Webhooks can now reference secrets

CD-as-a-ServiceFeature
undefined
undefined

When triggering a webhook from your deployment, you can now reference a secret from within it. To do this type {{secret.secretName}} where secretName is the name given to the secret when creating it through the ui. You should use secrets to store credentials used by webhooks to ensure they are neither visible to users nor logged. Here is an example of how to trigger a GitHub action that uses a secret for authentication:

  - name: Run_Security_Scanners
    method: POST
    uriTemplate: https://api.github.com/repos/myorgname/myreponame/dispatches
    networkMode: direct
    headers:
      - key: Authorization
        value: token {{secrets.github_token}}
      - key: Content-Type
        value: application/json
    bodyTemplate:
      inline:  >-
        {
        "event_type": "Run_Security_Scanners",
        "client_payload": {
            "callbackUri": "{{armory.callbackUri}}/callback"
            }
        }
    retryCount: 3
Armory logo

Sep

15

New on the deployment graph: Deployment triggers with source context!

CD-as-a-ServiceFeature