-
Notifications
You must be signed in to change notification settings - Fork 518
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
Fix #216 added support for user with x509 enabled #294
Fix #216 added support for user with x509 enabled #294
Conversation
- support for --ssl-cert and --ssl-key arguments - refer https://dev.mysql.com/doc/refman/5.7/en/using-encrypted-connections.html
- Dockerfile for multi stage build - steps for building binary file
Hi @mfridman Do I need to run any other checks / tests for this PR? |
No, all the tests pass. We'd prefer if you added (even if hard coded) test, but otherwise I need to test to make sure it's doing the right thing. (fwiw the code looks correct). |
- return error if failed to load x509 keypair
- update readme and rename Dockerfile as Dockerfile.local
- To be consistant with our releases build. - refer https://github.com/pressly/goose/blob/97eae0915cccce7fff1cce5387a9140e1320333a/.goreleaser.yml#L9
|
||
COPY . /src | ||
WORKDIR /src | ||
RUN CGO_ENABLED=0 make dist |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mfridman Added CGO_ENABLED=0
to be consistant with release build.
Refer https://github.com/pressly/goose/blob/master/.goreleaser.yml#L9
Without that, it's not working with alpine based docker images.
I have tested with this
FROM alpine:3.15
COPY --from=builder /src/bin/goose-linux64 /usr/local/bin/goose
RUN chmod +x /usr/local/bin/goose
RUN apk --no-cache add curl
RUN curl -ksSL https://raw.githubusercontent.com/cloudflare/cfssl/master/certdb/sqlite/migrations/001_CreateCertificates.sql -o 001_CreateCertificates.sql
RUN goose sqlite3 ./data.db up
RUN goose sqlite3 ./data.db status
Giving following error if the image is alpine. The same binary is working perfect in debian based images.
After adding CGO_ENABLED=0
Working in both debian and alpine based images.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, iirc this might be related to golang/go#28065 (I haven't kept up whether this is still the state of the world).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your contribution.
support for --ssl-cert and --ssl-key arguments
refer https://dev.mysql.com/doc/refman/5.7/en/using-encrypted-connections.html