-
Notifications
You must be signed in to change notification settings - Fork 34
44 lines (36 loc) · 1.37 KB
/
release_main.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
# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
name: Release
on:
release:
types:
- published
jobs:
# tests:
# uses: ./.github/workflows/basic_tests.yml # execute the callable basic_tests.yml
end_to_end_tests:
uses: ./.github/workflows/end_to_end_tests.yml # execute the callable end_to_end_tests.yml
build_and_push_docker_image:
# needs: [tests]
runs-on: ubuntu-latest
name: Push stellar/anchor-platform:VERSION to DockerHub
steps:
- uses: actions/checkout@v3
- name: Login to DockerHub
uses: docker/login-action@bb984efc561711aaa26e433c32c3521176eae55b
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push to DockerHub
uses: docker/build-push-action@7f9d37fa544684fb73bfe4835ed7214c255ce02b
with:
push: true
tags: stellar/anchor-platform:${{ github.event.release.tag_name }}
file: Dockerfile
complete:
if: always()
needs: [build_and_push_docker_image]
runs-on: ubuntu-latest
steps:
- if: contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled')
run: exit 1