Find drift
Someone edits a config file on a server to fix an incident at 3am. Someone resizes a droplet in the console. Each time, what’s running stops matching what’s written, and nobody notices until the next apply quietly undoes it.
conn3x drift tells you first. It reads every resource and every host step again and reports what changed, without changing anything:
$ conn3x driftDrift found in 2 resources.
Cloud ~ digitalocean_droplet.web changed
Hosts ~ conn3x_file.web__page["web1"] changed
Run conn3x plan to see what Conn3x would change to put them back.A file deleted outside Conn3x shows as gone.
Run it on a schedule
Section titled “Run it on a schedule”drift exits 0 when nothing changed, 2 when something did, and 1 on errors, so a scheduled job can alert on it. For example, from GitHub Actions:
- name: Check for drift run: conn3x drift -no-colorThe job fails when drift appears, which is usually the alert you want.
Then what
Section titled “Then what”- To put things back, run
conn3x planto see the exact change, thenconn3x apply. - To keep the hand edit, change the circuit to match, then apply. The next
driftcomes back clean.