Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions .scripts/linux/pipeline/build-images-core.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
#!/usr/bin/env bash

# The version we're building, defaults to dev
VERSION=0.0.0-devel
CLOUD_PROVIDER=local

# Read the version flag if given
num=0
for var in "$@"
do
eval flag="\$$num"

if [[ $flag == "--provider" ]]; then
((num=num+1))
eval CLOUD_PROVIDER="\$$num"
fi

if [[ $flag == "--version" ]]; then
((num=num+1))
eval VERSION="\$$num"
fi

((num=num+1))

done

# Define our base images
IMG_HTTP_SERVER="tensorworks/sps-http-server"

# Build all our core containers as background tasks
echo -e '*\n!bin/linux/amd64/*' > .dockerignore
docker build -t "$IMG_HTTP_SERVER:$VERSION-$CLOUD_PROVIDER" -f dockerfiles/http-server.dockerfile .

# push them containers to docker (3 at a time)
docker push "$IMG_HTTP_SERVER:$VERSION-$CLOUD_PROVIDER"