|
1 | | -# WoL Redirect |
2 | | - |
3 | | -WoL Redirect is a Docker Container with graphical interface, which allows users to wake up their services. |
4 | | -Integrates with all of the WoL Containers. |
5 | | - |
6 | | -_Well, except for meteorite_ |
| 1 | +<h1 align="center">WoL Redirect</h1> |
| 2 | + |
| 3 | +<p align="center"> |
| 4 | +🖥️ On-demand service wake-up · Web UI · ⚙️ flexible and configurable · Multi-Environment |
| 5 | +</p> |
| 6 | + |
| 7 | +<div align="center"> |
| 8 | + <a href="https://github.com/codeshelldev/wol-redirect/releases"> |
| 9 | + <img |
| 10 | + src="https://img.shields.io/github/v/release/codeshelldev/wol-redirect?sort=semver&logo=github&label=Release" |
| 11 | + alt="GitHub release" |
| 12 | + > |
| 13 | + </a> |
| 14 | + <a href="https://github.com/codeshelldev/wol-redirect/stargazers"> |
| 15 | + <img |
| 16 | + src="https://img.shields.io/github/stars/codeshelldev/wol-redirect?style=flat&logo=github&label=Stars" |
| 17 | + alt="GitHub stars" |
| 18 | + > |
| 19 | + </a> |
| 20 | + <a href="https://github.com/codeshelldev/wol-redirect/pkgs/container/wol-redirect"> |
| 21 | + <img |
| 22 | + src="https://ghcr-badge.egpl.dev/codeshelldev/wol-redirect/size?color=%2344cc11&tag=latest&label=Image+Size&trim=" |
| 23 | + alt="Docker image size" |
| 24 | + > |
| 25 | + </a> |
| 26 | + <a href="https://github.com/codeshelldev/wol-redirect/pkgs/container/wol-redirect"> |
| 27 | + <img |
| 28 | + src="https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fghcr-badge.elias.eu.org%2Fapi%2Fcodeshelldev%2Fwol-dockerized%2Fwol-dockerized&query=downloadCount&label=Downloads&color=2344cc11" |
| 29 | + alt="Docker image Pulls" |
| 30 | + > |
| 31 | + </a> |
| 32 | + <a href="./LICENSE"> |
| 33 | + <img |
| 34 | + src="https://img.shields.io/badge/License-MIT-green.svg" |
| 35 | + alt="License: MIT" |
| 36 | + > |
| 37 | + </a> |
| 38 | +</div> |
| 39 | + |
| 40 | +--- |
7 | 41 |
|
8 | 42 | ## Installation |
9 | 43 |
|
10 | | -Get the latest `docker-compose.yaml` file: |
| 44 | +Download the latest `docker-compose.yaml`: |
11 | 45 |
|
12 | 46 | ```yaml |
13 | 47 | {{{ #://docker-compose.yaml }}} |
14 | 48 | ``` |
15 | 49 |
|
| 50 | +Start the container: |
| 51 | + |
16 | 52 | ```bash |
17 | 53 | docker compose up -d |
18 | 54 | ``` |
19 | 55 |
|
20 | | -### Reverse Proxy |
| 56 | +## Reverse Proxy |
21 | 57 |
|
22 | | -In this example we'll be using traefik: |
| 58 | +The following example uses **Traefik** as a reverse proxy: |
23 | 59 |
|
24 | 60 | ```yaml |
25 | 61 | {{{ #://examples/traefik.docker-compose.yaml }}} |
26 | 62 | ``` |
27 | 63 |
|
28 | | -Let's use jellyfin for example |
| 64 | +Example service configuration using **Jellyfin**: |
29 | 65 |
|
30 | 66 | ```yaml |
31 | 67 | {{{ #://examples/jellyfin.yaml }}} |
32 | 68 | ``` |
33 | 69 |
|
34 | | -### Configuration |
| 70 | +## Configuration |
| 71 | + |
| 72 | +Basic service-to-host mappings: |
35 | 73 |
|
36 | 74 | ```json |
37 | 75 | {{{ #://examples/config/mapping.json }}} |
38 | 76 | ``` |
39 | 77 |
|
40 | | -`.env` |
| 78 | +Environment variables: |
41 | 79 |
|
42 | 80 | ```dotenv |
43 | 81 | {{{ #://examples/config/config.env }}} |
44 | 82 | ``` |
45 | 83 |
|
46 | | -#### PVE (VMs + LXCs) |
| 84 | +## Advanced Setups |
| 85 | + |
| 86 | +WoL Redirect supports two main scenarios depending on how your services are hosted. |
47 | 87 |
|
48 | | -If you are trying to wakeup a host running PVE, you will probably want to wakeup LXCs or VMs too. |
49 | | -Sadly LXCs (and VMs) don't have `Wake-on-LAN` functionalities. |
50 | | -For that you will need [WoL PVE](https://github.com/codeshelldev/wol-pve) |
| 88 | +## Virtualized Hosts (VMs, LXCs, Hypervisors) |
| 89 | + |
| 90 | +If your services run inside virtual machines or containers managed by a hypervisor (for example Proxmox VE, ..., or similar platforms), you may want to wake up the physical host **and** start specific VMs or LXCs. |
| 91 | + |
| 92 | +Since VMs and LXCs do not support Wake-on-LAN directly, an external helper is required. |
| 93 | + |
| 94 | +This setup requires an additional helper to be installed on the hypervisor: [**WoL VE**](https://github.com/codeshelldev/wol-ve) |
| 95 | + |
| 96 | +Example mapping configuration: |
51 | 97 |
|
52 | 98 | ```json |
53 | | -{{{ #://examples/config/mapping-pve.json }}} |
| 99 | +{{{ #://examples/config/virtual.mapping.json }}} |
54 | 100 | ``` |
55 | 101 |
|
56 | | -#### Docker |
| 102 | +This approach is applicable to: |
| 103 | + |
| 104 | +- Proxmox VE |
| 105 | +- Other hypervisors with API-controlled VM/container startup |
| 106 | +- Mixed virtualization environments |
57 | 107 |
|
58 | | -If you are running docker on your resource-hungry server, you might want to start docker-containers only if needed. |
59 | | -For this to work you will need [WoL Dockerized](https://github.com/codeshelldev/wol-dockerized) |
| 108 | +## Docker Hosts (Non-Virtualized) |
| 109 | + |
| 110 | +If Docker is running directly on a physical server, you may want to: |
| 111 | + |
| 112 | +- Wake up the server only when needed |
| 113 | +- Start specific Docker containers on demand |
| 114 | + |
| 115 | +For this use case, use [**WoL Dockerized**](https://github.com/codeshelldev/wol-dockerized). |
| 116 | + |
| 117 | +Example mapping configuration: |
60 | 118 |
|
61 | 119 | ```json |
62 | | -{{{ #://examples/config/mapping-docker.json }}} |
| 120 | +{{{ #://examples/config/docker.mapping.json }}} |
63 | 121 | ``` |
64 | 122 |
|
65 | | -#### Or both |
| 123 | +## Combined Setup (Virtualization + Docker) |
| 124 | + |
| 125 | +If your environment uses both virtualization and Docker (for example Docker running inside VMs, or mixed workloads), you can combine both approaches. |
| 126 | + |
| 127 | +Example mapping configuration: |
66 | 128 |
|
67 | 129 | ```json |
68 | | -{{{ #://examples/config/mapping-pve-docker.json }}} |
| 130 | +{{{ #://examples/config/virtual-docker.mapping.json }}} |
69 | 131 | ``` |
70 | 132 |
|
71 | | -_You will need both [WoL PVE](https://github.com/codeshelldev/wol-pve) and [WoL Dockerized](https://github.com/codeshelldev/wol-dockerized)_ |
| 133 | +This setup requires: |
| 134 | + |
| 135 | +- [WoL VE](https://github.com/codeshelldev/wol-ve) |
| 136 | +- [WoL Dockerized](https://github.com/codeshelldev/wol-dockerized) |
72 | 137 |
|
73 | 138 | ## Usage |
74 | 139 |
|
75 | | -Use a Reverse Proxy to redirect you from a service `https://jellyfin.mydomain.com` on another machine to `https://wol-red.mydomain.com`, |
76 | | -WoL Redirect will use the `config.json` to get the host of the requested service. |
| 140 | +Configure your reverse proxy to forward requests from a service domain (e.g. `https://jellyfin.mydomain.com`) to `https://wol-red.mydomain.com`. |
77 | 141 |
|
78 | | -## Contributing |
| 142 | +WoL Redirect inspects the incoming request, matches it against the configuration, and: |
79 | 143 |
|
80 | | -Have feedback, new ideas or found a bug? Feel free to open up an issue or to start a Pull Request! |
| 144 | +1. Wakes up the target host if necessary |
| 145 | +2. Starts the required VM, container, or service |
| 146 | +3. Redirects traffic once the service is available |
| 147 | + |
| 148 | +## Contributing |
81 | 149 |
|
82 | | -_But remember we are all volunteers, so be kind and respectful_ |
| 150 | +Have feedback, ideas, or found a bug? Open an issue or submit a pull request. |
83 | 151 |
|
84 | 152 | ## Supporting |
85 | 153 |
|
86 | | -Like this project and want to support? |
87 | | -⭐️ this Repository to let others know about this Project. |
| 154 | +If you find this project useful, consider starring ⭐️ the repository to help others discover it. |
88 | 155 |
|
89 | 156 | ## License |
90 | 157 |
|
91 | | -[MIT](https://choosealicense.com/licenses/mit/) |
| 158 | +This project is licensed under the [MIT License](./LICENSE) |
0 commit comments