Unverified Commit d168481c authored by Benjamin Lefaudeux's avatar Benjamin Lefaudeux Committed by GitHub
Browse files

[chore] Robustify CI, apt-get retries (#482)

parent a05a79bc
...@@ -63,6 +63,8 @@ install_dep_151: &install_dep_151 ...@@ -63,6 +63,8 @@ install_dep_151: &install_dep_151
- run: - run:
name: Install Dependencies with torch 1.5.1 name: Install Dependencies with torch 1.5.1
command: | command: |
# make sure that apt-get retries if needed
sudo sh -c "echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80-retries"
sudo apt-get install -y libopenmpi-dev sudo apt-get install -y libopenmpi-dev
# check if we have restored venv cache (/home/circleci/venv) correctly, if so, just skip # check if we have restored venv cache (/home/circleci/venv) correctly, if so, just skip
if [ -f /home/circleci/venv/check_version.py ]; then python /home/circleci/venv/check_version.py torch eq 1.5 && exit 0; fi if [ -f /home/circleci/venv/check_version.py ]; then python /home/circleci/venv/check_version.py torch eq 1.5 && exit 0; fi
...@@ -79,6 +81,8 @@ install_dep_160: &install_dep_160 ...@@ -79,6 +81,8 @@ install_dep_160: &install_dep_160
- run: - run:
name: Install Dependencies with torch 1.6.0 name: Install Dependencies with torch 1.6.0
command: | command: |
# make sure that apt-get retries if needed
sudo sh -c "echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80-retries"
sudo apt-get install -y libopenmpi-dev sudo apt-get install -y libopenmpi-dev
# check if we have restored venv cache (/home/circleci/venv) correctly, if so, just skip # check if we have restored venv cache (/home/circleci/venv) correctly, if so, just skip
if [ -f /home/circleci/venv/check_version.py ]; then python /home/circleci/venv/check_version.py torch eq 1.6 && exit 0; fi if [ -f /home/circleci/venv/check_version.py ]; then python /home/circleci/venv/check_version.py torch eq 1.6 && exit 0; fi
...@@ -96,6 +100,8 @@ install_dep_171: &install_dep_171 ...@@ -96,6 +100,8 @@ install_dep_171: &install_dep_171
- run: - run:
name: Install Dependencies with torch 1.7.1 name: Install Dependencies with torch 1.7.1
command: | command: |
# make sure that apt-get retries if needed
sudo sh -c "echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80-retries"
sudo apt-get install -y libopenmpi-dev sudo apt-get install -y libopenmpi-dev
# check if we have restored venv cache (/home/circleci/venv) correctly, if so, just skip # check if we have restored venv cache (/home/circleci/venv) correctly, if so, just skip
if [ -f /home/circleci/venv/check_version.py ]; then python /home/circleci/venv/check_version.py torch eq 1.7 && exit 0; fi if [ -f /home/circleci/venv/check_version.py ]; then python /home/circleci/venv/check_version.py torch eq 1.7 && exit 0; fi
...@@ -113,6 +119,8 @@ install_dep_171_cu110: &install_dep_171_cu110 ...@@ -113,6 +119,8 @@ install_dep_171_cu110: &install_dep_171_cu110
- run: - run:
name: Install Dependencies with torch 1.7.1+cu110 name: Install Dependencies with torch 1.7.1+cu110
command: | command: |
# make sure that apt-get retries if needed
sudo sh -c "echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80-retries"
sudo add-apt-repository universe sudo add-apt-repository universe
sudo apt-get update sudo apt-get update
sudo apt-get install -y libopenmpi-dev sudo apt-get install -y libopenmpi-dev
...@@ -132,6 +140,8 @@ install_dep_180: &install_dep_180 ...@@ -132,6 +140,8 @@ install_dep_180: &install_dep_180
- run: - run:
name: Install Dependencies with torch 1.8.0 nightly name: Install Dependencies with torch 1.8.0 nightly
command: | command: |
# make sure that apt-get retries if needed
sudo sh -c "echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80-retries"
sudo apt-get install -y libopenmpi-dev sudo apt-get install -y libopenmpi-dev
# check if we have restored cache correctly, if so, just skip # check if we have restored cache correctly, if so, just skip
if [ -f /home/circleci/venv/check_version.py ]; then python /home/circleci/venv/check_version.py torch eq 1.8 && exit 0; fi if [ -f /home/circleci/venv/check_version.py ]; then python /home/circleci/venv/check_version.py torch eq 1.8 && exit 0; fi
......
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