From 94d32c193c5d18556e56ce95af7f4fe2614f5176 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 12:19:39 -0600 Subject: [PATCH 01/23] Create Caddyfile --- caddy/Caddyfile | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 caddy/Caddyfile diff --git a/caddy/Caddyfile b/caddy/Caddyfile new file mode 100644 index 0000000..cfe25a7 --- /dev/null +++ b/caddy/Caddyfile @@ -0,0 +1,3 @@ +subdomain.duckdns.org { + reverse_proxy 127.0.0.1:7000 +} From ecb14e38d16d90979c75138dd8ff52170839d090 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 12:20:10 -0600 Subject: [PATCH 02/23] Delete caddy directory --- caddy/Caddyfile | 3 --- 1 file changed, 3 deletions(-) delete mode 100644 caddy/Caddyfile diff --git a/caddy/Caddyfile b/caddy/Caddyfile deleted file mode 100644 index cfe25a7..0000000 --- a/caddy/Caddyfile +++ /dev/null @@ -1,3 +0,0 @@ -subdomain.duckdns.org { - reverse_proxy 127.0.0.1:7000 -} From 3091e1bbeffe67ab38b2b4979932f40b2f950a30 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 12:20:42 -0600 Subject: [PATCH 03/23] Add files via upload --- Caddyfile | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 Caddyfile diff --git a/Caddyfile b/Caddyfile new file mode 100644 index 0000000..cfe25a7 --- /dev/null +++ b/Caddyfile @@ -0,0 +1,3 @@ +subdomain.duckdns.org { + reverse_proxy 127.0.0.1:7000 +} From ddd961f3ca7513ac90697082d696e295c5ba7334 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 12:21:01 -0600 Subject: [PATCH 04/23] Delete Caddyfile --- Caddyfile | 3 --- 1 file changed, 3 deletions(-) delete mode 100644 Caddyfile diff --git a/Caddyfile b/Caddyfile deleted file mode 100644 index cfe25a7..0000000 --- a/Caddyfile +++ /dev/null @@ -1,3 +0,0 @@ -subdomain.duckdns.org { - reverse_proxy 127.0.0.1:7000 -} From 96c4c36111550c1f335f3d87a030b73add5a0bf8 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 12:21:18 -0600 Subject: [PATCH 05/23] Add files via upload --- deployment/docker/Caddyfile | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 deployment/docker/Caddyfile diff --git a/deployment/docker/Caddyfile b/deployment/docker/Caddyfile new file mode 100644 index 0000000..cfe25a7 --- /dev/null +++ b/deployment/docker/Caddyfile @@ -0,0 +1,3 @@ +subdomain.duckdns.org { + reverse_proxy 127.0.0.1:7000 +} From 3ae6e5774bfbc31778ffaec2cf74ff11f16286c5 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 12:22:41 -0600 Subject: [PATCH 06/23] Update docker-compose.yaml --- deployment/docker/docker-compose.yaml | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/deployment/docker/docker-compose.yaml b/deployment/docker/docker-compose.yaml index ab2687e..48fe8ba 100644 --- a/deployment/docker/docker-compose.yaml +++ b/deployment/docker/docker-compose.yaml @@ -127,7 +127,20 @@ services: <<: *knightcrawler-app networks: - knightcrawler-network - + + caddy: + image: caddy:latest + restart: unless-stopped + ports: + - "80:80" + - "443:443" + - "443:443/udp" + volumes: + - ./Caddyfile:/etc/caddy/Caddyfile + - ./site:/srv + - caddy_data:/data + - caddy_config:/config + networks: knightcrawler-network: driver: bridge @@ -137,3 +150,5 @@ volumes: postgres: mongo: rabbitmq: + caddy_data: + caddy_config: From 7333aa1d73ab44113392410e2e63557949d7a3e3 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 12:51:23 -0600 Subject: [PATCH 07/23] Update README.md --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 43d316d..729327f 100644 --- a/README.md +++ b/README.md @@ -20,6 +20,7 @@ Join our [Discord](https://discord.gg/8fQdxay9z2)! - [Environment Setup](#environment-setup) - [Optional Configuration Changes](#optional-configuration-changes) - [DebridMediaManager setup (optional)](#debridmediamanager-setup-optional) + - [Configure external access](#configure-external-access) - [Run the project](#run-the-project) - [Monitoring with Grafana and Prometheus (Optional)](#monitoring-with-grafana-and-prometheus-optional) - [Accessing RabbitMQ Management](#accessing-rabbitmq-management) @@ -94,6 +95,10 @@ We can search DebridMediaManager hash lists which are hosted on GitHub. This all ``` GithubSettings__PAT= ``` +### Configure external access +What you will need: + 1. Domain or subdomain that points toward your ip. You can use [DuckDNS](duckdns.org) for a free subdomain. + 2. Ports 80 and 443 opened on your router/gateway. Refer to [PortForward.com](https://portforward.com/) ### Run the project From 4fdbb6679a632c2963ee8d713360f4003e110847 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 12:52:01 -0600 Subject: [PATCH 08/23] Update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 729327f..8d32ce1 100644 --- a/README.md +++ b/README.md @@ -97,8 +97,8 @@ We can search DebridMediaManager hash lists which are hosted on GitHub. This all ``` ### Configure external access What you will need: - 1. Domain or subdomain that points toward your ip. You can use [DuckDNS](duckdns.org) for a free subdomain. - 2. Ports 80 and 443 opened on your router/gateway. Refer to [PortForward.com](https://portforward.com/) +1. Domain or subdomain that points toward your ip. You can use [DuckDNS](duckdns.org) for a free subdomain. +2. Ports 80 and 443 opened on your router/gateway. Refer to [PortForward.com](https://portforward.com/) ### Run the project From 6af0e6d9f5aac7057fce39369c942af20561baec Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 12:54:04 -0600 Subject: [PATCH 09/23] Update README.md --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 8d32ce1..eb947b1 100644 --- a/README.md +++ b/README.md @@ -100,6 +100,7 @@ What you will need: 1. Domain or subdomain that points toward your ip. You can use [DuckDNS](duckdns.org) for a free subdomain. 2. Ports 80 and 443 opened on your router/gateway. Refer to [PortForward.com](https://portforward.com/) +Replace `subdomain.com` with your domain name in the Caddyfile; `knightcrawler/development/docker/Caddyfile`. ### Run the project From 84890c4366bf3892ce9ae39b2d9e4ac2ed47f72f Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 12:55:15 -0600 Subject: [PATCH 10/23] Update Caddyfile --- deployment/docker/Caddyfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deployment/docker/Caddyfile b/deployment/docker/Caddyfile index cfe25a7..f079a2b 100644 --- a/deployment/docker/Caddyfile +++ b/deployment/docker/Caddyfile @@ -1,3 +1,3 @@ -subdomain.duckdns.org { +your-domain.com { reverse_proxy 127.0.0.1:7000 } From c64ca7bce48ef4057e005ac9d3fc0296d60de9c4 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 12:58:17 -0600 Subject: [PATCH 11/23] Update README.md --- README.md | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index eb947b1..51d53ae 100644 --- a/README.md +++ b/README.md @@ -96,11 +96,12 @@ We can search DebridMediaManager hash lists which are hosted on GitHub. This all GithubSettings__PAT= ``` ### Configure external access -What you will need: -1. Domain or subdomain that points toward your ip. You can use [DuckDNS](duckdns.org) for a free subdomain. -2. Ports 80 and 443 opened on your router/gateway. Refer to [PortForward.com](https://portforward.com/) -Replace `subdomain.com` with your domain name in the Caddyfile; `knightcrawler/development/docker/Caddyfile`. +What you will need: +1. Domain or subdomain that points toward your ip. You can use [DuckDNS](duckdns.org) for a free subdomain. [Installation instructions](http://www.duckdns.org/install.jsp) are provided to keep your IP updated. +2. Ports 80 and 443 opened on your router/gateway adn forwarded to your KNightcrawler server. Refer to [PortForward.com](https://portforward.com/). + +Replace `your-domain.com` with your domain name in the Caddyfile; `knightcrawler/development/docker/Caddyfile`. ### Run the project From 6f3315ae0f83afc5c1f8ed48a3de6774c791587c Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 13:00:39 -0600 Subject: [PATCH 12/23] Update README.md --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index 51d53ae..0cd169d 100644 --- a/README.md +++ b/README.md @@ -310,5 +310,4 @@ This command should return: `ALTER DATABASE`. This means your database is now re ## To-do -- [ ] Add a section on external access - [ ] Add a troubleshooting section From f396dcca3e6fdf8fc5ca7c9ba39c216209179976 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 21:15:04 -0600 Subject: [PATCH 13/23] I've commented out Caddy in the docker-compose.yaml file and included a message describing the security vulnerabilities associated with enabling it. --- deployment/docker/docker-compose.yaml | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/deployment/docker/docker-compose.yaml b/deployment/docker/docker-compose.yaml index 48fe8ba..a9c224d 100644 --- a/deployment/docker/docker-compose.yaml +++ b/deployment/docker/docker-compose.yaml @@ -127,19 +127,20 @@ services: <<: *knightcrawler-app networks: - knightcrawler-network - - caddy: - image: caddy:latest - restart: unless-stopped - ports: - - "80:80" - - "443:443" - - "443:443/udp" - volumes: - - ./Caddyfile:/etc/caddy/Caddyfile - - ./site:/srv - - caddy_data:/data - - caddy_config:/config + +# Remove the #'s to activate Caddy for external access. Please note that this action may pose security vulnerabilities and potential damage for which Knightcrawler and its contributors cannot be held responsible. +# caddy: +# image: caddy:latest +# restart: unless-stopped +# ports: +# - "80:80" +# - "443:443" +# - "443:443/udp" +# volumes: +# - ./Caddyfile:/etc/caddy/Caddyfile +# - ./site:/srv +# - caddy_data:/data +# - caddy_config:/config networks: knightcrawler-network: From b6bfa0723adbbda64b5f4589f74467d62943ff2e Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 21:19:12 -0600 Subject: [PATCH 14/23] Fixed typos and added an additional message describing security vulnerabilities associated with forwarding ports. --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 0cd169d..c3dc41d 100644 --- a/README.md +++ b/README.md @@ -98,8 +98,8 @@ We can search DebridMediaManager hash lists which are hosted on GitHub. This all ### Configure external access What you will need: -1. Domain or subdomain that points toward your ip. You can use [DuckDNS](duckdns.org) for a free subdomain. [Installation instructions](http://www.duckdns.org/install.jsp) are provided to keep your IP updated. -2. Ports 80 and 443 opened on your router/gateway adn forwarded to your KNightcrawler server. Refer to [PortForward.com](https://portforward.com/). +1. Domain or subdomain that points toward your IP. You can use [DuckDNS](duckdns.org) for a free subdomain. [Installation instructions](http://www.duckdns.org/install.jsp) are provided to keep your IP updated. +2. Ports 80 and 443 opened on your router/gateway and forwarded to your Knightcrawler server. Refer to [PortForward.com](https://portforward.com/). Please note that this action may pose security vulnerabilities and potential damage for which Knightcrawler and its contributors cannot be held responsible. Replace `your-domain.com` with your domain name in the Caddyfile; `knightcrawler/development/docker/Caddyfile`. From 3eaf7cc357a79077ab606caf4bea6698bc0bb958 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 21:26:51 -0600 Subject: [PATCH 15/23] Update docker-compose.yaml --- deployment/docker/docker-compose.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/deployment/docker/docker-compose.yaml b/deployment/docker/docker-compose.yaml index a9c224d..5af2891 100644 --- a/deployment/docker/docker-compose.yaml +++ b/deployment/docker/docker-compose.yaml @@ -129,6 +129,7 @@ services: - knightcrawler-network # Remove the #'s to activate Caddy for external access. Please note that this action may pose security vulnerabilities and potential damage for which Knightcrawler and its contributors cannot be held responsible. + # caddy: # image: caddy:latest # restart: unless-stopped From c065ad024fca2e1e9443673a5ecc92135d4fd137 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 21:31:30 -0600 Subject: [PATCH 16/23] Added direction for uncommenting Caddy --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index c3dc41d..2bd168b 100644 --- a/README.md +++ b/README.md @@ -101,7 +101,8 @@ What you will need: 1. Domain or subdomain that points toward your IP. You can use [DuckDNS](duckdns.org) for a free subdomain. [Installation instructions](http://www.duckdns.org/install.jsp) are provided to keep your IP updated. 2. Ports 80 and 443 opened on your router/gateway and forwarded to your Knightcrawler server. Refer to [PortForward.com](https://portforward.com/). Please note that this action may pose security vulnerabilities and potential damage for which Knightcrawler and its contributors cannot be held responsible. -Replace `your-domain.com` with your domain name in the Caddyfile; `knightcrawler/development/docker/Caddyfile`. +Navigate to `knightcrawler/development/docker` and edit the `Caddyfile` to replace `your-domain.com` with your domain name. +Modify the `docker-compose.yaml` file by uncommenting the `caddy` container section to enable Caddy for external access. ### Run the project From aebd02927c3349d89b571101b0515daddb8db4fd Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 21:36:04 -0600 Subject: [PATCH 17/23] Removed Caddy from addon compose file --- deployment/docker/docker-compose.yaml | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/deployment/docker/docker-compose.yaml b/deployment/docker/docker-compose.yaml index 5af2891..240f350 100644 --- a/deployment/docker/docker-compose.yaml +++ b/deployment/docker/docker-compose.yaml @@ -127,21 +127,6 @@ services: <<: *knightcrawler-app networks: - knightcrawler-network - -# Remove the #'s to activate Caddy for external access. Please note that this action may pose security vulnerabilities and potential damage for which Knightcrawler and its contributors cannot be held responsible. - -# caddy: -# image: caddy:latest -# restart: unless-stopped -# ports: -# - "80:80" -# - "443:443" -# - "443:443/udp" -# volumes: -# - ./Caddyfile:/etc/caddy/Caddyfile -# - ./site:/srv -# - caddy_data:/data -# - caddy_config:/config networks: knightcrawler-network: @@ -152,5 +137,3 @@ volumes: postgres: mongo: rabbitmq: - caddy_data: - caddy_config: From 88fc4987f327f9bdc1fbc62c0a759ebd760c331f Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 21:38:28 -0600 Subject: [PATCH 18/23] Create docker-compose-caddy.yaml --- deployment/docker/docker-compose-caddy.yaml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 deployment/docker/docker-compose-caddy.yaml diff --git a/deployment/docker/docker-compose-caddy.yaml b/deployment/docker/docker-compose-caddy.yaml new file mode 100644 index 0000000..2e08eb5 --- /dev/null +++ b/deployment/docker/docker-compose-caddy.yaml @@ -0,0 +1,21 @@ +version: "3.7" + +services: + caddy: + image: caddy:latest + restart: unless-stopped + cap_add: + - NET_ADMIN + ports: + - "80:80" + - "443:443" + - "443:443/udp" + volumes: + - $PWD/Caddyfile:/etc/caddy/Caddyfile + - $PWD/site:/srv + - caddy_data:/data + - caddy_config:/config + +volumes: + caddy_data: + caddy_config: From 87cb085c3ab7242ae957334d8d4fb22cd6d60e87 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 21:44:13 -0600 Subject: [PATCH 19/23] Update README.md --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index 2bd168b..79a2da7 100644 --- a/README.md +++ b/README.md @@ -106,6 +106,13 @@ Modify the `docker-compose.yaml` file by uncommenting the `caddy` container sect ### Run the project +> [!IMPORTANT] +> If you have configured external access, utilize the following commands: +> ```sh +>cd deployment/docker +>docker-compose -f docker-compose.yaml -f docker-compose-caddy.yaml up -d +>``` + Open a terminal in the project directory and run the command: ```sh From d7e68446b56d7ca15c9dad802c57a4cd53a3d278 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 21:45:34 -0600 Subject: [PATCH 20/23] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 79a2da7..1dd8b02 100644 --- a/README.md +++ b/README.md @@ -44,7 +44,7 @@ Stremio is a media player. On it's own it will not allow you to watch anything. ## Using -The project is shipped as an all-in-one solution. The initial configuration is designed for hosting only on your local network. If you want it to be accessible from outside of your local network, please see [not yet available]() +The project is shipped as an all-in-one solution. The initial configuration is designed for hosting only on your local network. If you want it to be accessible from outside of your local network, please see [Configure external access](#configure-external-access). ### Download Docker and Docker Compose v2 From 35c54acd00f95f5bc8a525f1c92204929a5053e0 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 21:48:17 -0600 Subject: [PATCH 21/23] Update README.md --- README.md | 3 --- 1 file changed, 3 deletions(-) diff --git a/README.md b/README.md index 1dd8b02..cf641da 100644 --- a/README.md +++ b/README.md @@ -101,9 +101,6 @@ What you will need: 1. Domain or subdomain that points toward your IP. You can use [DuckDNS](duckdns.org) for a free subdomain. [Installation instructions](http://www.duckdns.org/install.jsp) are provided to keep your IP updated. 2. Ports 80 and 443 opened on your router/gateway and forwarded to your Knightcrawler server. Refer to [PortForward.com](https://portforward.com/). Please note that this action may pose security vulnerabilities and potential damage for which Knightcrawler and its contributors cannot be held responsible. -Navigate to `knightcrawler/development/docker` and edit the `Caddyfile` to replace `your-domain.com` with your domain name. -Modify the `docker-compose.yaml` file by uncommenting the `caddy` container section to enable Caddy for external access. - ### Run the project > [!IMPORTANT] From 32fc0721dc0b0812882e8898f163e88e6acd8697 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 21:52:40 -0600 Subject: [PATCH 22/23] Made run steps easier to understand --- README.md | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index cf641da..c2ff5a3 100644 --- a/README.md +++ b/README.md @@ -103,15 +103,14 @@ What you will need: ### Run the project -> [!IMPORTANT] -> If you have configured external access, utilize the following commands: -> ```sh ->cd deployment/docker ->docker-compose -f docker-compose.yaml -f docker-compose-caddy.yaml up -d ->``` -Open a terminal in the project directory and run the command: + If you have configured external access, utilize the following commands: +```sh +cd deployment/docker +docker-compose -f docker-compose.yaml -f docker-compose-caddy.yaml up -d +``` + If you have not configured external access, utilize the following commands: ```sh cd deployment/docker docker compose up -d From 186cd8be36bc83ad5f130ab95599c5e0b543f743 Mon Sep 17 00:00:00 2001 From: ben-2357 <123012900+ben-2357@users.noreply.github.com> Date: Mon, 4 Mar 2024 21:54:14 -0600 Subject: [PATCH 23/23] Update README.md --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index c2ff5a3..ab16309 100644 --- a/README.md +++ b/README.md @@ -101,6 +101,8 @@ What you will need: 1. Domain or subdomain that points toward your IP. You can use [DuckDNS](duckdns.org) for a free subdomain. [Installation instructions](http://www.duckdns.org/install.jsp) are provided to keep your IP updated. 2. Ports 80 and 443 opened on your router/gateway and forwarded to your Knightcrawler server. Refer to [PortForward.com](https://portforward.com/). Please note that this action may pose security vulnerabilities and potential damage for which Knightcrawler and its contributors cannot be held responsible. +Navigate to `knightcrawler/development/docker` and edit the `Caddyfile` to replace `your-domain.com` with your domain name. + ### Run the project