docker¶
exec as other user (e.G. root)¶
with docker exec
(where ac0
is the container id):
or with docker-compose
(znc is the container name):
docker logs¶
the default json
log can become pretty large if you're running a container for weeks. there are multiple options for logging, to simply use syslog globally for all containers:
create or edit /etc/docker/daemon.json
:
or like this:
changes in the daemon.json
only apply to new containers, not existing.
docker cleanup¶
get rid of exited containers:
get rid of unused images:
ipv6¶
this will never end
enable ipv6 in docker container¶
I just want my nginx or traefik container to be available from the outside, man. Since I couldn't find anything meaningful out there on the interwebs I assume something is dangerously wrong with my config, but it works.
docker-compose.yaml
example (from mailcow):
networks:
proxynet:
name: awesomenet
driver: bridge
enable_ipv6: true
ipam:
driver: default
config:
- subnet: fd4d:6169:6c63:6f77::/64
more docker ipv6 stuff¶
this is for your /etc/docker/daemon.json
file. it might not exist.