-
Notifications
You must be signed in to change notification settings - Fork 1
42 lines (40 loc) · 1.12 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
41
42
name: Docker Push
on:
push:
branches:
- main
- develop
- feature/noble
jobs:
deploy:
name: Deploy app
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: docker login
run: docker login -u $DOCKER_USER -p $DOCKER_PASSWORD
env:
DOCKER_USER: ${{ secrets.DOCKER_USER }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build and push (main)
if: github.ref == 'refs/heads/main'
uses: docker/build-push-action@v5
with:
context: .
file: ./Dockerfile
push: true
tags: |
mczachurski/vernissage-server:latest
mczachurski/vernissage-server:1.0.0
- name: Build and push (develop)
if: github.ref == 'refs/heads/develop'
uses: docker/build-push-action@v5
with:
context: .
file: ./Dockerfile
push: true
tags: |
mczachurski/vernissage-server:develop
mczachurski/vernissage-server:1.0.0-alpha