Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't build for test from the new Dockerfile in the repository #61

Open
wanix opened this issue Sep 9, 2022 · 2 comments
Open

Can't build for test from the new Dockerfile in the repository #61

wanix opened this issue Sep 9, 2022 · 2 comments

Comments

@wanix
Copy link
Contributor

wanix commented Sep 9, 2022

Hi all,
I want to propose a change for a RDS use we need and trying to validate my changes with the latest master, I am blocked on the docker build:

docker build -t "test-aws-resource-exporter:"(git rev-parse --short HEAD) .
Sending build context to Docker daemon  3.292MB
Step 1/8 : FROM quay.io/app-sre/golang:1.18.5 as builder
unauthorized: access to the requested resource is not authorized

Is it awaited to not being able to build the image ?

@janboll
Copy link
Contributor

janboll commented Sep 12, 2022

Hi, That's actually a good point. We use the dockerfiles to build this tool for our internal deployments, that enforce these private images. Can you please try testing by leveraging this image? https://hub.docker.com/_/golang
I'll create a story in out backlog to fix tooling to better support this contribution.

For our reference: https://issues.redhat.com/browse/APPSRE-6265

@wanix
Copy link
Contributor Author

wanix commented Sep 13, 2022

I have a running image (19,8MB) with the following dockerfile:

##
## Build
##

FROM golang:1.19-buster AS build

WORKDIR /build

COPY . .

RUN make build

##
## Deploy
##

FROM scratch
COPY --from=build /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
COPY --from=build /build/aws-resource-exporter /bin/aws-resource-exporter

EXPOSE     9115
ENTRYPOINT ["/bin/aws-resource-exporter"]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants