Skip to content

Commit

Permalink
revised buildah script to use new buildah features
Browse files Browse the repository at this point in the history
  • Loading branch information
buckaroogeek committed Sep 27, 2021
1 parent 8f73db3 commit e93fdff
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 27 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ doh-server/doh-server
.glide/

.idea/
notes-podman

# tmp folder
tmp/*
Expand Down
3 changes: 3 additions & 0 deletions notes-buildah/Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,6 @@ The notes-buildah directory contains a shell script with the 'multi' filename. T
## Usage
1. Authenticate with the repository (e.g. 'buildah login docker.io'.
2. Run script from reposity root (for correct path resolution).


buildah manifest create and buildah manifest push
21 changes: 5 additions & 16 deletions notes-buildah/multi
Original file line number Diff line number Diff line change
@@ -1,22 +1,11 @@
#! /bin/bash

DTAG="2.2.8"
# simple script that uses buildah multiarch build and then pushs resulting image
# to docker hub
# need to buildah login first

declare -A image
for arch in amd64 arm64 ; do
buildah bud --override-arch $arch --iidfile iid Dockerfile.client
image[$arch]=$(cat iid)
done
DTAG="2.2.12"

buildah manifest create doh-client:$DTAG

for arch in ${!image[@]} ; do
flags=
case $arch in
arm64|aarch64)
flags="--arch arm64 --variant v8"
esac
buildah manifest add doh-client:$DTAG $flags ${image[$arch]}
done
buildah bud --platform linux/amd64,linux/arm64 --manifest doh-client:$TAG ./Dockerfile.client

buildah manifest push --all doh-client:$DTAG docker://buckaroogeek/doh-client:$DTAG
5 changes: 0 additions & 5 deletions notes-podman/Read.me

This file was deleted.

6 changes: 0 additions & 6 deletions notes-podman/podman-sequence.txt

This file was deleted.

0 comments on commit e93fdff

Please sign in to comment.