-
Notifications
You must be signed in to change notification settings - Fork 24
60 lines (52 loc) · 1.53 KB
/
release.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
name: elastic beat release by goreleaser
on:
push:
tags:
- '*'
env:
GOPRIVATE: github.com/streamnative
jobs:
goreleaser:
runs-on: ubuntu-20.04
steps:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.18
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Run GoReleaser
uses: goreleaser/[email protected]
with:
distribution: goreleaser
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.BEAT_ACCESS_TOKEN }}
GOPATH: /home/runner/work/pulsar-beat-output/pulsar-beat-output/go
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Docker meta for filebeat
id: docker_meta_filebeat
uses: crazy-max/ghaction-docker-meta@v1
with:
images: |
streamnative/filebeat
tag-sha: true
- name: Setup tmate session
uses: mxschmitt/action-tmate@v3
- name: Build and push beat image
uses: docker/build-push-action@v2
with:
context: .
file: ./filebeat/Dockerfile
push: true
tags: ${{ steps.docker_meta_filebeat.outputs.tags }}
labels: ${{ steps.docker_meta_filebeat.outputs.labels }}