diff --git a/compose.dev.yaml b/compose.dev.yaml new file mode 100644 index 0000000..dd393b6 --- /dev/null +++ b/compose.dev.yaml @@ -0,0 +1,19 @@ +services: + oauth2-proxy: + image: quay.io/oauth2-proxy/oauth2-proxy:latest + command: --config /oauth2-proxy/oauth2-proxy.cfg + volumes: + - ./oauth2-proxy:/oauth2-proxy + ports: + - 4180:4180 + + docs: + build: + context: . + container_name: docs + restart: unless-stopped + env_file: .env + ports: + - ${PORT:-8081}:80 + depends_on: + - oauth2-proxy diff --git a/oauth2-proxy/oauth2-proxy.cfg b/oauth2-proxy/oauth2-proxy.cfg new file mode 100644 index 0000000..98f680c --- /dev/null +++ b/oauth2-proxy/oauth2-proxy.cfg @@ -0,0 +1,27 @@ +# Replace with your own credentials +client_id="54ac14e4-4e6b-46ce-a870-01b297421e89" +client_secret="W8r4ozypT4Qx23P0wa9pGHQAyUtmYOW8" +oidc_issuer_url="https://id.housh.dev" + +# Replace with a secure random string +cookie_secret="lGaySNwq1tNKd1pcji0IQrz7tPYbt2P8" + +# Upstream servers (e.g http://uptime-kuma:3001) +upstreams="http://docs:80" + +# Additional Configuration +provider="oidc" +scope = "openid email profile groups" + +# If you are using a reverse proxy in front of OAuth2 Proxy +reverse_proxy=false + +# Email domains allowed for authentication +email_domains="*" +insecure_oidc_allow_unverified_email="true" + +# If you are using HTTPS +cookie_secure="false" + +# Listen on all interfaces +http_address="0.0.0.0:4180"