diff options
Diffstat (limited to 'yarns/900-local.yarn')
-rw-r--r-- | yarns/900-local.yarn | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/yarns/900-local.yarn b/yarns/900-local.yarn index 5efad69..4e9dbe1 100644 --- a/yarns/900-local.yarn +++ b/yarns/900-local.yarn @@ -46,8 +46,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. IMPLEMENTS GIVEN controller config uses (\S+) at the state directory vars['statedir'] = get_next_match() - IMPLEMENTS GIVEN controller config uses (\S+) as blob service - vars['blob_service'] = get_next_match() + IMPLEMENTS GIVEN controller config uses (\S+) as artifact store + vars['artifact_store'] = get_next_match() ## Start and stop the controller @@ -67,7 +67,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. }, ], 'statedir': vars['statedir'], - 'blob-service': vars['blob_service'], + 'artifact-store': vars['artifact_store'], } env = dict(os.environ) env['ICK_CONTROLLER_CONFIG'] = 'ick_controller.yaml' @@ -109,22 +109,22 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. ## Check version result - IMPLEMENTS THEN blob service URL is (\S+) + IMPLEMENTS THEN artifact store URL is (\S+) expected = get_next_match() body = vars['body'] obj = json.loads(body) - actual = obj['blob_service'] + actual = obj['artifact_store'] assertEqual(actual, expected) -## Start and stop blob service +## Start and stop artifact store - IMPLEMENTS GIVEN blob service config uses (\S+) at the blob directory + IMPLEMENTS GIVEN artifact store config uses (\S+) at the blob directory vars['blobdir'] = get_next_match() - IMPLEMENTS GIVEN a running blob service + IMPLEMENTS GIVEN a running artifact store import os, time, cliapp, yaml - vars['blob_service.log'] = 'blob_service.log' - vars['gunicorn3_bs.log'] = 'gunicorn3_bs.log' + vars['artifact_store.log'] = 'artifact_store.log' + vars['gunicorn3_as.log'] = 'gunicorn3_as.log' vars['bsport'] = random_free_port() vars['bsurl'] = 'http://127.0.0.1:{}'.format(vars['bsport']) config = { @@ -133,27 +133,27 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. 'token-public-key': cat('token.key.pub'), 'log': [ { - 'filename': vars['blob_service.log'], + 'filename': vars['artifact_store.log'], }, ], 'blobdir': vars['blobdir'], } env = dict(os.environ) - env['BLOB_SERVICE_CONFIG'] = 'blob_service.yaml' - yaml.safe_dump(config, open('blob_service.yaml', 'w')) + env['ARTIFACT_STORE_CONFIG'] = 'artifact_store.yaml' + yaml.safe_dump(config, open('artifact_store.yaml', 'w')) argv = [ 'gunicorn3', '--daemon', '--bind', '127.0.0.1:{}'.format(vars['bsport']), - '--log-file', vars['gunicorn3_bs.log'], + '--log-file', vars['gunicorn3_as.log'], '--log-level', 'debug', '-p', 'bspid', - 'blob_service:app', + 'artifact_store:app', ] cliapp.runcmd(argv, env=env) vars['bspid'] = int(cat('bspid')) wait_for_port(vars['bsport']) - IMPLEMENTS FINALLY stop blob service + IMPLEMENTS FINALLY stop artifact store import os, signal os.kill(vars['bspid'], signal.SIGTERM) |