Add ability to specify target-manifest for Armada
Change-Id: Ica00512062fb19ae395544c254de517fe0161e12
This commit is contained in:
parent
b4449434a5
commit
8c468b359b
|
@ -23,6 +23,8 @@ Here is a complete sample document:
|
|||
data:
|
||||
hostname: n0
|
||||
ip: 192.168.77.10
|
||||
armada:
|
||||
target_manifest: cluster-bootstrap
|
||||
labels:
|
||||
static:
|
||||
- calico-etcd=enabled
|
||||
|
@ -49,6 +51,14 @@ Here is a complete sample document:
|
|||
mode: 0644
|
||||
|
||||
|
||||
Amrada
|
||||
------
|
||||
|
||||
This section contains particular configuration options for bootstrapping with
|
||||
Armada. It currently only supports a single option: ``target_manifest``, which
|
||||
specifies which ``armada/Manifest/v1`` to be used during Genesis.
|
||||
|
||||
|
||||
Bootstrapping Images
|
||||
--------------------
|
||||
|
||||
|
|
|
@ -9,6 +9,8 @@ metadata:
|
|||
data:
|
||||
hostname: n0
|
||||
ip: 192.168.77.10
|
||||
armada:
|
||||
target_manifest: cluster-bootstrap
|
||||
labels:
|
||||
dynamic:
|
||||
- calico-etcd=enabled
|
||||
|
|
|
@ -10,6 +10,8 @@ metadata:
|
|||
data:
|
||||
hostname: n0
|
||||
ip: 192.168.77.10
|
||||
armada:
|
||||
target_manifest: cluster-bootstrap
|
||||
labels:
|
||||
dynamic:
|
||||
- calico-etcd=enabled
|
||||
|
|
|
@ -55,11 +55,9 @@ class Configuration:
|
|||
return cls(documents=documents, **kwargs)
|
||||
|
||||
def __getitem__(self, path):
|
||||
value = self.get_path(path)
|
||||
if value:
|
||||
return value
|
||||
else:
|
||||
return jinja2.StrictUndefined('No match found for path %s' % path)
|
||||
return self.get_path(path,
|
||||
jinja2.StrictUndefined(
|
||||
'No match found for path %s' % path))
|
||||
|
||||
def get_first(self, *paths):
|
||||
result = self._get_first(*paths)
|
||||
|
|
|
@ -57,6 +57,13 @@ data:
|
|||
|
||||
type: object
|
||||
properties:
|
||||
armada:
|
||||
type: object
|
||||
properties:
|
||||
target_manifest:
|
||||
type: string
|
||||
additionalProperties: false
|
||||
|
||||
files:
|
||||
type: array
|
||||
items:
|
||||
|
|
|
@ -59,7 +59,11 @@ spec:
|
|||
|
||||
while true; do
|
||||
sleep 10
|
||||
if armada --debug apply --tiller-host 127.0.0.1 /etc/genesis/armada/assets/manifest.yaml &>> "${ARMADA_LOGFILE}"; then
|
||||
if armada --debug \
|
||||
apply \
|
||||
--target-manifest {{ config.get_path('Genesis:armada.target_manifest', 'cluster-bootstrap') }} \
|
||||
--tiller-host 127.0.0.1 \
|
||||
/etc/genesis/armada/assets/manifest.yaml &>> "${ARMADA_LOGFILE}"; then
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
|
Loading…
Reference in New Issue