Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
attempt at turning docker build into performance regression test
[simgrid.git] / .github / workflows / docker.yml
1 name: Docker unstable
2
3 # This workflow uses actions that are not certified by GitHub.
4 # They are provided by a third-party and are governed by
5 # separate terms of service, privacy policy, and support
6 # documentation.
7
8 on:
9   workflow_dispatch:
10   schedule:
11     - cron: '42 18 * * 0'
12
13 jobs:
14   docker-simgrid:
15
16     runs-on: ubuntu-latest
17     permissions:
18       contents: read
19       packages: write
20
21     steps:
22       - name: Checkout repository
23         uses: actions/checkout@v3
24
25       # Login against a Docker registry except on PR
26       # https://github.com/docker/login-action
27       - name: Log into registry ${{ env.REGISTRY }}
28         uses: docker/login-action@v1
29         with:
30           username: ${{ secrets.DOCKERHUB_USERNAME }}
31           password: ${{ secrets.DOCKERHUB_TOKEN }}
32
33       - name: build docker unstable
34         run: |
35           cd tools/docker
36           docker pull simgrid/unstable
37           docker tag simgrid/unstable simgrid/unstable_old
38           docker pull simgrid/stable
39           make unstable
40           git clone https://github.com/adegomme/master_worker_flashback
41           cd master_worker_flashback
42           make build
43           make run
44       - name: Create the failure Message
45         if: ${{ failure() }}
46         run: |
47           echo "{\"attachments\": [{\"color\": \"#FF0000\", \"text\":\"Failure when building docker unstable ! See ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} \"}]}" > mattermost.json
48       - name: Create the success Message
49         if: ${{ success() }}
50         run: |
51           echo "{\"attachments\": [{\"color\": \"#00FF00\", \"text\":\"Docker unstable built and pushed successfully ! ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} \"}]}" > mattermost.json
52       - uses: mattermost/action-mattermost-notify@master
53         env:
54           MATTERMOST_WEBHOOK_URL: ${{ secrets.MATTERMOST_WEBHOOK_URL }}
55           MATTERMOST_CHANNEL: ${{ secrets.MATTERMOST_CHANNEL}}
56
57
58   docker-tuto-mc:
59
60     # the Dockerfile builds upon debian:testing
61     runs-on: ubuntu-latest
62     permissions:
63       contents: read
64       packages: write
65
66     steps:
67       - name: Checkout repository
68         uses: actions/checkout@v3
69
70       # Login against a Docker registry except on PR
71       # https://github.com/docker/login-action
72       - name: Log into registry ${{ env.REGISTRY }}
73         uses: docker/login-action@v1
74         with:
75           username: ${{ secrets.DOCKERHUB_USERNAME }}
76           password: ${{ secrets.DOCKERHUB_TOKEN }}
77
78       - name: build docker tuto-mc
79         run: |
80           cd tools/docker
81           make tuto-mc
82           docker push simgrid/tuto-mc
83
84       - name: Create the failure Message
85         if: ${{ failure() }}
86         run: |
87           echo "{\"attachments\": [{\"color\": \"#FF0000\", \"text\":\"Failure when building docker tuto-mc image ! See ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} \"}]}" > mattermost.json
88       - name: Create the success Message
89         if: ${{ success() }}
90         run: |
91           echo "{\"attachments\": [{\"color\": \"#00FF00\", \"text\":\"Docker tuto-mc image built and pushed successfully ! ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} \"}]}" > mattermost.json
92       - uses: mattermost/action-mattermost-notify@master
93         env:
94           MATTERMOST_WEBHOOK_URL: ${{ secrets.MATTERMOST_WEBHOOK_URL }}
95           MATTERMOST_CHANNEL: ${{ secrets.MATTERMOST_CHANNEL}}
96