Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 import os | |
| 2 # Copyright 2016 The Chromium Authors. All rights reserved. | |
| 3 # Use of this source code is governed by a BSD-style license that can be | |
| 4 # found in the LICENSE file. | |
| 5 | |
| 6 from recipe_engine.config import config_item_context, ConfigGroup | |
| 7 from recipe_engine.config import Single | |
| 8 | |
| 9 | |
| 10 def BaseConfig(): | |
| 11 return ConfigGroup( | |
| 12 accounts_path = Single(str, required=True), | |
| 13 authutil_path = Single(str, required=True)) | |
| 14 | |
| 15 | |
| 16 config_ctx = config_item_context(BaseConfig) | |
| 17 | |
| 18 | |
| 19 @config_ctx() | |
| 20 def service_account_windows(c): | |
| 21 c.accounts_path = 'C:\\creds\\service_accounts' | |
| 22 c.authutil_path = 'C:\\infra-tools\\authutil.exe' | |
|
nodir
2016/05/06 20:32:09
why AUTHUTILPATH is not read on windows?
nodir
2016/05/06 20:38:01
apparently we should not use env in recipes becaus
nodir
2016/05/06 20:38:01
also please add a TODO that authutil should be ins
RobertoCN
2016/05/06 21:38:10
Done.
RobertoCN
2016/05/06 21:38:11
Done.
RobertoCN
2016/05/06 21:38:11
Removed the reading of the env variable completely
| |
| 23 | |
| 24 | |
| 25 @config_ctx() | |
| 26 def service_account_default(c): | |
| 27 c.accounts_path = '/creds/service_accounts' | |
| 28 c.authutil_path = os.environ.get( | |
| 29 'AUTHUTILPATH', '/opt/infra-tools/authutil') | |
| OLD | NEW |