-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (36 loc) · 1.18 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
name: Docker Image CI
on:
push:
tags:
- '*'
branches:
- '*'
jobs:
build-and-push-image:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Login to GHCR
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ secrets.GH_USERNAME }}
password: ${{ secrets.GH_TOKEN }}
- name: Get the version
id: get_version
run: echo ::set-output name=VERSION::$(echo $GITHUB_REF | cut -d / -f 3)
- name: Build and push dynratelimiter
uses: docker/build-push-action@v2
with:
context: .
file: build/docker/dynratelimiter/Dockerfile
push: true
tags: ghcr.io/arivum/dynratelimiter/dynratelimiter:${{ steps.get_version.outputs.VERSION }},ghcr.io/arivum/dynratelimiter/dynratelimiter:latest
- name: Build and push operator
uses: docker/build-push-action@v2
with:
context: .
file: build/docker/dynratelimiter-operator/Dockerfile
push: true
tags: ghcr.io/arivum/dynratelimiter/dynratelimiter-operator:${{ steps.get_version.outputs.VERSION }},ghcr.io/arivum/dynratelimiter/dynratelimiter-operator:latest