Valkey

In-memory key-value store under the BSD license.

DatabaseTested on FreeBSD9.1.2BSD-3-Clause

jailops app install valkey

Add --dry-run to see every step first. From the console: open Apps, pick Valkey and press Install; the dialog takes the jail name, the network and the storage, and Preview steps shows the plan before anything runs. See the console.

About

Valkey is a high-performance data structure server for key/value workloads. The package ships the server, the command line client and a sentinel; this definition runs the server with the configuration the package installs.

The server binds 127.0.0.1 and ::1 with protected mode on until /usr/local/etc/valkey.conf is changed.

What you get

Ports

  • 6379/tcp valkeyThe protocol port; bound to localhost until bind is changed.

Data on its own datasets

  • /var/db/valkey volume var-db-valkeySnapshots and the append-only file.

Configuration

  • /usr/local/etc/valkey.confThe server configuration (bind, protected-mode, persistence). Restart: service valkey restart.

Logs

  • /var/log/valkey/valkey.logThe server log.

Health check

Command: valkey-cli ping succeeds in the jail, retried for up to 30 seconds.

Services

  • valkey: enabled and started

Setup, once, before the first start

Two commands, run in the jail as argv, without a shell:

  1. /bin/mkdir -p /var/log/valkey /var/run/valkey
  2. /usr/sbin/chown valkey:valkey /var/db/valkey /var/log/valkey /var/run/valkey

After the installation

The notes of the definition, shown after the installation too.

Talk to it from inside the jail with: jailops exec NAME -- valkey-cli
To reach it from other jails, set bind and requirepass in valkey.conf and restart the service.

How it connects

jailops app allow valkey from @web

This opens port 6379/tcp of this app to the jail web, and nothing else. The service itself must listen on the jail's address and accept the client.

Valkey binds 127.0.0.1 with protected mode on: before you allow a jail, set bind, protected-mode and requirepass in /usr/local/etc/valkey.conf and restart the service.

An installed app is closed: nothing reaches it, not even its own network, until you allow a source. A source is a jail (@web), a jail of another project (@project/web), an address set, an address or prefix, or host. jailops app access valkey lists who may connect. The names here are jail names: jailops app install names the jail after the app unless --name says otherwise.