Skip to content

Commit

Permalink
stop-ls.sh now stops containers started by localstack so lambdas dont…
Browse files Browse the repository at this point in the history
… get orphaned
  • Loading branch information
paulrobello committed Oct 23, 2023
1 parent ace3150 commit de775b4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ services:
- PROXY_VOLUME_DIR # where to persist cert files. defaults to /tmp/mitproxy
- PROXY_URL # http(s) proxy to use. if USE_PROXY_HOST is enabled will be set to http://PROXY_CONTAINER_NAME:8080
- PROXY_AUTO_EXPORT_ENV # auto export HTTP_PROXY and HTTPS_PROXY vars equal to PROXY_URL
- DEV_CONTAINER=1.9.5 # used to detect if running inside dev container
- DEV_CONTAINER=1.9.6 # used to detect if running inside dev container
volumes:
- /var/run/docker.sock:/var/run/docker.sock # allow container to interact with host docker
- "${GDC_DIR}:/root/gdc-host" # mount gdc folder inside container to get access to compose files
Expand Down
3 changes: 2 additions & 1 deletion root/bin/ls/stop-ls.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ if [[ "$1" = "--help" || "$1" = "-h" ]]; then
exit 0
fi


docker rm -f "$LS_MAIN_CONTAINER_NAME"
docker ps -a --format '{{.Names}}' | grep "^$(echo "$LS_MAIN_CONTAINER_NAME-" | tr "_" "-")" | xargs -I {} docker rm -f {}

sleep 2

0 comments on commit de775b4

Please sign in to comment.