Skip to content

Instantly share code, notes, and snippets.

@dkatz23238
Created March 28, 2019 03:07
Show Gist options
  • Save dkatz23238/0a8df5b6dcfe44bc2b20d929bcdf7664 to your computer and use it in GitHub Desktop.
Save dkatz23238/0a8df5b6dcfe44bc2b20d929bcdf7664 to your computer and use it in GitHub Desktop.
Execution shell script from docker-compose to within a docker container running an x11vnc server
docker-compose exec <container name> sh -c "COMMAND1 && COMMAND2 && COMMAND3 && ... "
# If GUI apps need to be started the following code can be used
docker-compose exec <container name> sh -c "export DISPLAY=:1"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment