Skip to content

Instantly share code, notes, and snippets.

@kevints
Created August 27, 2015 19:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kevints/29adc47f4794033e900b to your computer and use it in GitHub Desktop.
Save kevints/29adc47f4794033e900b to your computer and use it in GitHub Desktop.
default profile values in pystachio (Aurora configs)
% cat test.aurora
class Profile(Struct):
a = Default(Integer, 1)
jobs = [
Job(role = 'a', environment = 'devel', name = 'c', cluster='devcluster',
task = SimpleTask('t', 'echo {{profile.a}}')).bind(profile=Profile()),
% aurora job inspect devcluster/a/devel/c test.aurora
Job level information
name: 'c'
role: 'a'
contact: '<class 'pystachio.composite.Empty'>'
cluster: 'devcluster'
instances: '1'
service: False
production: False
Task level information
name: 't'
Process 't':
cmdline:
echo 1
% aurora job inspect devcluster/a/devel/c test.aurora --bind=profile.a=2
Job level information
name: 'c'
role: 'a'
contact: '<class 'pystachio.composite.Empty'>'
cluster: 'devcluster'
instances: '1'
service: False
production: False
Task level information
name: 't'
Process 't':
cmdline:
echo 2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment