Created
July 7, 2016 19:42
-
-
Save johnrengelman/a302634c2aa7833a46584484df755f8d to your computer and use it in GitHub Desktop.
Upgrade Rancher Cluster with Amazon EC2 Run Command
This file contains 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
{ | |
"schemaVersion":"1.2", | |
"description":"Upgrade Rancher cluster to specified version", | |
"parameters":{ | |
"version":{ | |
"type":"String", | |
"description":"(Required) The version to upgrade to.", | |
"maxChars":4096 | |
} | |
}, | |
"runtimeConfig":{ | |
"aws:runShellScript":{ | |
"properties":[ | |
{ | |
"runCommand": [ | |
"docker pull rancher/server:{{version}}", | |
"docker rm -f $(sudo docker ps -a | grep rancher | awk {'print $1'}) ", | |
"/var/lib/rancher/bin/rancher-ha-start.sh rancher/server:{{version}}" | |
] | |
} | |
] | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment