`just` confusing
Alan Pearce alan@alanpearce.eu
Sun, 21 Apr 2024 23:18:53 +0200
2 files changed, 5 insertions(+), 7 deletions(-)
jump to
M gitlab-ci.yml → gitlab-ci.yml
@@ -29,7 +29,7 @@ - | if fly auth whoami > /dev/null 2>&1 then fly auth docker - just push-to-registry result --tmpdir=$TMPDIR + just push-to-registry docker://$(just evaluate fly-registry):$DOCKER_TAG result --tmpdir=$TMPDIR just print-docker-tag >> build.env fi artifacts:
M justfile → justfile
@@ -45,13 +45,11 @@ print-docker-tag: @echo {{ docker-tag }} -# docker://some_docker_registry/myimage:tag -stream-to-registry registry-and-tag=("docker://" + fly-registry + ":" + docker-tag) *skopeo-flags="": - just docker-stream-fly | gzip --fast | skopeo {{ skopeo-flags }} copy --dest-precompute-digests docker-archive:/dev/stdin {{ registry-and-tag }} +stream-to-registry *skopeo-flags="": + just docker-stream-fly | gzip --fast | skopeo {{ skopeo-flags }} copy --dest-precompute-digests docker-archive:/dev/stdin ("docker://" + fly-registry + ":" + docker-tag) -# docker://some_docker_registry/myimage:tag -push-to-registry registry-and-tag=("docker://" + fly-registry + ":" + docker-tag) image-path=`readlink -f result` *skopeo-flags="": - skopeo {{ skopeo-flags }} copy --dest-precompute-digests {{ image-path }} {{ registry-and-tag }} +push-to-registry *skopeo-flags="": + echo skopeo {{ skopeo-flags }} copy --dest-precompute-digests `readlink -f result` ("docker://" + fly-registry + ":" + docker-tag) deploy registry-and-tag=(fly-registry + ":" + docker-tag): fly deploy --image {{ registry-and-tag }}