Skip to content

Commit

Permalink
Merge pull request #33 from port-labs/PORT-5940-fix-k-8-s-exporter-bi…
Browse files Browse the repository at this point in the history
…naries-for-amd

PORT-5940 fix k 8 s exporter binaries for amd
  • Loading branch information
yairsimantov20 authored Jan 3, 2024
2 parents 763f103 + b6a091b commit 07e908a
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 5 deletions.
3 changes: 2 additions & 1 deletion .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ dockers:
- image_templates:
- "{{ .Env.REGISTRY }}/{{ .Env.IMAGE_NAME }}:{{ .Version }}-amd64"
use: buildx
dockerfile: Dockerfile
dockerfile: Dockerfile.x86_64
goarch: amd64
build_flag_templates:
- "--label=org.opencontainers.image.created={{.Date}}"
- "--label=org.opencontainers.image.title={{.ProjectName}}"
Expand Down
4 changes: 1 addition & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
FROM gcr.io/distroless/static-debian11
FROM alpine

COPY assets/ /assets

USER nonroot:nonroot

ENTRYPOINT ["/usr/bin/port-k8s-exporter"]

COPY port-k8s-exporter /usr/bin/port-k8s-exporter
9 changes: 9 additions & 0 deletions Dockerfile.x86_64
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
FROM alpine

COPY assets/ /assets

RUN apk add gcompat

ENTRYPOINT ["/usr/bin/port-k8s-exporter"]

COPY port-k8s-exporter /usr/bin/port-k8s-exporter
2 changes: 1 addition & 1 deletion pkg/event_handler/consumer/consumer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ func TestConsumer_HandleJson(t *testing.T) {
f.Consume(mockHandler.HandleJson)

f.Produce(t, []byte("test-value"))
time.Sleep(time.Second)
time.Sleep(time.Second * 2)

if len(mockHandler.CapturedValue) == 0 {
t.Error("Handler was not called")
Expand Down

0 comments on commit 07e908a

Please sign in to comment.