Skip to content

Instantly share code, notes, and snippets.

@srusskih
Created October 31, 2023 08:42
Show Gist options
  • Save srusskih/cc3e2c85194c2467027f52de7387175f to your computer and use it in GitHub Desktop.
Save srusskih/cc3e2c85194c2467027f52de7387175f to your computer and use it in GitHub Desktop.
#!/bin/env bash
NAME=$1
CONTAINER_ID=$(docker ps | grep $NAME | awk '{printf $1;}')
docker exec -it $CONTAINER_ID bash
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment