CI: Use docker mirror proxy
TODO: Debian build still requires access to original repo. Change-Id: Ie4bac5334369a63793d36568a9d3a58a0cdc7667 Signed-off-by: Radosław Piliszek <radoslaw.piliszek@gmail.com>
This commit is contained in:
parent
52024d2c57
commit
1d0c1e51af
@ -3,15 +3,11 @@
|
||||
vars_files:
|
||||
- ../vars/zuul.yml
|
||||
tasks:
|
||||
- name: copy setup script
|
||||
copy:
|
||||
src: "{{ zuul.executor.work_root }}/{{ zuul.project.src_dir }}/tools/setup_{{ ansible_os_family }}.sh"
|
||||
dest: /tmp/setup.sh
|
||||
mode: 0755
|
||||
|
||||
- name: run node setup script
|
||||
shell: /tmp/setup.sh
|
||||
- name: Run node setup script
|
||||
script: "{{ zuul.executor.work_root }}/{{ zuul.project.src_dir }}/tools/setup_{{ ansible_os_family }}.sh"
|
||||
become: true
|
||||
environment:
|
||||
DOCKER_REPOS_MIRROR_URL: "{{ nodepool_docker_proxy }}"
|
||||
|
||||
- name: changing permission of Docker socket to 666
|
||||
file:
|
||||
|
@ -4,3 +4,4 @@ nodepool_pypi_mirror: "http://{{ zuul_site_mirror_fqdn }}:8080/pypi/simple"
|
||||
nodepool_mirror_host: "{{ zuul_site_mirror_fqdn }}"
|
||||
nodepool_npmjs_proxy: "http://{{ zuul_site_mirror_fqdn }}:8080/registry.npmjs/"
|
||||
nodepool_cbs_centos_proxy: "http://{{ zuul_site_mirror_fqdn }}:8080/cbs.centos"
|
||||
nodepool_docker_proxy: "http://{{ zuul_site_mirror_fqdn }}:8080/docker"
|
||||
|
@ -61,8 +61,8 @@ distro_codename=$(lsb_release -cs)
|
||||
|
||||
sudo apt-get update
|
||||
sudo apt-get -y install apt-transport-https
|
||||
sudo add-apt-repository "deb https://download.docker.com/linux/${distro_id} ${distro_codename} stable"
|
||||
curl -fsSL https://download.docker.com/linux/${distro_id}/gpg | sudo apt-key add -
|
||||
sudo add-apt-repository "deb $DOCKER_REPOS_MIRROR_URL/${distro_id} ${distro_codename} stable"
|
||||
curl -fsSL $DOCKER_REPOS_MIRROR_URL/${distro_id}/gpg | sudo apt-key add -
|
||||
sudo apt-get update
|
||||
sudo apt-get -y install --no-install-recommends docker-ce
|
||||
|
||||
|
@ -6,9 +6,13 @@ set -o errexit
|
||||
# (SamYaple)TODO: Remove the path overriding
|
||||
export PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
|
||||
|
||||
sudo yum-config-manager \
|
||||
--add-repo \
|
||||
https://download.docker.com/linux/centos/docker-ce.repo
|
||||
sudo tee /etc/yum.repos.d/docker-ce-stable.repo << EOF
|
||||
[docker-ce-stable]
|
||||
baseurl=$DOCKER_REPOS_MIRROR_URL/centos/7/\$basearch/stable
|
||||
enabled=1
|
||||
gpgcheck=1
|
||||
gpgkey=$DOCKER_REPOS_MIRROR_URL/centos/gpg
|
||||
EOF
|
||||
|
||||
sudo yum -y install libffi-devel openssl-devel docker-ce btrfs-progs
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user