18 lines
455 B
Bash
Executable File
18 lines
455 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
# echo "hello"
|
|
# curl http://webdevcat.me:8080
|
|
image=miti.sh
|
|
|
|
echo "starting container..."
|
|
container_id=$(docker run --rm -d -v $(pwd):/opt/app -p 8080:8080 \
|
|
--add-host=miti.sh=127.0.0.1 \
|
|
--add-host=webdevcat.me=127.0.0.1 \
|
|
$image)
|
|
|
|
echo "container $container_id started"
|
|
echo "stopping container $container_id"
|
|
stop_cmd_result=$(docker stop $container_id)
|
|
echo "container $stop_cmd_result stopped"
|
|
# curl http://miti.sh:8080
|