Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/sashkab/docker-caddy2
https://github.com/sashkab/docker-caddy2
Last synced: 17 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/sashkab/docker-caddy2
- Owner: sashkab
- Created: 2020-07-03T12:52:27.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2024-09-20T15:07:00.000Z (3 months ago)
- Last Synced: 2024-11-18T02:45:34.662Z (about 1 month ago)
- Language: Dockerfile
- Size: 53.7 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# docker-caddy2
Run [Caddy][1] v2 webserver inside a docker container.
## Usage
### Command line
Create directories:
```sh
mkdir www caddy
``````sh
docker run -it --rm -v $(pwd)/Caddyfile:/etc/caddy/Caddyfile \
-v $(pwd)/caddy:/caddy -v $(pwd)/www:/www docker.pkg.github.com/sashkab/docker-caddy2/docker-caddy2:latest
```### docker-compose
```yaml
version: "3"services:
caddy:
image: docker.pkg.github.com/sashkab/docker-caddy2/docker-caddy2:latest
restart: always
volumes:
- ./Caddyfile:/etc/caddy/Caddyfile:ro
- caddy2:/caddy
- ./path/to/www:/www
ports:
- "80:80"
- "443:443"volumes:
caddy2:
```[1]: https://github.com/caddyserver/caddy