initial revision

This commit is contained in:
Jason Swank
2023-12-02 21:16:07 +00:00
commit 009bff7106
11 changed files with 268 additions and 0 deletions

21
justfile Normal file
View File

@@ -0,0 +1,21 @@
set dotenv-load
tag := `grep ^FROM Dockerfile | cut -d: -f2`
image := "jswank/aws-cli"
registry := "ghcr.io"
registry_user := "jswank"
# this environment variable will be passed to podman login as the password
registry_pass_var := "REGISTRY_PASSWORD"
# build a new image
build flags="":
podman build -t {{image}}:{{tag}} {{flags}} -f Dockerfile ctx
# publish the image
publish alt_tag=tag:
@ podman tag {{image}}:{{tag}} {{registry}}/{{image}}:{{alt_tag}}
@ echo "${{ registry_pass_var }}" | podman login {{registry}} -u {{registry_user}} --password-stdin
@ podman push {{registry}}/{{image}}:{{alt_tag}}
@ podman logout {{registry}}