PWD is a Docker playground that allows launching and using Docker Containers in your browser within seconds. You don’t need to install anything!!!
Just visit https://labs.play-with-docker.com, log in with you Docker Hub user and play around with a free Alpine Linux Docker Container in your browser.
Of course, the base Alpine Linux container supports Docker-in-Docker (DinD), so it’s up to you to launch any containers of your choice and even create clusters in Docker Swarm Mode.
How does it look like?
Play with Docker provides a simple but effective web-user-interface. Each session is limited to four hours, but in fact, this is always enough for demos, testing, and training purpose.
In the following part, I shortly describe my personal top core features of Play with Docker.
Showcasing your application
(One-click on-demand demo instance of our application)
You published a project and would like to provide an on-demand testing instance?
Using PWD you can provide a showcasing instance with a single click.
Basically you need to provide two things:
- Your application as a ready to use Docker Compose raw file.
- The base PWD-URL extended with your Docker official image or Docker Compose file.
Note: Since PWD uses Docker stack deploy to provide the container, you are not able to build new images. Check documentation for configuration keys available using Docker stack deploy.
Ports can also be exposed as shown in the Nginx-example.
PWD automatically exposes ports defined in the Docker Compose file and provides a link next to “OPEN PORT”.
Hint: In case you would like to include your application showcasing URL as a button like above on your website or Github Readme, just add the following snippet.
<a href="https://labs.play-with-docker.com?stack=https://gitlab.com/fabian.guschlbauer/play-with-docker/-/raw/master/docker-compose.yml"><img src="https://cdn.rawgit.com/play-with-docker/stacks/cff22438/assets/images/button.png" alt="Try in PWD"></a>
Uploading files into a PWD instance is a simple but powerful feature, especially because there is nearly no use-case were you do not need any script, dockerfile, or something like this inside your container.
PWD Docker Machine Driver and SSH
Are you looking forward to your next fancy live demo, interactive presentation session, or workshop and want to use your favorite terminal?
PWD Machine Driver allows you to create and manage your PWD instances easily through your favorite terminal.
To install PWD Machine Driver follow the instructions from the project’s readme.
Use the PWD Machine Driver:
- Get the session URL of PWD from your browser and export it into the PWD_URL environment variable.
Instead of specifying the PWD_URL environment variable, you could use the
--pwd-urloption of the PWD Machine Driver.
- Create a new instance “node2” using
docker-machine create -d pwd node2
- SSH connect using
docker-machine ssh node2