From 40087399862dfbfe49697434cc5d7e266fdfe63a Mon Sep 17 00:00:00 2001 From: adegomme <13270544+adegomme@users.noreply.github.com> Date: Mon, 30 Aug 2021 14:18:35 +0200 Subject: [PATCH] Add docker images to ci (#378) * Create docker.yml test without push * add make stable * framagit download path is easier now * Update Makefile * Update Makefile * Update Makefile * Update Makefile * Update Makefile * Update Makefile * Update Makefile * Update docker.yml * Update docker.yml * Update Makefile * Update docker.yml * trailing spaces --- .github/workflows/docker.yml | 38 ++++++++++++++++++++++++++++++++++++ tools/docker/Makefile | 9 ++++----- 2 files changed, 42 insertions(+), 5 deletions(-) create mode 100644 .github/workflows/docker.yml diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml new file mode 100644 index 0000000000..a1ae0340ae --- /dev/null +++ b/.github/workflows/docker.yml @@ -0,0 +1,38 @@ +name: Docker + +# This workflow uses actions that are not certified by GitHub. +# They are provided by a third-party and are governed by +# separate terms of service, privacy policy, and support +# documentation. + +on: + workflow_dispatch: + schedule: + - cron: '42 18 * * 0' + +jobs: + build: + + runs-on: ubuntu-latest + permissions: + contents: read + packages: write + + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + # Login against a Docker registry except on PR + # https://github.com/docker/login-action + - name: Log into registry ${{ env.REGISTRY }} + uses: docker/login-action@v1 + with: + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + + - name: build + run: | + cd tools/docker + make stable + make all + make push diff --git a/tools/docker/Makefile b/tools/docker/Makefile index dc2faf5a70..4da4f51abe 100644 --- a/tools/docker/Makefile +++ b/tools/docker/Makefile @@ -11,15 +11,14 @@ default: @echo "All our images are based on debian:testing" @echo "Also possible: DOCKER_EXTRA=--no-cache make unstable" -all: build-deps unstable tuto-s4u tuto-smpi +all: build-deps unstable tuto-s4u tuto-smpi tuto-mc stable: - # docker build -f Dockerfile.stable --build-arg DLURL=/simgrid/simgrid/uploads/0365f13697fb26eae8c20fc234c5af0e/SimGrid-3.25.tar.gz -t simgrid/stable:latest -t simgrid/stable:v3.25 . |tee stable.log + # docker build -f Dockerfile.stable --build-arg DLURL=/simgrid/simgrid/-/archive/v3.28/simgrid-v3.28.tar.gz -t simgrid/stable:latest -t simgrid/stable:v3.25 . |tee stable.log export last_tag=$$(wget https://framagit.org/simgrid/simgrid/tags 2>/dev/null -O - | grep /simgrid/simgrid/-/tags/v | head -n1 | sed 's/[^>]*>//' | sed 's/<.*//'); \ - export DLURL=$$(wget https://framagit.org/simgrid/simgrid/tags/$${last_tag} 2>/dev/null -O - | grep simgrid- | perl -pe 's/.*?