Commit 2d21fad5 authored by Prada Sarasola, Miguel's avatar Prada Sarasola, Miguel

Merge branch 'dev-image' into 'master'

Add development-mode deployment image

See merge request !22
parents d2abcf80 29fbaaa3
......@@ -43,11 +43,17 @@ industrial_ci_kinetic_deploy:
script:
- .ci_config/gitlab.sh
- cd $(mktemp -d)
- wget https://git.code.tecnalia.com/tecnalia_robotics-public/gitlab_templates/raw/master/deploy/Dockerfile
- wget https://git.code.tecnalia.com/tecnalia_robotics-public/gitlab_templates/raw/master/deploy/ros_entrypoint.bash
- wget https://git.code.tecnalia.com/tecnalia_robotics-public/gitlab_templates/-/archive/master/gitlab_templates-master.zip
- unzip gitlab_templates-master.zip && cd gitlab_templates-master/deploy
- cd base
- chmod a+x ros_entrypoint.bash
- docker build -t ${ARTIFACT_DOCKER_URL}/${CI_PROJECT_NAME}:${CI_COMMIT_REF_NAME} .
- docker push ${ARTIFACT_DOCKER_URL}/${CI_PROJECT_NAME}:${CI_COMMIT_REF_NAME}
- cd ..
- cd dev
- docker build --build-arg APPLICATION_IMAGE=${ARTIFACT_DOCKER_URL}/${CI_PROJECT_NAME}:${CI_COMMIT_REF_NAME} -t ${ARTIFACT_DOCKER_URL}/${CI_PROJECT_NAME}:${CI_COMMIT_REF_NAME}-dev .
- docker push ${ARTIFACT_DOCKER_URL}/${CI_PROJECT_NAME}:${CI_COMMIT_REF_NAME}-dev
- cd ..
only:
- tags
......
......@@ -45,11 +45,17 @@ industrial_ci_kinetic_deploy:
script:
- .ci_config/gitlab.sh
- cd $(mktemp -d)
- wget https://git.code.tecnalia.com/tecnalia_robotics-public/gitlab_templates/raw/master/deploy/Dockerfile
- wget https://git.code.tecnalia.com/tecnalia_robotics-public/gitlab_templates/raw/master/deploy/ros_entrypoint.bash
- wget https://git.code.tecnalia.com/tecnalia_robotics-public/gitlab_templates/-/archive/master/gitlab_templates-master.zip
- unzip gitlab_templates-master.zip && cd gitlab_templates-master/deploy
- cd base
- chmod a+x ros_entrypoint.bash
- docker build -t ${ARTIFACT_DOCKER_URL}/${CI_PROJECT_NAME}:${CI_COMMIT_REF_NAME} .
- docker push ${ARTIFACT_DOCKER_URL}/${CI_PROJECT_NAME}:${CI_COMMIT_REF_NAME}
- cd ..
- cd dev
- docker build --build-arg APPLICATION_IMAGE=${ARTIFACT_DOCKER_URL}/${CI_PROJECT_NAME}:${CI_COMMIT_REF_NAME} -t ${ARTIFACT_DOCKER_URL}/${CI_PROJECT_NAME}:${CI_COMMIT_REF_NAME}-dev .
- docker push ${ARTIFACT_DOCKER_URL}/${CI_PROJECT_NAME}:${CI_COMMIT_REF_NAME}-dev
- cd ..
only:
- tags
......
......@@ -2,6 +2,10 @@ FROM industrial_ci_image
RUN rm -rf /root/ici /root/src
RUN apt-get update -qq && apt-get install -y -qq \
ros-kinetic-rosbash \
&& rm -rf /var/lib/apt/lists/*
COPY ./ros_entrypoint.bash /
ENTRYPOINT ["/ros_entrypoint.bash"]
......
ARG APPLICATION_IMAGE
FROM ${APPLICATION_IMAGE}
RUN apt-get update -qq && apt-get install -y -qq \
apt-transport-https
RUN curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > microsoft.gpg \
&& mv microsoft.gpg /etc/apt/trusted.gpg.d/microsoft.gpg \
&& sh -c 'echo "deb [arch=amd64] https://packages.microsoft.com/repos/vscode stable main" > /etc/apt/sources.list.d/vscode.list'
RUN apt-get update -qq && apt-get install -y -qq \
code
RUN echo "alias code='code --user-data-dir /root'" >> /root/.bashrc
RUN code --user-data-dir /root \
--install-extension ajshort.ros \
--install-extension joaompinto.asciidoctor-vscode \
--install-extension ms-python.python \
--install-extension ms-vscode.cpptools \
--install-extension peterjausovec.vscode-docker \
--install-extension twxs.cmake
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment