-
Notifications
You must be signed in to change notification settings - Fork 1
64 lines (58 loc) · 2.08 KB
/
promote-docker-images.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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: publish to registry
on:
push:
branches:
- develop
env:
PROJECT: book
DOCKERIMAGE-BOOK-API: hergytchuinkou/book-api-kit
DOCKERIMAGE-METRICS: hergytchuinkou/book-metrics-kit
REGISTRY_DOMAIN: openshift-registry.adorsys.de
APPNAME: book
jobs:
publish-book-api:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Generate keys
run: make keys
- name: Run build
run: make books-api
- name: Docker login
run: docker login -u ${{ secrets.DOCKERHUB_USERNAME }} -p ${{ secrets.DOCKERHUB_PASSWORD }}
- name: Build
run: make books-api
- name: Tags
run: |
docker tag book-api-kit ${{ secrets.DOCKERHUB_USERNAME }}/book-api-kit:latest
- name: Push
run: |
docker push ${{ secrets.DOCKERHUB_USERNAME }}/book-api-kit:latest
publish-metrics:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Run build
run: make metrics
- name: Docker login
run: docker login -u ${{ secrets.DOCKERHUB_USERNAME }} -p ${{ secrets.DOCKERHUB_PASSWORD }}
- name: Build
run: make metrics
- name: Tags
run: |
docker tag book-metrics-kit ${{ secrets.DOCKERHUB_USERNAME }}/book-metrics-kit:latest
- name: Push
run: |
docker push ${{ secrets.DOCKERHUB_USERNAME }}/book-metrics-kit:latest
# - name: OpenShift Action publish images
# uses: redhat-developer/openshift-actions@v1.1
# with:
# version: 'latest'
# openshift_server_url: ${{secrets.OPENSHIFT_SERVER_URL}}
# parameters: '{"username": "${{ secrets.USERNAME }}", "password": "${{ secrets.PASSWORD }}", "acceptUntrustedCerts": "true"}'
# cmd: |
# oc project book-library
# oc import-image --confirm hergytchuinkou/book-api-kit:latest
# oc import-image --confirm hergytchuinkou/book-metrics-kit:latest
# oc import-image --confirm openzipkin/zipkin:2.11
# oc import-image --confirm postgres:11.1-alpine