Skip to content

Support managing sidecar services (e.g. Meilisearch, Redis) #12

@raffaelschneider

Description

@raffaelschneider

Problem

Vela currently manages BEAM releases, but real-world deployments often depend on sidecar services like Meilisearch, Redis, MinIO, or PostgreSQL running on the same host. These services need to:

  • Start before the BEAM app
  • Auto-restart on crash
  • Survive server reboots
  • Be health-checked independently

Right now these have to be managed manually via systemd or nohup, which defeats the purpose of having a single deployment tool.

Proposal

Add a [[services]] section to Vela.toml that lets you declare companion services:

[[services]]
name = "meilisearch"
binary = "/usr/local/bin/meilisearch"
args = ["--db-path", "/var/lib/meilisearch/data", "--env", "production", "--http-addr", "127.0.0.1:7700"]
health = "http://127.0.0.1:7700/health"
restart = "always"

[services.env]
MEILI_MASTER_KEY = "secret"

Vela would then:

  1. Ensure each service is running before starting the BEAM app
  2. Restart services if they crash (configurable policy)
  3. Optionally install systemd units on the remote host
  4. Include service health in vela status output

Motivation

We deploy Cyanea Hub with vela deploy to a Hetzner bare-metal server. Meilisearch runs alongside it on the same box. Currently we had to SSH in, install the binary, and run it with nohup manually. It would be much cleaner if Vela owned the full deployment lifecycle.

Alternatives considered

  • Docker Compose: Adds container overhead, doesn't integrate with Vela's BEAM release management
  • Manual systemd: Works but requires sudo and is outside Vela's visibility
  • pre_start hook: Hacky, no crash recovery, no health checking

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions