Use System Initiative workspaces in your GitHub workflows!
NOTE: this is in early private access, and not yet publicly available.
Triggers a management function, so you can deploy real infrastructure based on your changes.
Place this in a .github/workflows
workflow on your repository:
- uses: systeminit/actions@main
with:
changeSetName: CI
componentId: 01JH3DZW0QTMH69ZA45299GSWY
domain: |
a: new A
c: new C
point/x: new x
apiToken: ${{ secrets.SI_API_TOKEN }}
The with
section is where you put the input properties that tell SI what to
run and what properties to set:
-
apiToken
is the API token you use to access SI from GitHub Actions (see Getting an API Token). We recommend using a secret here, likeapiToken: ${{ secrets.SI_API_TOKEN }}
. -
changeSetName
is the name of the change set to create when the action runs. (You may alternately specifychangeSetId
if you want to use an existing change set.) -
componentId
is the ID of the management component. -
domain
is the list of properties you want to set on your component. You can specify the names of each property you want to set directly (likeCidrBlock
), followed by their value. Any properties you do not specify will be left alone with their current value.If you have a nested object (like a "point" object with "x", "y" and "z" properties) you can use a path to the individual property as its name (e.g.
"point/x": "100"
.You may specify this as either YAML or JSON. (The
|
afterdomain:
is important, as it must be passed in as a string!)
To use these actions, you will need an API token. To get one:
- Go to https://auth.systeminit.com/workspaces.
- Click on the Gear icon in the workspace you'd like to use with System
Initiative, and click API Tokens.
- Create an API token: fill in the name and how long before the token will
expire, and click "Create API Token".
- Click the Copy button at the bottom right to copy the token, so that you can
paste it wherever you like.
We recommend placing the secret into a
GitHub secret
so you can access it in workflows with {{ secrets.SI_API_TOKEN }}
(though you
can name it whatever you like)! The examples on this page all assume you have
placed it into a repository secret named SI_API_TOKEN.