Skip to content

Instantly share code, notes, and snippets.

@JohnnySixarms
Last active February 10, 2018 10:08
Show Gist options
  • Save JohnnySixarms/fff9b568babc5c3026eb79ba7e745f13 to your computer and use it in GitHub Desktop.
Save JohnnySixarms/fff9b568babc5c3026eb79ba7e745f13 to your computer and use it in GitHub Desktop.
apache2 as a dockerservice
docker service create \
--name apache2 \
--publish 80:80/tcp \
--publish 443:443/tcp \
--constraint node.role==manager \
--mount type=bind,src=//opt/apache2/var/log/apache2,dst=/var/log/apache2 \
--mount type=bind,src=//opt/apache2/var/www,dst=/var/www \
--mount type=bind,src=//opt/apache2/etc/apache2,dst=/etc/apache2 \
johnnysixarms/debian_httpd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment