create abc-toolbox docker image

This commit is contained in:
2021-03-13 10:04:22 -05:00
parent 7bd452a2a7
commit 5b78e3ba17
8 changed files with 87 additions and 0 deletions

View File

@@ -0,0 +1,15 @@
#FROM ubuntu:21.04
#RUN apt-get update && ap-get install build-essential
FROM alpine/git
RUN apk add --update alpine-sdk
RUN mkdir -p /project
WORKDIR /project
RUN git clone https://git.xai-corp.net/richard/abcmidi.git /project
RUN make all install
WORKDIR /
COPY entrypoint.sh /entrypoint.sh
ENTRYPOINT ["/entrypoint.sh"]

View File

@@ -0,0 +1,49 @@
#!/usr/bin/env bash
set -e
LOCAL_IMAGE=xaicorp/abc-toolbox
TAG=latest
REMOTE_IMAGE=dkregistry.xai-corp.net:5000/${LOCAL_IMAGE}:${TAG}
build() {
docker build --rm -f Dockerfile -t ${LOCAL_IMAGE} .
}
build_test() {
echo testing the image
docker run --rm $LOCAL_IMAGE abc2midi -ver | grep 'abc2midi'
#docker run --rm -it -v $(pwd):/opt xaicorp/abc-toolbox abc2midi /opt/tests/abc1.abc -cvt
}
build_deploy() {
echo push to registry
docker tag $LOCAL_IMAGE $REMOTE_IMAGE
docker push $REMOTE_IMAGE
}
print_usage() {
printf "Usage: %s: [-b] [-t] [-d] \n" "$0"
echo -b build
echo -t test
echo -d push to registry
echo -h help
exit 0
}
######
if [ -z "$1" ]; then
build && build_test && build_deploy
exit
fi
while getopts btdh name
do
case $name in
b) build;;
t) build_test;;
d) build_deploy;;
*) print_usage;;
esac
done

View File

@@ -0,0 +1,3 @@
ARGS - The arguments you wish to provide to this command
TODO: Fill out the help information for this command.

View File

@@ -0,0 +1 @@
ARGS...

View File

@@ -0,0 +1,4 @@
#!/usr/bin/env sh
set -ex
exec $@

View File

@@ -0,0 +1,15 @@
X: 1
T: Struan And Frazer's
Z: Josh
S: https://thesession.org/tunes/14951#setting27622
R: reel
M: 4/4
L: 1/8
K: Bmin
|: f2 ef BBdB | feef Bffd | ecce AeeA | ccAe cdec |
f2 ef BBdB | feef Bffd | ecce Aeec | effA B2 de :|
fBBB aBBB | fBBa BBfd | ecce AeeA | ccBc ABce |
fBBB aBBB | fBBa BBfd | ecce Aeec | effA B2 de ||
fBBa BBfB | fBBa BBfd | ecce AeeA | ccBc ABce |
fBBa BBfB | fBBa BBfd | ecce Aeec | effA B2 de |]

Binary file not shown.