Skip to content

Instantly share code, notes, and snippets.

@Anthonyhawkins
Created June 8, 2021 18:07
Show Gist options
  • Save Anthonyhawkins/792d229c11a7854b490459d4cb2382dd to your computer and use it in GitHub Desktop.
Save Anthonyhawkins/792d229c11a7854b490459d4cb2382dd to your computer and use it in GitHub Desktop.
class Task(object):
@staticmethod
def cf_mgmt(command):
return {
"task": command,
"image": "cf-mgmt",
"config": {
"platform": "linux",
"inputs": [
{"name": "config-repo"}
],
"params": {
"SYSTEM_DOMAIN": sources.grab("vars", "meta.system_domain"),
"USER_ID": sources.grab("vars", "meta.user_id"),
"PASSWORD": env("PASSWORD"),
"CONFIG_DIR": "config-repo/orgs/" + env("CF_ENVIRONMENT"),
"CLIENT_SECRET": env("CLIENT_SECRET"),
"LOG_LEVEL": "info",
"CF_MGMT_COMMAND": command
},
"run": {
"path": "config-repo/ci/tasks/cf-mgmt.sh"
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment