Last active
October 21, 2015 13:41
-
-
Save dln/caf67e3e23f09ca5d41e to your computer and use it in GitHub Desktop.
Parameterized jobs in Aurora
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
| CLUSTERS = [ | |
| 'dc1.example.com', | |
| 'dc2.example.com', | |
| 'dc3.example.com', | |
| 'dc4.example.com', | |
| 'dc5.example.com', | |
| 'dc6.example.com', | |
| ] |
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
| include("clusters.aurora") | |
| myprocess = Process( | |
| name = 'my awesome program', | |
| cmdline = ... | |
| ) | |
| myservice = Service( | |
| role = 'user', | |
| env = 'prod', | |
| name = 'myjob', | |
| task = Task( | |
| processes = [myprocess], | |
| resources = Resources(cpu = 1.0, ram = 3*GB, disk = 10*GB), | |
| ), | |
| instances = 3, | |
| ) | |
| jobs = [myservice(cluster = cluster) for cluster in CLUSTERS] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment