Pick how to install it
Steps
1
Make a key for the first administrator
A server that listens on anything but loopback refuses to start without an API key. Make a long random one now and keep it in your secret store:The server warns about a key shorter than 32 characters. To keep the plain key off the server, give it the SHA-256 digest instead, written
sha256:<64 hex digits>; clients still send the plain key. See Secure the server.2
Start the server
- Docker
- Linux package
- Install script
- Archive
- From source
The image listens on The image has no shell and no
0.0.0.0 inside the container, so it always needs a key. Publish the port on loopback and let the reverse proxy in step 3 face the network:curl. It runs as the unprivileged user 65532.3
Check the server on the host
{"status":"UP"} and needs no key. The second shows the name and role of your key.4
Put TLS in front of it
Yukta serves plain HTTP, and keys travel in request headers, so end TLS in a reverse proxy on the same host. Two things matter in the proxy: do not buffer event streams, and do not close idle ones early (the server sends a keep-alive comment every 15 seconds).These are examples; adapt them to your proxy. When you set a key, the
- nginx
- Caddy
Host and Origin check that protects a keyless local server is off, so no extra setting is needed for the host name. The one-time-token answer path (/api/inputs/token-answer) rate-limits by caller address; for that to be the caller and not the proxy, set server.forward-headers-strategy=framework and make the proxy replace X-Forwarded-For as shown.5
Tell clients where the server is
6
Give it time to stop
On a stop signal the server refuses new starts and gives running runs
yukta.execution.shutdown-timeout (30 seconds by default) to finish. The packaged systemd unit waits 45 seconds. In an orchestrator, set the stop grace period above 30 seconds. Use GET /actuator/health as the probe: the image has no shell for an exec probe.Verify it worked
From another machine:{"status":"UP"}. The second call prints 401, because it sent no key. The third returns your key’s name and role. If the container or service exits at start, read its log: “Refusing to listen on … without an API key” means no key reached the server. See Troubleshoot.
Variations that matter
- Choose the plugins you ship. Optional plugins are chosen when you build, with
-Pyukta.plugins=default,all,noneor a comma-separated list. A running server cannot add or remove them. The settings and the plugin names are in Configuration reference and the plugin reference. - Run more than one server. Failover needs a Plus build and PostgreSQL. See Run highly available.
- Install on a machine with no internet. Copy a release’s files to a web server laid out as
<base>/vX.Y.Z/<file>, then runinstall.shwithYUKTA_DOWNLOAD_BASE=<base>. Read the script first if you need to audit it. - Check a download. Every release publishes
SHA256SUMSand a Sigstore signature for it. See Releases. - Publish the API description. The
prodprofile serves no Swagger UI or/v3/api-docs. To turn them on behind your key, see Secure the server.
Related
- Install Yukta: the first install, on a laptop
- Upgrade and roll back
- Secure the server
- Configuration reference: every setting, its default and its environment variable
- How durability and high availability work