Ringmaster supports scripts using any of the supported handlers.
There are two ways to get your scripts:
ringmaster has built-in support for downloading and verifying scripts.
To download scripts:
ringmaster get STACK_DIR/LOCAL_DIR https://url.directoryeg:
ringmaster get stack/0010-iam https://raw.githubusercontent.com/declarativesystems/ringmaster/examples/0010-iamWould create:
0010-iam/
├── AWSLoadBalancerController.iam_policy.json
├── Certbot.iam_policy.json
├── EksDeploy.iam_policy.json
├── EksExternalSecrets.iam_policy.json
├── ExternalDns.iam_policy.json
└── metadata.yaml
- Make sure to give the link to the
rawversion of your script if using github - You can change the local directory if you like
metadata.yamlmust exist as a child ofurl.directorymetadata.yamlcontains a list of files to download and their hashes- Local edits will abort the download process to prevent accidental overwriting
-
Find the stack directory you want your script to belong to or create a new one
-
Create a directory for your script to run in. Numbering the directory is an easy way to get your script to run in the right order
-
Write your script - since you already know cloudformation, Bash, Python, Kubernetes deployment descriptors and a bunch of other stuff, you already know how to do this, so just make sure the filename of your script matches the handler you want to use.
Some scripts support variable substitution, so you do things like have your Kubernetes deployment descriptors automatically rewritten for you, other scripts such as cloudformation will do an automatic parameter lookup from the databag. The best way to get started is look at the handlers documentation and the existing examples.
If you've written a cool script and want to share it with the World, all you need to do is generate your metadata and publish to the internet.
Generating metadata
ringmaster metadata DIRECTORYeg
ringmaster metadata my_stack/0300-some-cool-thing- Create
my_stack/0300-some-cool-thing/metadata.yaml - List all files inside
my_stack/0300-some-cool-thingwith matching handlers in thefilessection - Set the
namefield to0300-some-cool-thing - Create a
descriptionfield for you to fill out if you like
If you have additional files that form part of the script use the --include
argument.
At the moment name and description are for your own reference.
To publish your script, upload the whole directory somewhere, eg github.
Now anyone with access to the URL can use the script.