-
-
Notifications
You must be signed in to change notification settings - Fork 47
39 lines (34 loc) · 1.11 KB
/
docker.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: Build and push Docker images
on:
push:
branches: [ dev ]
tags: [ '*' ]
jobs:
build:
name: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
if: ${{ contains(github.event.head_commit.message, '[skip ci]') != true }}
- name: Build and push stable Docker image
uses: docker/[email protected]
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
repository: arkscript/stable
dockerfile: Dockerfile
# tag with the git commit SHA
tag_with_sha: true
tags: latest
# push the image only if the event that kicked off the workflow was a push of a git tah
push: ${{ startsWith(github.ref, 'refs/tags/') }}
- name: Build and push nightly Docker image
uses: docker/[email protected]
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
repository: arkscript/nightly
dockerfile: Dockerfile
# tag with the git commit SHA
tag_with_sha: true
tags: latest