-
Notifications
You must be signed in to change notification settings - Fork 1
40 lines (38 loc) · 1.04 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
40
name: docker containers
on:
push:
branches:
- main
pull_request:
branches:
- main
concurrency:
group: docker-${{ github.ref }}
cancel-in-progress: true
jobs:
docker:
runs-on: ubuntu-latest
name: "Docker"
steps:
- uses: actions/checkout@v4
- run: docker compose build
- uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
- run: |
echo $MONDEY_DOCKER_IMAGE_TAG
docker compose build
docker compose push
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
env:
MONDEY_DOCKER_IMAGE_TAG: ${{ github.sha }}
- run: |
echo $MONDEY_DOCKER_IMAGE_TAG
docker compose build
docker compose push
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
env:
MONDEY_DOCKER_IMAGE_TAG: "latest"