summaryrefslogtreecommitdiff
path: root/yarns/900-local.yarn
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2018-02-07 18:54:13 +0200
committerLars Wirzenius <liw@liw.fi>2018-02-09 19:11:02 +0200
commit5cf3781ad4beddfab5aa7181c0990a5462ffe06f (patch)
treea50a769bc8b6cc7e31f28466002c7dc15f2433b4 /yarns/900-local.yarn
parent4b6fd81e121935f60f29b8314bc7c44726bf6fd7 (diff)
downloadick2-5cf3781ad4beddfab5aa7181c0990a5462ffe06f.tar.gz
Change: make all .service units be conditional on config
If the config file is missing, the unit won't start.
Diffstat (limited to 'yarns/900-local.yarn')
-rw-r--r--yarns/900-local.yarn13
1 files changed, 13 insertions, 0 deletions
diff --git a/yarns/900-local.yarn b/yarns/900-local.yarn
index 2739542..5efad69 100644
--- a/yarns/900-local.yarn
+++ b/yarns/900-local.yarn
@@ -46,6 +46,9 @@ 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()
+
## Start and stop the controller
IMPLEMENTS GIVEN a running ick controller
@@ -64,6 +67,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
},
],
'statedir': vars['statedir'],
+ 'blob-service': vars['blob_service'],
}
env = dict(os.environ)
env['ICK_CONTROLLER_CONFIG'] = 'ick_controller.yaml'
@@ -103,6 +107,15 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
filename = os.path.join(vars['statedir'], 'workers', basename + '.yaml')
assertTrue(os.path.exists(filename))
+## Check version result
+
+ IMPLEMENTS THEN blob service URL is (\S+)
+ expected = get_next_match()
+ body = vars['body']
+ obj = json.loads(body)
+ actual = obj['blob_service']
+ assertEqual(actual, expected)
+
## Start and stop blob service
IMPLEMENTS GIVEN blob service config uses (\S+) at the blob directory