Skip to content

Commit 5d069a5

Browse files
committed
Merge branch 'develop'
2 parents 1f12fd4 + 38c649c commit 5d069a5

File tree

1 file changed

+37
-2
lines changed

1 file changed

+37
-2
lines changed

.github/workflows/test.yml renamed to .github/workflows/test-and-ship.yml

Lines changed: 37 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Test
1+
name: Test & Ship
22

33
on:
44
- push
@@ -7,7 +7,7 @@ on:
77
jobs:
88
test:
99
runs-on: ubuntu-latest
10-
timeout-minutes: 15
10+
timeout-minutes: 30
1111

1212
strategy:
1313
matrix:
@@ -53,3 +53,38 @@ jobs:
5353
5454
#
5555
# gulp send-stats-to-coveralls ;
56+
57+
ship:
58+
needs: [ test ]
59+
if: github.event_name == 'push' # not on PRs
60+
runs-on: ubuntu-latest
61+
timeout-minutes: 15
62+
63+
steps:
64+
- uses: actions/checkout@v2
65+
66+
- name: Configure AWS credentials
67+
uses: aws-actions/configure-aws-credentials@v1
68+
with:
69+
aws-access-key-id: ${{ secrets.AWS_ECR_ACCESS_KEY_ID }}
70+
aws-secret-access-key: ${{ secrets.AWS_ECR_SECRET_ACCESS_KEY }}
71+
aws-region: eu-west-1
72+
73+
- name: Get ECR password
74+
id: get-ecr-password
75+
run: echo "::set-output name=password::$(aws ecr get-login-password)"
76+
77+
- name: Build and push to Amazon ECR
78+
uses: docker/build-push-action@v1
79+
with:
80+
registry: 513259414768.dkr.ecr.eu-west-1.amazonaws.com
81+
repository: platform-client
82+
username: AWS
83+
password: ${{ steps.get-ecr-password.outputs.password }}
84+
always_pull: true
85+
tag_with_sha: true
86+
tag_with_ref: true
87+
88+
- name: Logout from Amazon ECR
89+
if: always()
90+
run: docker logout ${{ steps.login-ecr.outputs.registry }}

0 commit comments

Comments
 (0)