This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
prefix="[your-prefix-here]" | |
queues=$(aws sqs list-queues --queue-name-prefix $prefix) | |
for q in ${queues[@]} | |
do | |
if [ "${q:0:1}" == "\"" ]; then | |
x=${q:1:${#q}-3} | |
if [ $x != "QueueUrls" ]; then | |
aws sqs delete-queue --queue-url $x | |
fi | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
docker run --rm -it \ | |
-v /var/run/docker.sock:/var/run/docker.sock \ | |
-v $HOME/.docker:/root/.docker \ | |
-v $(pwd):/app \ | |
-e ACCOUNT=gnschenker \ | |
-e IMAGE=myapi \ | |
-e TAG=1.${bamboo.buildNumber} \ | |
gnschenker/builder:latest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
docker run --rm -it \ | |
-v /var/run/docker.sock:/var/run/docker.sock \ | |
-v $HOME/.docker:/root/.docker \ | |
-v $(pwd):/app \ | |
-e ACCOUNT=gnschenker \ | |
-e IMAGE=myapi \ | |
-e TAG=1.1 \ | |
gnschenker/builder:latest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
docker tag builder gnschenker/builder:0.1 | |
docker tag builder gnschenker/builder:latest | |
docker push gnschenker/builder:0.1 | |
docker push gnschenker/builder:latest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# build artifact | |
docker build -t $IMAGE /app | |
# test artifact | |
if [ -e /app/test/sh ]; then | |
/app/test.sh | |
fi | |
# tag artifact | |
docker tag $IMAGE $ACCOUNT/$IMAGE:$TAG |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM docker:1.12 | |
VOLUME /app | |
ENTRYPOINT /builder.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
docker push $ACCOUNT/$IMAGE_NAME:$TAG | |
docker push $ACCOUNT/$IMAGE_NAME:latest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
docker run --rm -it \ | |
-v /var/run/docker.sock:/var/run/docker.sock \ | |
-v $HOME/.docker:/root/.docker \ | |
-v $(pwd):/app \ | |
-w /app docker \ | |
./builder.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ACCOUNT=gnschenker | |
$TAG=1.0 | |
docker tag $IMAGE_NAME $ACCOUNT/$IMAGE_NAME:$TAG | |
docker tag $IMAGE_NAME $ACCOUNT/$IMAGE_NAME:latest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$IMAGE_NAME=myapi | |
docker build -t $IMAGE_NAME | |
docker run --rm -i --entrypoint test.sh $IMAGE_NAME |
NewerOlder