cuddle-rust-service-plan/scripts/run_release.sh

18 lines
228 B
Bash
Raw Normal View History

2022-08-11 01:05:47 +02:00
#!/bin/bash
2022-08-11 01:09:16 +02:00
set -e
2022-08-11 01:05:47 +02:00
echo "prebuiliding docker image"
2022-08-11 01:06:24 +02:00
cuddle_cli x build_release
2022-08-11 01:05:47 +02:00
echo "running docker image"
tag="$REGISTRY/$NAME:$COMMIT_SHA"
2022-08-11 01:09:16 +02:00
container_id=$(docker run --rm -d "$tag")
2022-08-11 01:05:47 +02:00
2022-08-11 01:09:16 +02:00
sleep 5s
2022-08-11 01:05:47 +02:00
2022-08-11 01:09:16 +02:00
docker stop "$container_id"