58 lines
1.9 KiB
Markdown
58 lines
1.9 KiB
Markdown
# Cronicle Docker
|
|
|
|
[](https://drone.mrmeeb.stream/MrMeeb/cronicle-docker) - _Every new commit triggers a build. I'm lazy._
|
|
|
|
|
|
Dockerised Cronicle, based on the [Cronicle-Edge](https://github.com/cronicle-edge/cronicle-edge) fork.
|
|
|
|
Can function in both the **manager** and **worker** role.
|
|
|
|
## Running
|
|
|
|
`config.json`, located in `/config/config.json`, is automatically generated on the first run of Cronicle in 'manager' mode. This file must be kept identical between the manager and any workers it controls.
|
|
|
|
If you want to configure Cronicle before first run, download `config_sample.json` and adjust accordingly before placing in `/config/config.json`.
|
|
|
|
NOTE: You need to define the hostname of the container if using `docker run`. Cronicle expects the hostname to remain the same, so the randomly-generated container hostname can cause problems if it changes. Docker Compose containers inherit their hostname from the `container_name` parameter, but it can also be defined using `hostname: xyz`.
|
|
|
|
### Docker CLI
|
|
```
|
|
docker run -d --name cronicle \
|
|
--hostname cronicle-docker \
|
|
-p 3012:3012 \
|
|
-e MODE=manager \
|
|
-v {path on host}:/config
|
|
git.mrmeeb.stream/mrmeeb/cronicle:latest
|
|
```
|
|
|
|
### Docker Compose
|
|
|
|
```
|
|
version: '3'
|
|
services:
|
|
cronicle:
|
|
container_name: cronicle
|
|
image: git.mrmeeb.stream/mrmeeb/cronicle:latest
|
|
restart: unless-stopped
|
|
ports:
|
|
- 3012:3012
|
|
volumes:
|
|
- {path on host}:/config
|
|
environment:
|
|
- MODE=manager
|
|
```
|
|
|
|
## Ports
|
|
|Port |Description|
|
|
|-----|-----------|
|
|
|3012 |WebUI and communication between manager and workers|
|
|
|
|
## Volumes
|
|
|Mount |Description|
|
|
|------|-----------|
|
|
|/config |Persistent config file and job configurations|
|
|
|
|
## Environment Variables
|
|
|Variable|Options|Default|Description|
|
|
|--------|-------|-------|-------|
|
|
|MODE |manager, worker|manager|Determines what mode Cronicle runs in |