Skip to content
Snippets Groups Projects
Commit 66cebf69 authored by Lennart Kramer's avatar Lennart Kramer
Browse files

further modifications to build

parent 2bfe46c9
No related branches found
No related tags found
No related merge requests found
...@@ -21,6 +21,8 @@ $ ./buildweb.sh ...@@ -21,6 +21,8 @@ $ ./buildweb.sh
$ ./buildimage.sh 2020061000 $ ./buildimage.sh 2020061000
``` ```
The image should then be available as `goemaxima:2020061000-dev`.
License License
======= =======
......
...@@ -2,5 +2,5 @@ REGISTRY=$1 ...@@ -2,5 +2,5 @@ REGISTRY=$1
grep -v '^#' versions | cut -f1 | \ grep -v '^#' versions | cut -f1 | \
while read -r ver; do while read -r ver; do
goemaxima_version="$2" goemaxima_version="$2"
bash ./buildimage.sh "$ver" "${REGISTRY}" "$goemaxima_version" || exit 1 ./buildimage.sh "$ver" "${REGISTRY}" "$goemaxima_version" || exit 1
done done
...@@ -6,10 +6,11 @@ stackver="$1" ...@@ -6,10 +6,11 @@ stackver="$1"
if [ -z "$stackver" ]; then if [ -z "$stackver" ]; then
echo "Stack version is missing" echo "Stack version is missing"
echo "Usage: $0 stackmaximaversion [registry] [containerversion]" echo "Usage: $0 stackmaximaversion [registry] [containerversion]"
exit 1
fi fi
verstring=$(awk '$1 == "'"$1"'"{ print $0 }' versions) verstring=$(awk '$1 == "'"$1"'"{ print $0 }' versions)
sbclver="$(echo "$verstring" | cut -f2)" maximaver="$(echo "$verstring" | cut -f2)"
maximaver="$(echo "$verstring" | cut -f3)" sbclver="$(echo "$verstring" | cut -f3)"
goemaxver="$(cat goemaxima_version)" goemaxver="$(cat goemaxima_version)"
libpath="stack/$stackver/maxima" libpath="stack/$stackver/maxima"
echo "starting to build image for:" echo "starting to build image for:"
...@@ -23,11 +24,11 @@ if [ -n "$REG" ]; then ...@@ -23,11 +24,11 @@ if [ -n "$REG" ]; then
docker pull "$2/$IMAGENAME-dev" docker pull "$2/$IMAGENAME-dev"
fi fi
# build it # build it
docker build -t "${IMAGENAME}" --build-arg MAXIMA_VERSION="$maximaver" --build-arg SBCL_VERSION="$sbclver" --build-arg LIB_PATH="$libpath" . || exit 1 docker build -t "${IMAGENAME}-dev" --build-arg MAXIMA_VERSION="$maximaver" --build-arg SBCL_VERSION="$sbclver" --build-arg LIB_PATH="$libpath" . || exit 1
echo "${IMAGENAME} wurde erfolgreich gebaut." echo "${IMAGENAME} wurde erfolgreich gebaut."
# push the image # push the image
if [ -n "$REG" ]; then if [ -n "$REG" ]; then
docker tag "$IMAGENAME" "$2/$IMAGENAME-dev" docker tag "$IMAGENAME-dev" "$2/$IMAGENAME-dev"
docker push "$2/$IMAGENAME-dev" docker push "$2/$IMAGENAME-dev"
if [ -n "$3" ]; then if [ -n "$3" ]; then
docker tag "$IMAGENAME" "$2/$IMAGENAME-$3" docker tag "$IMAGENAME" "$2/$IMAGENAME-$3"
......
#!/bin/bash #!/bin/sh
set -e set -e
echo ${MAXIMA_VERSION?Error \$MAXIMA_VERSION is not defined} \ echo ${MAXIMA_VERSION?Error \$MAXIMA_VERSION is not defined} \
${SBCL_VERSION?Error \$SBCL_VERSION is not defined} ${SBCL_VERSION?Error \$SBCL_VERSION is not defined}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment