2020-02-05 20:53:52 +00:00
|
|
|
#!/bin/bash
|
2020-04-03 13:53:47 +00:00
|
|
|
|
|
|
|
# Build and push Docker image to Docker Hub
|
2020-04-03 15:29:33 +00:00
|
|
|
echo "$DOCKER_TOKEN" | docker login -u "$DOCKER_USERNAME" --password-stdin
|
2020-04-03 13:53:47 +00:00
|
|
|
docker build --no-cache -t sartography/cr-connect-backend:latest . || exit 1;
|
|
|
|
docker push sartography/cr-connect-backend:latest || exit 1;
|
|
|
|
|
2020-04-23 18:47:07 +00:00
|
|
|
# Wait for Docker Hub
|
|
|
|
echo "Publishing to Docker Hub..."
|
|
|
|
sleep 30
|
|
|
|
|
2020-04-03 13:53:47 +00:00
|
|
|
# Notify UVA DCOS that Docker image has been updated
|
2020-04-23 18:47:07 +00:00
|
|
|
echo "Refreshing DC/OS..."
|
2020-04-03 13:53:47 +00:00
|
|
|
aws sqs send-message --queue-url 'https://queue.amazonaws.com/474683445819/dcos-refresh' --message-body 'crconnect/backend' || exit 1;
|