Commit 270b7fcb authored by Cédric Le Ninivin's avatar Cédric Le Ninivin

html5as: Add basic replicate software type

parent fed8d47c
......@@ -17,7 +17,7 @@
[template-cfg]
filename = instance.cfg.in
md5sum = 8a1383f7508a911c0c2d81445b5d4250
md5sum = 6ed5d779fd0518ebd574f4629467b43d
[instance_html5as]
_update_hash_filename_ = instance_html5as.cfg.in
......@@ -42,3 +42,8 @@ md5sum = d57cb01df5941e139b02a2f7bdabcdc8
[template_graceful]
_update_hash_filename_ = templates/graceful.in
md5sum = 1c0ee16966e1fcdb3fd11c09f12ee2b2
[template_instance_replicate]
_update_hash_filename_ = instance_replicate.cfg.in
md5sum = c5cf3925503e03334816b0d0d6787eb8
......@@ -27,6 +27,16 @@ context =
section buildout buildout
section parameter_list profile-common
[instance-replicate]
recipe = slapos.recipe.template:jinja2
template = {{ template_instance_replicate }}
rendered = ${buildout:directory}/${:filename}
filename = instance-replicate-html5as.cfg
context =
section buildout buildout
section parameter_list profile-common
[switch-softwaretype]
recipe = slapos.cookbook:softwaretype
default = ${instance-html5as:rendered}
replicate = ${instance-replicate:rendered}
[buildout]
parts =
publish-connection-information
eggs-directory = {{ buildout['eggs-directory'] }}
develop-eggs-directory = {{ buildout['develop-eggs-directory'] }}
offline = true
[instance-request-base]
<= slap-connection
recipe = slapos.cookbook:request
# It is the same software as the current one
software-url = ${slap-connection:software-release-url}
# We want the default behaviour
software-type = default
# What parameter are neede to be retrieved
return = server_url server-cdn-url monitor-setup-url
# Provided parameters
config-title = ${slap-parameter:title}
config-download_url = ${slap-parameter:download_url}
# Request a normal html5as instance
[instance-1]
<= instance-request-base
# Name of the instanc e
name = instance-html5as-1
config-port = ${slap-parameter:port1}
config-title = ${slap-parameter:title1}
[instance-2]
<= instance-request-base
# Name of the instance
name = instance-html5as-2
config-port = ${slap-parameter:port2}
config-title = ${slap-parameter:title2}
[slap-parameter]
title1 =
title2 =
download_url =
port1 = 8081
port2 = 8082
[publish-connection-information]
recipe = slapos.cookbook:publish
instance-1-server_url = ${instance-1:connection-server_url}
instance-1-server-cdn-url = ${instance-1:connection-server-cdn-url}
instance-1-server-monitor-setup-url = ${instance-1:connection-monitor-setup-url}
instance-2-server_url = ${instance-2:connection-server_url}
instance-2-server-cdn-url = ${instance-1:connection-server-cdn-url}
instance-2-server-monitor-setup-url = ${instance-1:connection-monitor-setup-url}
......@@ -44,6 +44,7 @@ context =
key template_instance_html5as_target instance_html5as:target
key template_index_html_target template_index_html:target
key template_graceful_target template_graceful:target
key template_instance_replicate template_instance_replicate:target
# Monitor stack also provides a template for the instance
key template_monitor monitor2-template:rendered
......@@ -76,6 +77,9 @@ mode = 0644
[template_graceful]
<= download-base
[template_instance_replicate]
<= download-base
# Pin versions of eggs used that are not already pinned by stack/slapos.cfg
[versions]
slapos.recipe.template = 4.4
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment