A policy that runs before executing each task in a Scale Manifest stage.

Example Payload

Click to expand
  "input": {
    "deploy": {
      "account": "spinnaker",
      "credentials": "spinnaker",
      "events": [],
      "location": "staging",
      "manifestName": "deployment hostname",
      "replicas": 10

Example Policy

This policy prevents scaling a deployment or replicaset in a production account to have <2 replicas.

package spinnaker.deployment.tasks.before.scaleManifest

productionAccounts :=["prod1","prod2"]

deny["production accounts require >1 replicas to avoid a single point of failure."]{


input.deploy.accountstringThe account being deployed to.
input.deploy.credentialsstringThe credentials used to access the account.
input.deploy.locationstringThe name of the namespace the manifest is being deleted from.
input.deploy.manifestNamestringThe name of the manifest being deleted.
input.deploy.replicasnumberHow many pods should be running after the scaling action.

Last modified August 18, 2023: (02b163b7)