Compare commits
No commits in common. "495a03b8a95ed947b73f9441f01a1bc6687694b3" and "1f4945fa4b237f4f43dd8c0d562ce1819a2b409f" have entirely different histories.
495a03b8a9
...
1f4945fa4b
1 changed files with 0 additions and 18 deletions
|
@ -1,18 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
script_dir=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
|
|
||||||
repo="$(basename "${script_dir}")"
|
|
||||||
tag="${1}"
|
|
||||||
if [ -z "${tag}" ]; then
|
|
||||||
git_reference=$(grep '^ref: ' .git/HEAD | awk 'BEGIN {FS="/"} {print($NF)}')
|
|
||||||
if [ "${git_reference}" == 'master' ] || [ "${git_reference}" == 'main' ] || [ -z "${git_reference}" ]; then
|
|
||||||
echo "Change to a different git reference not 'master/main', since it will be used as tag for the container. Or pass a tag name as only parameter."
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
tag="${git_reference}"
|
|
||||||
fi
|
|
||||||
echo "Building '${repo}:${tag}'..."
|
|
||||||
podman build --tag "${repo}:${tag}" .
|
|
||||||
echo "Tagging it to 'repos.susurrando.com/adelgado/${repo}:${tag}'..."
|
|
||||||
podman tag "${repo}:${tag}" "repos.susurrando.com/adelgado/${repo}:${tag}"
|
|
||||||
echo "Pushing it to 'repos.susurrando.com/adelgado/${repo}:${tag}'..."
|
|
||||||
podman push "repos.susurrando.com/adelgado/${repo}:${tag}"
|
|
Loading…
Reference in a new issue