Dockerfile: move alias and path to ardupilot_env

This commit is contained in:
TsuyoshiKawamura 2022-12-17 22:34:26 +09:00 committed by Peter Barker
parent 6d2e060deb
commit c740cd865a
1 changed files with 3 additions and 3 deletions

View File

@ -30,11 +30,11 @@ USER ${USER_NAME}
ENV SKIP_AP_EXT_ENV=1 SKIP_AP_GRAPHIC_ENV=1 SKIP_AP_COV_ENV=1 SKIP_AP_GIT_CHECK=1 ENV SKIP_AP_EXT_ENV=1 SKIP_AP_GRAPHIC_ENV=1 SKIP_AP_COV_ENV=1 SKIP_AP_GIT_CHECK=1
RUN Tools/environment_install/install-prereqs-ubuntu.sh -y RUN Tools/environment_install/install-prereqs-ubuntu.sh -y
# add waf alias to ardupilot waf to .bashrc # add waf alias to ardupilot waf to .ardupilot_env
RUN echo "alias waf=\"/${USER_NAME}/waf\"" >> ~/ardupilot_entrypoint.sh RUN echo "alias waf=\"/${USER_NAME}/waf\"" >> ~/.ardupilot_env
# Check that local/bin are in PATH for pip --user installed package # Check that local/bin are in PATH for pip --user installed package
RUN echo "if [ -d \"\$HOME/.local/bin\" ] ; then\nPATH=\"\$HOME/.local/bin:\$PATH\"\nfi" >> ~/ardupilot_entrypoint.sh RUN echo "if [ -d \"\$HOME/.local/bin\" ] ; then\nPATH=\"\$HOME/.local/bin:\$PATH\"\nfi" >> ~/.ardupilot_env
# Create entrypoint as docker cannot do shell substitution correctly # Create entrypoint as docker cannot do shell substitution correctly
RUN export ARDUPILOT_ENTRYPOINT="/home/${USER_NAME}/ardupilot_entrypoint.sh" \ RUN export ARDUPILOT_ENTRYPOINT="/home/${USER_NAME}/ardupilot_entrypoint.sh" \