fleet/tools/tuf/test/migration
Noah Talerman e93750edab
Cleanup scripts (#27307)
- Move duplicate scripts out of `scripts/mdm/` and into
`it-and-security/` so we have one version that we can continue to
iterate and improve.
- Remove no longer used scripts out of `scripts/mdm/`

---------

Co-authored-by: Lucas Manuel Rodriguez <lucas@fleetdm.com>
2025-03-27 16:43:53 -05:00
..
migration_test.sh Cleanup scripts (#27307) 2025-03-27 16:43:53 -05:00
README.md Migration script to support multiple hosts and rpm and arm64 (#25542) 2025-01-17 14:13:27 -03:00

migration_test.sh

This script is used to test the migration from one local TUF repository to a new local TUF repository (with new roots).

Currently supports running on macOS only.

The script is interactive and assumes the user will use a Windows and Ubuntu VM to install fleetd and test the changes on those platforms too.

  • FLEET_URL: The Fleet server will be hosted on https://localhost:8080, tunneled via ngrok to e.g. https://s123ssfsdgsdf.ngrok.app.
  • OLD_TUF_URL: The "old" TUF will be hosted on http://localhost:8081, tunneled via ngrok to e.g. https://121e9b4a4dab.ngrok.app.
  • NEW_TUF_URL: The "new" TUF will be hosted on http://localhost:8082, tunneled via ngrok to e.g. https://12oe8b5b3cc6.ngrok.app.
  • SIMULATE_NEW_TUF_OUTAGE=1: Simulates an outage of the new TUF server during the migration.
  • ORBIT_PATCH_IN_OLD_TUF=1: Simulates an outage of the new TUF server during the migration and a "need" to patch orbit on the old repository.
  • HOSTNAMES: Space separated list of hostname where fleetd will be installed to test the migration (as reported by osquery/Fleet).
  • NO_TEAM_ENROLL_SECRET: Enroll secret of "No team" on your Fleet instance.
FLEET_URL=https://s123ssfsdgsdf.ngrok.app \
OLD_TUF_URL=https://121e9b4a4dab.ngrok.app \
NEW_TUF_URL=https://12oe8b5b3cc6.ngrok.app \
NO_TEAM_ENROLL_SECRET=... \
HOSTNAMES="DESKTOP-USFLJ3H foobar-ubuntu" \
SIMULATE_NEW_TUF_OUTAGE=1 \
ORBIT_PATCH_IN_OLD_TUF=1 \
./tools/tuf/test/migration/migration_test.sh