gauth
gauth copied to clipboard
Add Dockerfiles + pretty output
Hi @stevemcquaid, could you describe what you're going for with the output? No going to lie I'm pretty happy with what I came up with and quite habituated, but I can surely be swayed to change it outright and I'm open to making it configurable.
Personally no use case for Docker for a single Go binary that's not networked, but if anybody has a use case and wants to automate through GitHub Actions or similar, totally open to the contribution. Probably shouldn't go to somebody else's repo though ;)
Feel free to update this PR or I'll probably close it in a few years ;)
All comments are fair, I just figured a PR you can reject is better than no PR at all + silent forks. The best I can gather from my atrocious code is that I just wanted proper left padding for the header columns?
Personally no use case for Docker for a single Go binary that's not networked, but if anybody has a use case and wants to automate through GitHub Actions or similar, totally open to the contribution.
I've found most people are more comfortable running a docker image than they are adding a binary to their path for easy use. Myself included - I don't like having a ton of different binaries hanging around, I'd rather just pull down a ~20Mb docker image to run a binary.
Probably shouldn't go to somebody else's repo though ;)
💯
@stevemcquaid oh yes great idea thanks, filed #43. Thanks for the perspective, I'm sold on the Docker image it's a recurring theme and I've baked carrying a bin/ around in my assumptions, just need the GitHub Actions integration with my secret only reachable from main and it's published.
I second @stevemcquaid usage. Also, dockerizing would add some sort of security due to confinement, both at filesystem level (fs jailing and gauth.txt R/O mounting) and network level ("None" network driver).
Also, hosting a Dockerfile in the repo would enable a "no checkout, straight from repo URL, any branch/tag" build:
# Build main
$ docker build -t gauth https://github.com/pcarrier/gauth.git#main
# Build some not-so-random PR :)
$ docker build -t gauth https://github.com/pcarrier/gauth.git#pull/23/head
No need for publishing to Docker Hub, initially. Although the Github Action is pretty easy and somebody might eventually get to it. For reference, see docker-publish.yml and its PRs and also check out anacrolix/dms#97.