Created
June 29, 2020 18:59
-
-
Save descrepes/5b9e2a2506651299b81638a4b645deda to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
apiVersion: argoproj.io/v1alpha1 | |
kind: WorkflowTemplate | |
metadata: | |
name: saltstack | |
namespace: argo | |
spec: | |
templates: | |
- name: highstate | |
inputs: | |
parameters: | |
- name: compound | |
container: | |
imagePullPolicy: "Always" | |
image: geshan/fabric-alpine:latest | |
command: ["fab"] | |
args: ["-H", "myuser@salt", "--", "sudo /usr/bin/salt --show-jid --state-output=changes -C \"{{inputs.parameters.compound}}\" state.highstate queue=True" ] | |
- name: cloud-create | |
inputs: | |
parameters: | |
- name: profile | |
- name: vms | |
script: | |
imagePullPolicy: "Always" | |
image: geshan/fabric-alpine:latest | |
env: | |
- name: VMS | |
value: "{{inputs.parameters.vms}}" | |
command: ["sh"] | |
source: | | |
fab -H myuser@salt -- sudo /usr/bin/salt-cloud -p {{inputs.parameters.profile}} ${VMS//,/ } -P |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment