From 461956b549c8401efe6fc56220de929ac7f06910 Mon Sep 17 00:00:00 2001 From: pazpi Date: Mon, 5 May 2025 22:47:59 +0200 Subject: [PATCH] Add Docker Compose files for Open WebUI and Watchtower services --- containers/README.md | 3 +++ containers/open-webui/docker-compose.yml | 27 ++++++++++++++++++++++++ containers/watchtower/docker-compose.yml | 21 ++++++++++++++++++ 3 files changed, 51 insertions(+) create mode 100644 containers/README.md create mode 100644 containers/open-webui/docker-compose.yml create mode 100644 containers/watchtower/docker-compose.yml diff --git a/containers/README.md b/containers/README.md new file mode 100644 index 0000000..b0ef27c --- /dev/null +++ b/containers/README.md @@ -0,0 +1,3 @@ +# Containers + +Easy to deploy in portainer that nix \ No newline at end of file diff --git a/containers/open-webui/docker-compose.yml b/containers/open-webui/docker-compose.yml new file mode 100644 index 0000000..099b1ea --- /dev/null +++ b/containers/open-webui/docker-compose.yml @@ -0,0 +1,27 @@ +services: + openwebui: + image: ghcr.io/open-webui/open-webui:main + ports: + - "4000:8080" + volumes: + - open-webui:/app/backend/data + environment: + WEBUI_URL: https://ai.${DOMAIN} + ENABLE_OPENAI_API: true + OPENAI_API_BASE_URL: http://open-webui.home:12345 + ENABLE_OLLAMA_API: false + ENABLE_WEB_SEARCH: true + WEB_SEARCH_ENGINE: searxng + SEARXNG_QUERY_URL: https://search.${DOMAIN}/search?q= + OAUTH_CLIENT_ID: ${OAUTH_CLIENT_ID} + OAUTH_CLIENT_SECRET: ${OAUTH_CLIENT_SECRET} + OAUTH_PROVIDER_NAME: authentik + OPENID_PROVIDER_URL: https://auth.${DOMAIN}/application/o/openwebui/.well-known/openid-configuration + OPENID_REDIRECT_URI: https://ai.${DOMAIN}/oauth/oidc/callback + ENABLE_OAUTH_SIGNUP: true + ENABLE_LOGIN_FORM: false + labels: + - "com.centurylinklabs.watchtower.enable=true" + +volumes: + open-webui: \ No newline at end of file diff --git a/containers/watchtower/docker-compose.yml b/containers/watchtower/docker-compose.yml new file mode 100644 index 0000000..568ac92 --- /dev/null +++ b/containers/watchtower/docker-compose.yml @@ -0,0 +1,21 @@ +services: + watchtower: + image: containrrr/watchtower + container_name: watchtower + extends: + file: "../base.yml" + service: base + volumes: + - /var/run/docker.sock:/var/run/docker.sock + environment: + - TZ=Europe/Rome + - WATCHTOWER_SCHEDULE=0 0 4 * * * + - WATCHTOWER_CLEANUP=true + - WATCHTOWER_LABEL_ENABLE=true + - WATCHTOWER_NOTIFICATIONS=shoutrrr + - WATCHTOWER_NOTIFICATION_URL=telegram://${BOT_TOKEN}@telegram/?channels=${CHAT_ID} + labels: + - "com.centurylinklabs.watchtower.enable=true" + +volumes: + open-webui: \ No newline at end of file