File tree Expand file tree Collapse file tree 1 file changed +21
-2
lines changed Expand file tree Collapse file tree 1 file changed +21
-2
lines changed Original file line number Diff line number Diff line change 9
9
runs-on : ubuntu-latest
10
10
11
11
steps :
12
+ # Free disk space
13
+ - name : Free up disk space
14
+ run : sudo rm -rf /usr/share/dotnet
15
+
16
+ # checkout repository
12
17
- name : Checkout repository
13
- uses : actions/checkout@v2.3.4
18
+ uses : actions/checkout@v2
19
+ with :
20
+ fetch-depth : 1
14
21
15
22
# Build Docker image
16
23
- id : get-timestamp
36
43
image_tag : ${{github.sha}}
37
44
push_image_and_stages : true
38
45
username : ${{ secrets.DOCKER_REGISTRY_USERNAME }}
39
- password : " ${{ secrets.DOCKER_REGISTRY_TOKEN }}"
46
+ password : " ${{ secrets.DOCKER_REGISTRY_TOKEN }}"
47
+
48
+ - name : Clean up unnecessary images to free disk space
49
+ run : |
50
+ images=$(docker images | grep -v ${{github.sha}} | grep ago | awk '{print $3}')
51
+ docker rm -f $images
40
52
41
53
- name : Label base Docker image
42
54
run : |
57
69
username : ${{ secrets.DOCKER_REGISTRY_USERNAME }}
58
70
password : " ${{ secrets.DOCKER_REGISTRY_TOKEN }}"
59
71
72
+ - name : Clean up unnecessary images to free disk space
73
+ run : |
74
+ images=$(docker images | grep -v ${{github.sha}} | grep ago | awk '{print $3}')
75
+ docker rm -f $images
76
+
60
77
- name : Label Docker image
61
78
run : |
79
+ docker image tag ghcr.io/biosimulators/biosimulators-base-stages:${{github.sha}} ghcr.io/biosimulators/biosimulators-base:${{github.sha}}
80
+ docker image tag ghcr.io/biosimulators/biosimulators-base-stages:${{github.sha}} ghcr.io/biosimulators/biosimulators-base:latest
62
81
docker image tag ghcr.io/biosimulators/biosimulators-stages:${{github.sha}} ghcr.io/biosimulators/biosimulators:${{github.sha}}
63
82
docker image tag ghcr.io/biosimulators/biosimulators-stages:${{github.sha}} ghcr.io/biosimulators/biosimulators:latest
64
83
You can’t perform that action at this time.
0 commit comments