Every server in the WikiOasis farm is managed by Salt from first boot. This runbook walks through the complete process — from installing the minion agent to verifying that all role-appropriate states have been applied cleanly. Follow each step in order; the minion’s ID is especially important because it controls which states and pillar data are automatically assigned.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/wikioasis/salt/llms.txt
Use this file to discover all available pages before exploring further.
Naming convention and role assignment
The minion ID you choose at provisioning time is the primary key Salt uses to determine every role and pillar assignment. Bothsalt/top.sls and pillar/top.sls use glob patterns matched against the minion ID, so getting the name right is critical before you ever run a state.
| Minion ID pattern | States applied |
|---|---|
mw* | mediawiki.target, php, nginx, sentry_relay, monitoring.nrpe_nginx, monitoring.nrpe_php, monitoring.nrpe_mediawiki, monitoring.phpfpm_exporter |
staging* | mediawiki, php, nginx, sentry_relay, monitoring.nrpe_nginx, monitoring.nrpe_php, monitoring.nrpe_mediawiki, monitoring.phpfpm_exporter |
task* | php, nginx, mediawiki.target, mediawiki.jobrunner, monitoring.nrpe_nginx, monitoring.nrpe_php, monitoring.phpfpm_exporter |
apps* | php, nginx, monitoring.nrpe_nginx, monitoring.nrpe_php, monitoring.phpfpm_exporter |
db* | mariadb, mariadb.monitoring_user, mariadb.prometheus_user, mariadb.backup, mariadb.nrpe_backup, monitoring.mysqld_exporter |
proxy* | haproxy, mediawiki.proxy, monitoring.nrpe_haproxy, monitoring.haproxy_exporter |
redis* | redis, monitoring.nrpe_redis, monitoring.redis_exporter |
opensearch* | opensearch, monitoring.nrpe_opensearch, monitoring.opensearch_exporter |
monitoring* | monitoring, monitoring.director, monitoring.nrpe_nginx, monitoring.prometheus, monitoring.grafana, monitoring.statsd_exporter |
metal* | metal, monitoring.nrpe_metal |
salt* | monitoring.nrpe_salt_master |
base, users, monitoring.nrpe, monitoring.nrpe_common, monitoring.nrpe_salt, and monitoring.node_exporter states regardless of its name.
The
mw* and staging* patterns both match the compound rule mw* or staging* in salt/top.sls, which applies php, nginx, sentry_relay, and the associated monitoring states. The mw* pattern additionally receives mediawiki.target; the staging* pattern additionally receives mediawiki.All servers whose IDs match *-us-east-0[0-9][0-9]* also receive the metal.vm_ipv6 state, which configures IPv6 addressing for virtual machines hosted on bare-metal hypervisors.Adding the server
Provision the server
Boot the new machine from a Debian image. Once the OS is running, install the Salt minion package and point it at the Salt master:Edit Then enable and start the service:The minion will generate an RSA key pair and send its public key to the master for acceptance.
/etc/salt/minion and set the master address and the minion ID you have chosen:Accept the minion key on the master
On the Salt master, list pending keys and accept the new minion:Verify connectivity immediately after accepting:You should receive
True within a few seconds.Add per-host pillar data if required
Some roles need per-host pillar files. Database servers are the most common example — each If your new server needs dedicated pillar data, create the file (e.g. Similarly, per-host Redis pillar files live under
db-* host has its own .sls file in pillar/mariadb/ that sets connection parameters, backup credentials, and tuning values.Check pillar/top.sls to see whether a new entry is needed for your minion ID:pillar/mariadb/db-c2-us-east-031.sls) and add the matching glob to pillar/top.sls:pillar/redis/ and are referenced by their own glob patterns:The
private pillar must be present on the master before applying any state that references secrets (passwords, SSH keys, API tokens). Confirm with your team that the private pillar has been updated for the new host.Verify pillar data
Before applying any state, confirm the minion sees the correct pillar values. This catches missing private pillar files or top.sls mismatches early:For a database server, also confirm the MariaDB-specific keys are populated:If the output is empty or missing expected keys, fix the pillar before proceeding.
Apply the base state
The The
base state configures system-wide settings (timezone, APT mirror) and is safe to apply to any server at any time. Apply it first to establish a known baseline:users state is applied automatically as part of the top file for all minions, but you can apply it explicitly if needed:Apply the role states
Apply the states that correspond to the server’s role. Use Database server:HAProxy load balancer:Redis cache server:OpenSearch node:Monitoring server:
state.highstate to apply everything from top.sls at once, or apply individual states if you want to bring the server up incrementally.MediaWiki application server:Verify the server is healthy
After states apply cleanly, confirm the server is reachable and monitored:Log into Icinga2 and confirm the new host appears and all service checks are passing. If the host does not appear within a few minutes, check that the
monitoring.director state has been applied to the monitoring server and that monitoring:icinga_api_host is set correctly in the private pillar.Reference: pillar/top.sls glob patterns
The table below summarises the per-role pillar assignments frompillar/top.sls. These are applied on top of the universal base, users, and private pillars that every minion receives.
| Pattern | Pillar files |
|---|---|
db* | mariadb, private |
db-other-us-east-011* | mariadb.db-other-us-east-011 |
db-pc-us-east-011* | mariadb.db-pc-us-east-011 |
db-c1-us-east-021* | mariadb.db-c1-us-east-021 |
mw* or staging* | users.servers.mediawiki, php, nginx, mediawiki |
proxy* | haproxy, mediawiki |
redis-us-east-011* | redis.redis-us-east-011 |
redis-us-east-012* | redis.redis-us-east-012 |
monitoring* | monitoring, metal, private |
apps* | php, private |
task* | users.servers.mediawiki, php, nginx, mediawiki, mediawiki.jobrunner |
bastion* | users.servers.bastion |
metal-us-east-01* | metal.metal-us-east-01 |
metal-us-east-02* | metal.metal-us-east-02 |
Maintenance Runbook
Learn how to depool, schedule downtime, apply configuration changes, and repool a server safely.
Database Backup
Understand the full, incremental, and binlog streaming backup system for MariaDB servers.