How it works
- Create a saved script.
- Select one or more scripts when ordering, provisioning, or reinstalling a server.
- Rackdog records the selected scripts and their order for that install.
- On supported Linux and Windows templates, each script runs on first boot.
Requirements
- Linux scripts use Bash by default. To use another interpreter, start the script with
#!/usr/bin/python3. - Windows scripts run with PowerShell.
- Script content can be up to 1500 characters.
- Script names can be up to 100 characters.
- Linux scripts run as root. Windows scripts run as Administrator.
- Creating, updating, or deleting scripts requires organization admin access.
- Selecting the same script twice in one request is rejected.
- Scripts do not run on Custom iPXE installs.
Create a script
Use the public API to create a saved script:contentSha256. Use the ID when selecting the script for a server.
Select scripts for an install
AddprovisioningScripts to an order, provisioning, or reinstall request:
provisioningScripts.
If a script exits non-zero, Rackdog stops running the remaining scripts and does not roll the install back.
Script output and errors are written to the server:
- Linux:
/var/log/rackdog/provisioning.log - Windows:
C:\ProgramData\Rackdog\provisioning.log
Good habits
- Provisioning scripts are best for small bootstrap tasks.
- For larger setup flows, use a provisioning script to set up your preferred configuration management tool.
- Avoid putting long-lived secrets directly in script content.
- Test on a non-production server before using a script across a fleet.
