Merge "Replace all templates/(.*)\.yaml with templates/\1"
This commit is contained in:
commit
a03bcea57e
@ -5,7 +5,7 @@ function deploy {
|
||||
# this two commands will clean db
|
||||
solar resource clear_all
|
||||
|
||||
solar resource create nodes templates/nodes.yaml '{"count": 1}'
|
||||
solar resource create nodes templates/nodes '{"count": 1}'
|
||||
solar resource create mariadb1 /vagrant/resources/mariadb_service image=mariadb port=3306
|
||||
solar connect node1 mariadb1
|
||||
|
||||
|
@ -10,7 +10,7 @@ from solar.dblayer.model import ModelMeta
|
||||
def run():
|
||||
ModelMeta.remove_all()
|
||||
|
||||
resources = vr.create('nodes', 'templates/nodes.yaml', {'count': 2})
|
||||
resources = vr.create('nodes', 'templates/nodes', {'count': 2})
|
||||
|
||||
node1, node2 = [x for x in resources if x.name.startswith('node')]
|
||||
hosts1, hosts2 = [x for x in resources
|
||||
|
@ -5,7 +5,7 @@ Run it from /vagrant dir:
|
||||
|
||||
```
|
||||
solar resource clear_all
|
||||
solar resource create nodes templates/nodes.yaml '{"count": 1}'
|
||||
solar resource create nodes templates/nodes '{"count": 1}'
|
||||
solar resource create librarian_example examples/librarian/librarian.yaml '{"node": "node1"}'
|
||||
|
||||
solar changes stage
|
||||
|
@ -26,5 +26,5 @@ solar res action run ceph_mon1
|
||||
To add repositories use
|
||||
|
||||
```
|
||||
solar resource create apt1 templates/mos_repos.yaml node=node1 index=1
|
||||
solar resource create apt1 templates/mos_repos node=node1 index=1
|
||||
```
|
||||
|
@ -33,7 +33,7 @@ NETWORK_METADATA = yaml.load("""
|
||||
|
||||
def deploy():
|
||||
ModelMeta.remove_all()
|
||||
resources = vr.create('nodes', 'templates/nodes.yaml', {'count': 2})
|
||||
resources = vr.create('nodes', 'templates/nodes', {'count': 2})
|
||||
first_node, second_node = [x for x in resources if x.name.startswith('node')]
|
||||
first_transp = next(x for x in resources if x.name.startswith('transport'))
|
||||
|
||||
@ -60,7 +60,7 @@ def deploy():
|
||||
})[0]
|
||||
|
||||
managed_apt = vr.create(
|
||||
'managed_apt1', 'templates/mos_repos.yaml',
|
||||
'managed_apt1', 'templates/mos_repos',
|
||||
{'node': first_node.name, 'index': 0})[-1]
|
||||
|
||||
keys.connect(ceph_mon, {})
|
||||
|
@ -45,8 +45,8 @@ def lxc_template(idx):
|
||||
def deploy():
|
||||
ModelMeta.remove_all()
|
||||
|
||||
node1 = vr.create('nodes', 'templates/nodes.yaml', {})[0]
|
||||
seed = vr.create('nodes', 'templates/seed_node.yaml', {})[0]
|
||||
node1 = vr.create('nodes', 'templates/nodes', {})[0]
|
||||
seed = vr.create('nodes', 'templates/seed_node', {})[0]
|
||||
|
||||
ssh_key = vr.create('ssh_key1', 'resources/ssh_key', {
|
||||
'keys_dir': '/vagrant/.ssh',
|
||||
|
@ -40,9 +40,9 @@ def main():
|
||||
|
||||
|
||||
def prepare_nodes(nodes_count):
|
||||
resources = vr.create('nodes', 'templates/nodes_with_transports.yaml', {"count": nodes_count})
|
||||
resources = vr.create('nodes', 'templates/nodes_with_transports', {"count": nodes_count})
|
||||
nodes = [x for x in resources if x.name.startswith('node')]
|
||||
resources = vr.create('nodes_network', 'templates/nodes_network.yaml', {"count": nodes_count})
|
||||
resources = vr.create('nodes_network', 'templates/nodes_network', {"count": nodes_count})
|
||||
nodes_sdn = [x for x in resources if x.name.startswith('node')]
|
||||
r = {}
|
||||
|
||||
|
@ -40,7 +40,7 @@ requests.post(bareon_sync)
|
||||
nodes_list = requests.get(discovery_service).json()
|
||||
|
||||
# Create slave node resources
|
||||
node_resources = vr.create('nodes', 'templates/not_provisioned_nodes.yaml',
|
||||
node_resources = vr.create('nodes', 'templates/not_provisioned_nodes',
|
||||
{'nodes': nodes_list})
|
||||
|
||||
# Get master node
|
||||
|
@ -30,21 +30,21 @@ resources:
|
||||
riaks: ['riak_service1', 'riak_service2', 'riak_service3']
|
||||
|
||||
- id: haproxy1
|
||||
from: templates/haproxy.yaml
|
||||
from: templates/haproxy
|
||||
values:
|
||||
node: {{nodes[0]}}
|
||||
service_configs: ['haproxy_riak_config_pb', 'haproxy_riak_config_http']
|
||||
index: 1
|
||||
|
||||
- id: haproxy2
|
||||
from: templates/haproxy.yaml
|
||||
from: templates/haproxy
|
||||
values:
|
||||
node: {{nodes[1]}}
|
||||
service_configs: ['haproxy_riak_config_pb', 'haproxy_riak_config_http']
|
||||
index: 2
|
||||
|
||||
- id: haproxy3
|
||||
from: templates/haproxy.yaml
|
||||
from: templates/haproxy
|
||||
values:
|
||||
node: {{nodes[2]}}
|
||||
service_configs: ['haproxy_riak_config_pb', 'haproxy_riak_config_http']
|
||||
|
@ -15,7 +15,7 @@ from solar.dblayer.model import ModelMeta
|
||||
def setup_riak():
|
||||
|
||||
ModelMeta.remove_all()
|
||||
nodes = template.nodes_from('templates/riak_nodes.yaml')
|
||||
nodes = template.nodes_from('templates/riak_nodes')
|
||||
|
||||
riak_services = nodes.on_each(
|
||||
'resources/riak_node',
|
||||
|
@ -31,7 +31,7 @@ from solar.dblayer.solar_models import Resource
|
||||
def setup_riak():
|
||||
|
||||
ModelMeta.remove_all()
|
||||
resources = vr.create('nodes', 'templates/nodes.yaml', {'count': 3})
|
||||
resources = vr.create('nodes', 'templates/nodes', {'count': 3})
|
||||
nodes = [x for x in resources if x.name.startswith('node')]
|
||||
hosts_services = [x for x in resources if x.name.startswith('hosts_file')]
|
||||
node1, node2, node3 = nodes
|
||||
|
@ -28,7 +28,7 @@ def setup_riak(nodes_num=None, hosts_mapping=False):
|
||||
nodes_num = NODES
|
||||
db.clear()
|
||||
|
||||
resources = vr.create('nodes', 'templates/nodes.yaml', {'count': nodes_num})
|
||||
resources = vr.create('nodes', 'templates/nodes', {'count': nodes_num})
|
||||
nodes = [x for x in resources if x.name.startswith('node')]
|
||||
hosts_services = [x for x in resources if x.name.startswith('hosts_file')]
|
||||
|
||||
|
@ -19,7 +19,7 @@ resources:
|
||||
ssh_key: '#{ssh_key}#'
|
||||
|
||||
- id: keystone_base
|
||||
from: templates/keystone_base.yaml
|
||||
from: templates/keystone_base
|
||||
values:
|
||||
login_user: root
|
||||
login_password: 'mariadb_service::root_password'
|
||||
@ -33,7 +33,7 @@ resources:
|
||||
ssh_key: '#{ssh_key}#'
|
||||
|
||||
- id: keystone_api_1
|
||||
from: templates/keystone_api.yaml
|
||||
from: templates/keystone_api
|
||||
values:
|
||||
idx: 1
|
||||
db_password: 'keystone_db_user::user_password'
|
||||
@ -49,7 +49,7 @@ resources:
|
||||
ssh_key: '#{ssh_key}#'
|
||||
|
||||
- id: openstack_base
|
||||
from: templates/openstack_base.yaml
|
||||
from: templates/openstack_base
|
||||
values:
|
||||
ip: '#{ip}#'
|
||||
ssh_user: '#{ssh_user}#'
|
||||
|
@ -2,7 +2,7 @@ id: glance_#{idx}#
|
||||
|
||||
resources:
|
||||
- id: glance_base_#{ idx }#
|
||||
from: templates/glance_db.yaml
|
||||
from: templates/glance_db
|
||||
values:
|
||||
idx: '#{ idx }#'
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user