-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Axel Leroy
committed
Dec 20, 2022
1 parent
1f6a70a
commit a66a59c
Showing
1 changed file
with
44 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,44 @@ | ||
## Environment variables | ||
|
||
| Variable | Meaning | Example | | ||
|----------------|-----------------------------------------------------------|---------------------------------| | ||
| `TZ` | Timezone | `TZ='Europe/Paris'` | | ||
| `CRON` | Cron schedule expression | `CRON='20 4 * * *'` | | ||
| `MAC_ADDRESS` | Mac address of the computer you want to wake up | `MAC_ADDRESS=AA:BB:CC:DD:EE:FF` | | ||
| `BROADCAST_IP` | IP address of the subnet to broadcast the magic packet to | `BROADCAST_IP=192.168.0.255` | | ||
# wakeonlan-cron-docker | ||
|
||
A Docker container to wake up a computer on a schedule. | ||
|
||
## Instructions | ||
|
||
### Vanilla Docker | ||
|
||
```bash | ||
docker run \ | ||
axeleroy/wakeonlan-cron-docker:latest \ | ||
-e TZ='Europe/Paris' \ | ||
-e CRON='20 4 * * *' \ | ||
-e MAC_ADDRESS=AA:BB:CC:DD:EE:FF \ | ||
--network="host" | ||
``` | ||
|
||
### Docker-compose | ||
```yml | ||
version: "3" | ||
services: | ||
wake-on-lan: | ||
image: axeleroy/wakeonlan-cron-docker:latest | ||
environment: | ||
- TZ='Europe/Paris' | ||
- CRON='20 4 * * *' | ||
- MAC_ADDRESS=AA:BB:CC:DD:EE:FF | ||
networks: | ||
hostnet: {} | ||
|
||
networks: | ||
hostnet: | ||
external: true | ||
name: host | ||
``` | ||
### Environment variables | ||
| Variable | Meaning | Example | | ||
|----------------|---------------------------------------------------------------------------|---------------------------------| | ||
| `TZ` | Timezone | `TZ='Europe/Paris'` | | ||
| `CRON` | Cron schedule expression (tip: use [crontab.guru](https://crontab.guru/)) | `CRON='20 4 * * *'` | | ||
| `MAC_ADDRESS` | Mac address of the computer you want to wake up | `MAC_ADDRESS=AA:BB:CC:DD:EE:FF` | | ||
| `BROADCAST_IP` | IP address of the subnet to broadcast the magic packet to | `BROADCAST_IP=192.168.0.255` | |