# Deploy Miniflux via Docker and Cloudflare
## Metadata
**Status**:: #x
**Zettel**:: #zettel/literature
**Created**:: [[2023-02-15]]
**Tags**:: #docker #docker-compose
## Synopsis
[Miniflux](https://miniflux.app/) is a minimalist and opinionated RSS feed reader.
Generate the certificates for Origin Server from Cloudflare and save into the `certs` folder.
Create `docker-compose.yml`. Replace the password and cert domain.
> [!file]- docker-compose.yml
> ```yaml
> version: '3.4'
> services:
> miniflux:
> image: miniflux/miniflux:latest
> ports:
> - "443:8080"
> depends_on:
> - db
> volumes:
> - $PWD/certs:/certs
> environment:
> - DATABASE_URL=postgres://miniflux:secret@db/miniflux?sslmode=disable
> - RUN_MIGRATIONS=1
> - CREATE_ADMIN=1
> - CERT_FILE=/certs/server.crt
> - KEY_FILE=/certs/server.key
> - HOSTNAME=***
> - ADMIN_USERNAME=admin
> - ADMIN_PASSWORD=***
> db:
> image: postgres:15
> environment:
> - POSTGRES_USER=miniflux
> - POSTGRES_PASSWORD=secret
> volumes:
> - miniflux-db:/var/lib/postgresql/data
> healthcheck:
> test: ["CMD", "pg_isready", "-U", "miniflux"]
> interval: 10s
> start_period: 30s
> volumes:
> miniflux-db:
> ```
>
Start services:
```
# db first
docker-compose up -d db
docker-compose up -d miniflux
```
Set up Cloudflare Proxy to enable the SSL.