https://github.com/valohai/worker-queue
Dockerfile for building the Valohai Worker queue
https://github.com/valohai/worker-queue
devops iaac valohai
Last synced: 26 days ago
JSON representation
Dockerfile for building the Valohai Worker queue
- Host: GitHub
- URL: https://github.com/valohai/worker-queue
- Owner: valohai
- Created: 2021-06-17T16:55:26.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2025-02-06T07:29:12.000Z (8 months ago)
- Last Synced: 2025-02-06T08:32:16.550Z (8 months ago)
- Topics: devops, iaac, valohai
- Language: Shell
- Homepage:
- Size: 7.19 MB
- Stars: 1
- Watchers: 9
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Valohai Worker Queue
This repository contains a Dockerfile for building the Valohai Worker queue and scripts to deploy the queue.
The Docker image built is based on the official Debian Bookworm image and contains:
- Redis (version 7+)
- acmetool (modified for ACMEv2 support)
- a startup script that wants the specified SSL certificate and runs Redis with the given password## Bulding and Publishing
Build: `./build.sh`
Publish: `./publish.sh`
## Installation
> :warning: The worker queue host machine needs to have port 80 open to the internet and port 63790 open to Valohai (roi) and workers (peon)!
Installing the worker queue on a machine is as easy as running: `curl https://raw.githubusercontent.com/valohai/worker-queue/main/host/setup.sh | sudo QUEUE_ADDRESS=your-queue-address-here REDIS_PASSWORD=your-redis-password-here REDIS_PORT=redis-tls-port bash`
This installs Docker and creates a systemd service that runs the worker queue with the given parameters.
Replace your-queue-address-here with the `xxx.vqueue.net` address configured in Valohai's AWS Route 53 and your-redis-password-here with an agreed-upon password for Redis.
Running the above is equal to running the setup script directly: `sudo QUEUE_ADDRESS=your-queue-address-here REDIS_PASSWORD=your-redis-password-here ./setup.sh`
### Manual Setup
If you want to install the worker queue without running the setup script `setup.sh` at all, here are the steps required:
- Prepare a Linux host machine with Docker installed
- Run `docker pull valohai/worker-queue:latest`
- Copy `host/worker-queue.service` from this repository to `/etc/systemd/system/worker-queue.service`
- Replace the following values in `etc/systemd/system/worker-queue.service`: `$QUEUE_ADDRESS` with your `xxx.vqueue.net` address and `$REDIS_PASSWORD` with an agreed-upon password for Redis
- Run `systemctl enable worker-queue`
- Run `systemctl start worker-queue`