Skip to content

Commit 90db8d1

Browse files
Use self-hosted action instead of drone. (#16)
1 parent 34e5eea commit 90db8d1

File tree

2 files changed

+46
-52
lines changed

2 files changed

+46
-52
lines changed

.github/workflows/publish.yaml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Publish
2+
on:
3+
push:
4+
tags:
5+
- v**
6+
jobs:
7+
publish-ecr:
8+
runs-on: self-hosted
9+
permissions:
10+
id-token: write
11+
contents: read
12+
steps:
13+
- uses: actions/checkout@v3
14+
15+
- name: configure aws credentials
16+
uses: aws-actions/configure-aws-credentials@v1
17+
with:
18+
role-to-assume: arn:aws:iam::558830342743:role/PublishCleanerController
19+
role-session-name: github-actions-from-cleaner-controller
20+
aws-region: us-east-1
21+
22+
- name: Login to Amazon ECR Public
23+
id: login-ecr-public
24+
uses: aws-actions/amazon-ecr-login@v2
25+
with:
26+
registry-type: public
27+
28+
- uses: actions/setup-go@v4
29+
with:
30+
go-version: '1.19'
31+
32+
- name: Build, tag, and push docker image to Amazon ECR Public
33+
uses: int128/kaniko-action@v1
34+
with:
35+
push: true
36+
tags: ${{ steps.login-ecr-public.outputs.registry }}/f8y0w2c4/cleaner-controller:${{ github.ref_name }}
37+
38+
- name: Publish helm chart
39+
run: |
40+
make helm VERSION=manager-${{ github.ref_name }}
41+
# latest v3.13.0 helm is bugged https://github.com/helm/helm/issues/12423
42+
curl https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 | bash -s -- --version v3.12.3
43+
helm package ./cleaner-controller --app-version ${{ github.ref_name }} --version ${{ github.ref_name }}
44+
helm push ./cleaner-controller-${{ github.ref_name }}.tgz oci://public.ecr.aws/f8y0w2c4
45+
46+

.vtex/drone.yml

Lines changed: 0 additions & 52 deletions
This file was deleted.

0 commit comments

Comments
 (0)