Skip to content

Commit

Permalink
[CI] Add more guidelines about local setup (#6848)
Browse files Browse the repository at this point in the history
  • Loading branch information
tqchen authored Nov 4, 2020
1 parent b8761ed commit 3ff0100
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 11 deletions.
7 changes: 4 additions & 3 deletions docker/bash.sh
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,9 @@ else
fi

if [[ "${DOCKER_IMAGE_NAME}" == *"ci"* ]]; then
CI_PY_ENV="-e PYTHONPATH=/workspace/python"
CI_ADDON_ENV="-e PYTHONPATH=/workspace/python"
else
CI_PY_ENV=""
CI_ADDON_ENV=""
fi

# If the Vitis-AI docker image is selected, expose the Xilinx FPGA devices and required volumes containing e.g. DSA's and overlays
Expand Down Expand Up @@ -142,7 +142,8 @@ ${DOCKER_BINARY} run --rm --pid=host\
-e "CI_BUILD_GROUP=$(id -g -n)" \
-e "CI_BUILD_GID=$(id -g)" \
-e "CI_PYTEST_ADD_OPTIONS=$CI_PYTEST_ADD_OPTIONS" \
${CI_PY_ENV} \
-e "CI_IMAGE_NAME=${DOCKER_IMAGE_NAME}" \
${CI_ADDON_ENV} \
${CUDA_ENV} \
"${CI_DOCKER_EXTRA_PARAMS[@]}" \
${DOCKER_IMAGE_NAME} \
Expand Down
1 change: 1 addition & 0 deletions docker/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,7 @@ ${DOCKER_BINARY} run --rm --pid=host \
-e "CI_BUILD_GROUP=$(id -g -n)" \
-e "CI_BUILD_GID=$(id -g)" \
-e "CI_PYTEST_ADD_OPTIONS=$CI_PYTEST_ADD_OPTIONS" \
-e "CI_IMAGE_NAME=${DOCKER_IMAGE_NAME}" \
${CUDA_ENV}\
${CI_DOCKER_EXTRA_PARAMS[@]} \
${DOCKER_IMG_NAME} \
Expand Down
1 change: 1 addition & 0 deletions docker/with_the_same_user
Original file line number Diff line number Diff line change
Expand Up @@ -56,5 +56,6 @@ PATH=${PATH} \
JAVA_HOME=${JAVA_HOME} \
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} \
PYTHONPATH=${PYTHONPATH} \
CI_IMAGE_NAME=${CI_IMAGE_NAME} \
HOME=${CI_BUILD_HOME} \
"${COMMAND[@]}"
2 changes: 2 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,7 @@
).strip()

header_logo = "https://tvm.apache.org/assets/images/logo.svg"
header_logo_link = "https://tvm.apache.org/"

header_links = [
("Community", "https://tvm.apache.org/community"),
Expand Down Expand Up @@ -283,6 +284,7 @@
"header_links": header_links,
"header_dropdown": header_dropdown,
"header_logo": header_logo,
"header_logo_link": header_logo_link,
}

# add additional overrides
Expand Down
10 changes: 10 additions & 0 deletions tests/scripts/task_ci_python_setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,13 @@ set -u
set -o pipefail

# Script to setup additional python env.
#
# Use the following command to install the
# package to /workspace/.local, these additional
# packages will have precedence over the system packages.
#
# command: python3 -m pip install --user <package>==<version>
#
echo "Addtiional setup in" ${CI_IMAGE_NAME}

python3 -m pip install --user tlcpack-sphinx-addon==0.1.2
4 changes: 0 additions & 4 deletions tests/scripts/task_python_docs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,6 @@ find . -type f -path "*.log" | xargs rm -f
find . -type f -path "*.pyc" | xargs rm -f
make cython3

# install theme addon for to local if does not exists
# avoid docker for now before we stablize on the choice of style
python3 -m pip install --user --upgrade -q tlcpack-sphinx-addon==0.1.0

cd docs
PYTHONPATH=`pwd`/../python make html |& tee /tmp/$$.log.txt
if grep -E "failed to execute|Segmentation fault" < /tmp/$$.log.txt; then
Expand Down
4 changes: 0 additions & 4 deletions tests/scripts/task_sphinx_precheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,6 @@ rm -rf docs/vta/tutorials
find . -type f -path "*.pyc" | xargs rm -f
make cython3

# install theme addon for to local if does not exists
# avoid docker for now before we stablize on the choice of style
python3 -m pip install --user --upgrade -q tlcpack-sphinx-addon==0.1.0

echo "PreCheck sphinx doc generation WARNINGS.."
cd docs
make clean
Expand Down

0 comments on commit 3ff0100

Please sign in to comment.