Skip to content

Commit

Permalink
do not copy top level directory (#2761)
Browse files Browse the repository at this point in the history
  • Loading branch information
Haroon-Khel authored Oct 6, 2022
1 parent 597ead2 commit 0443672
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
10 changes: 5 additions & 5 deletions ansible/docker/Dockerfile.Alpine3
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ RUN apk update \
&& apk upgrade \
&& apk add ansible

COPY ../. /infrastructure
COPY . /ansible

RUN echo "localhost ansible_connection=local" > /infrastructure/ansible/hosts
RUN echo "localhost ansible_connection=local" > /ansible/hosts

RUN set -eux; \
cd /infrastructure; \
ansible-playbook -i ansible/hosts ansible/playbooks/AdoptOpenJDK_Unix_Playbook/main.yml -e "git_sha=$git_sha" --skip-tags="debug,hosts_file,hostname,adoptopenjdk,jenkins,nagios,superuser,docker,swap_file,crontab,nvidia_cuda_toolkit"; \
rm -rf /infrastructure; apk del ansible
cd /ansible; \
ansible-playbook -i hosts ansible/playbooks/AdoptOpenJDK_Unix_Playbook/main.yml -e "git_sha=$git_sha" --skip-tags="debug,hosts_file,hostname,adoptopenjdk,jenkins,nagios,superuser,docker,swap_file,crontab,nvidia_cuda_toolkit"; \
rm -rf /ansible; apk del ansible

ENV \
JDK7_BOOT_DIR="/usr/lib/jvm/jdk8" \
Expand Down
12 changes: 6 additions & 6 deletions ansible/docker/Dockerfile.CentOS6
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,16 @@ RUN sed -i -e 's!mirrorlist!#mirrorlist!g' /etc/yum.repos.d/CentOS-Base.repo; \
yum -y install gcc openssl-devel bzip2-devel sqlite-devel sudo wget python3 epel-release; \
yum -y install ansible

COPY ../. /infrastructure
COPY . /ansible

RUN echo "localhost ansible_connection=local" > /infrastructure/ansible/hosts
RUN echo "localhost ansible_connection=local" > /ansible/hosts

RUN set -eux; \
cd /infrastructure; \
ansible-playbook -i ansible/hosts ansible/playbooks/AdoptOpenJDK_Unix_Playbook/main.yml -e "git_sha=$git_sha" --skip-tags="debug,hosts_file,hostname,adoptopenjdk,jenkins,nagios,superuser,docker,swap_file,crontab,nvidia_cuda_toolkit"; \
ansible-playbook -i ansible/hosts ansible/playbooks/AdoptOpenJDK_Unix_Playbook/main.yml -e "git_sha=$git_sha" --tags="riscv"
cd /ansible; \
ansible-playbook -i hosts ansible/playbooks/AdoptOpenJDK_Unix_Playbook/main.yml -e "git_sha=$git_sha" --skip-tags="debug,hosts_file,hostname,adoptopenjdk,jenkins,nagios,superuser,docker,swap_file,crontab,nvidia_cuda_toolkit"; \
ansible-playbook -i hosts ansible/playbooks/AdoptOpenJDK_Unix_Playbook/main.yml -e "git_sha=$git_sha" --tags="riscv"

RUN rm -rf /infrastructure; yum remove -y ansible; yum clean all
RUN rm -rf /ansible; yum remove -y ansible; yum clean all

RUN groupadd -g 1000 ${user}
RUN useradd -c "Jenkins user" -d /home/${user} -u 1000 -g 1000 -m ${user}
Expand Down

0 comments on commit 0443672

Please sign in to comment.