Skip to main content

Primary links

  • Home
  • AI
  • Kubernetes
  • Incus
  • Ansible
  • Terraform
  • OpenStack
  • Virtualization
  • Linux
  • SmartHome
  • HowTo

Misc

  • Linux
  • Hardware
  • Programming
  • Databases
  • Multimedia
  • Windows

Cloud

  • OpenStack
  • cloud-config
  • nextcloud

Virtualization

  • Virtualization
  • Incus
  • Docker
  • KVM
  • Kubernetes
  • LXC
  • LXD
  • QEMU
  • VMware
  • VirtualBox
  • multipass
  • podman
  • vagrant
  • XEN

Network

  • DNS
  • Firewall
  • Linux
  • OpenvSwitch
  • SSL
  • VLAN
  • VPN
  • iPXE
  • namespaces
  • nmcli
  • tcpdump

Storage

  • CEPH
  • DRBD
  • LVM
  • S3
  • ZFS
  • btrfs

Automation / CI/CD

  • Install
  • Ansible
  • GitLab
  • LLM
  • Preseed
  • Puppet
  • Terraform
  • Ubuntu autoinstall

Monitoring / Visualisation

  • Grafana
  • Icinga
  • Prometheus
  • Monitoring
  • ELK
  • mermaid
  • nginx
  • docker
  • container

Create required directories

mkdir -p /etc/docker/nginx/{conf.d,html}

Configure nginx as webserver

cat < /etc/docker/nginx/conf.d/default.conf
server {
    listen 80;
    server_name _;

    root   /usr/share/nginx/html; 
    index  index.html index.htm;
}
EOF

Configure nginx as proxy

cat < /etc/docker/nginx/conf.d/proxy.conf
server {
    listen 80;
    server_name foo.example.com;

    location / {
        proxy_pass http://localhost:8080/;
    }
}
EOF

Create container

sudo docker run -d \
  --name nginx \
  --net host \
  -v /etc/docker/nginx/html:/usr/share/nginx/html:ro \
  -v /etc/docker/nginx/conf.d:/etc/nginx/conf.d:ro \
  nginx

debug

docker restart nginx
docker logs nginx -f

Links
https://hub.docker.com/_/nginx

Profiles GitHub StackOverflow LinkedIn Xing
Contact Imprint
© panticz 2026

Cookie-Einstellungen

Diese Website nutzt eingebettete Inhalte von Drittanbietern (z.B. YouTube, SoundCloud). Beim Laden dieser Inhalte werden Daten an die jeweiligen Anbieter übermittelt. Datenverarbeitungserklärung