Tips & Tricks
Clean every unused images, containers, networks & build cache)
Delete all containers at once
Build image in docker compose
It is possible to build an image directly inside docker compose.
Even better, you can specify a branch, example for dev branch:
Get container start command
You started a container with docker run CLI but you forgot the command you used ? You can kinda get it back with these steps:
Get your container ID (you can just take a few char if you want):
Run this with your ID at the end (lets say b0ca0c234177):
If you think you'll use it frequently you can add an alias to your ~/.bashrc or ~/.zshrc:
After restarting your terminal, you can use it like this:
Run GUI apps in docker in WSL2 using WSLg
If fonts are missing in your app, it may be necessary to install fonts, on alpine I needed to run this for firefox to work properly:
Last updated