5353: Added max_total_price. Added more tests for multiple node sizes.
[arvados.git] / services / nodemanager / doc / gce.example.cfg
1 # Google Compute Engine configuration for Arvados Node Manager.
2 # All times are in seconds unless specified otherwise.
3
4 [Daemon]
5 # Node Manager will ensure that there are at least this many nodes
6 # running at all times.
7 min_nodes = 0
8
9 # Node Manager will not start any compute nodes when at least this
10 # many are running.
11 max_nodes = 8
12
13 # Poll compute nodes and Arvados for new information every N seconds.
14 poll_time = 60
15
16 # Polls have exponential backoff when services fail to respond.
17 # This is the longest time to wait between polls.
18 max_poll_time = 300
19
20 # Upper limit on rate of spending (in $/hr), will not boot additional nodes
21 # if total price of already running nodes meets or exceeds this threshold.
22 # default 0 means no limit.
23 max_total_price = 0
24
25 # If Node Manager can't succesfully poll a service for this long,
26 # it will never start or stop compute nodes, on the assumption that its
27 # information is too outdated.
28 poll_stale_after = 600
29
30 # "Node stale time" affects two related behaviors.
31 # 1. If a compute node has been running for at least this long, but it
32 # isn't paired with an Arvados node, do not shut it down, but leave it alone.
33 # This prevents the node manager from shutting down a node that might
34 # actually be doing work, but is having temporary trouble contacting the
35 # API server.
36 # 2. When the Node Manager starts a new compute node, it will try to reuse
37 # an Arvados node that hasn't been updated for this long.
38 node_stale_after = 14400
39
40 # File path for Certificate Authorities
41 certs_file = /etc/ssl/certs/ca-certificates.crt
42
43 [Logging]
44 # Log file path
45 file = /var/log/arvados/node-manager.log
46
47 # Log level for most Node Manager messages.
48 # Choose one of DEBUG, INFO, WARNING, ERROR, or CRITICAL.
49 # WARNING lets you know when polling a service fails.
50 # INFO additionally lets you know when a compute node is started or stopped.
51 level = INFO
52
53 # You can also set different log levels for specific libraries.
54 # Pykka is the Node Manager's actor library.
55 # Setting this to DEBUG will display tracebacks for uncaught
56 # exceptions in the actors, but it's also very chatty.
57 pykka = WARNING
58
59 # Setting apiclient to INFO will log the URL of every Arvados API request.
60 apiclient = WARNING
61
62 [Arvados]
63 host = zyxwv.arvadosapi.com
64 token = ARVADOS_TOKEN
65 timeout = 15
66
67 # Accept an untrusted SSL certificate from the API server?
68 insecure = no
69
70 [Cloud]
71 provider = gce
72
73 # Shutdown windows define periods of time when a node may and may not
74 # be shut down.  These are windows in full minutes, separated by
75 # commas.  Counting from the time the node is booted, the node WILL
76 # NOT shut down for N1 minutes; then it MAY shut down for N2 minutes;
77 # then it WILL NOT shut down for N3 minutes; and so on.  For example,
78 # "54, 5, 1" means the node may shut down from the 54th to the 59th
79 # minute of each hour of uptime.
80 # GCE bills by the minute, and does not provide information about when
81 # a node booted.  Node Manager will store this information in metadata
82 # when it boots a node; if that information is not available, it will
83 # assume the node booted at the epoch.  These shutdown settings are
84 # very aggressive.  You may want to adjust this if you want more
85 # continuity of service from a single node.
86 shutdown_windows = 20, 999999
87
88 [Cloud Credentials]
89 user_id = client_email_address@developer.gserviceaccount.com
90 key = path_to_certificate.pem
91 project = project-id-from-google-cloud-dashboard
92 timeout = 60
93
94 # Valid location (zone) names: https://cloud.google.com/compute/docs/zones
95 datacenter = us-central1-a
96
97 # Optional settings. For full documentation see
98 # http://libcloud.readthedocs.org/en/latest/compute/drivers/gce.html#libcloud.compute.drivers.gce.GCENodeDriver
99 #
100 # auth_type = SA               # SA, IA or GCE
101 # scopes = https://www.googleapis.com/auth/compute
102 # credential_file =
103
104 [Cloud List]
105 # A comma-separated list of tags that must be applied to a node for it to
106 # be considered a compute node.
107 # The driver will automatically apply these tags to nodes it creates.
108 tags = zyxwv, compute
109
110 [Cloud Create]
111 # New compute nodes will send pings to Arvados at this host.
112 # You may specify a port, and use brackets to disambiguate IPv6 addresses.
113 ping_host = hostname:port
114
115 # A file path for an SSH key that can log in to the compute node.
116 # ssh_key = path
117
118 # The GCE image name and network zone name to use when creating new nodes.
119 image = debian-7
120 # network = your_network_name
121
122 # JSON string of service account authorizations for this cluster.
123 # See http://libcloud.readthedocs.org/en/latest/compute/drivers/gce.html#specifying-service-account-scopes
124 # service_accounts = [{'email':'account@example.com', 'scopes':['storage-ro']}]
125
126
127 # You can define any number of Size sections to list node sizes you're
128 # willing to use.  The Node Manager should boot the cheapest size(s) that
129 # can run jobs in the queue.
130 #
131 # The Size fields are interpreted the same way as with a libcloud NodeSize:
132 # http://libcloud.readthedocs.org/en/latest/compute/api.html#libcloud.compute.base.NodeSize
133 #
134 # See https://cloud.google.com/compute/docs/machine-types for a list
135 # of known machine types that may be used as a Size parameter.
136 #
137 # Each size section MUST define the number of cores are available in this
138 # size class (since libcloud does not provide any consistent API for exposing
139 # this setting).
140 # You may also want to define the amount of scratch space (expressed
141 # in GB) for Crunch jobs.
142 # You can also override Google's provided data fields (such as price per hour)
143 # by setting them here.
144
145 [Size n1-standard-2]
146 cores = 2
147 price = 0.076
148 scratch = 100
149
150 [Size n1-standard-4]
151 cores = 4
152 price = 0.152
153 scratch = 200