Commit 90558870 authored by Vivien Alger's avatar Vivien Alger

New flavor of KVM with an ssh access

parent e01342cb
......@@ -4,8 +4,7 @@ kvm
Introduction
------------
This software release is used to deploy KVM instances, NBD instances and
Frontend instances of KVM.
This software release is used to deploy KVM instances with a ssh access.
For extensive parameters definition, please look at parameter-input-schema.json.
......@@ -18,47 +17,31 @@ Software Release from slap console or command line.
KVM instance (1GB of RAM, 10GB of SSD, one core)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Note that the KVM instance will try to request a frontend slave instance in order
to be accessible from IPv4.
Note that for this flavor of KVM you will need to pass a public key for ssh
access.
Also note that since this is a special release you WILL(most likely) have to
use the development.cfg rather than the software.cfg file for specifying your
software release
::
myawesomekvm = request(
software_release=kvm,
software_release="/path_to_your_slapos_repository(or url)/software/manual_kvm/development.cfg",
partition_reference="My awesome KVM",
partition_parameter_kw={
"nbd-host":"ubuntu-1204.nbd.vifib.net",
"authorized-key":"<your public key>"
}
)
See the instance-kvm-input-schema.json file for more instance parameters (cpu-count, ram-size, disk-size, etc).
NBD instance
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This type of instance will allow to host a disk image that will be used by
any KVM instance.
::
mynbd = request(
software_release=kvm,
partition_reference="mynbd",
software_type="nbd",
)
Once requested your instance shall appear on slapos.org in the "My services" section.
Starting your instance
~~~~~~~~~~~~~~~~~~~~~~
KVM Frontend Master Instance (will host all frontend Slave Instances)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This type of instance will allow to host any frontend slave instance requested
by KVM instances. Slave instances (and thus KVM instance) will be accessible
at : https://mydomain.com/instancereference .
All the scripts generated by SlapOS can be found in /instance_home/etc/scripts.
If you want to start your instance without those, you can access the binaries
through the /instance_home/software_release/bin directory.
::
mykvmfrontend = request(
software_release=kvm,
partition_reference="mykvmfrontend",
partition_parameter_kw={
"domain":"mydomain.com"
},
software_type="frontend",
)
SlapOS will only start the ssh server, everything else is up to you.
......@@ -72,7 +72,7 @@ command =
[template-kvm]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-kvm.cfg.in
#md5sum = cb8adfb70882a07e1df3943983c27963
md5sum = 0d7f19172d62d9f024fec6b0ce7b1a19
output = ${buildout:directory}/template-kvm.cfg
mode = 0644
......
......@@ -84,6 +84,14 @@
"type": "string",
"format": "uri",
"default": "http://git.erp5.org/gitweb/slapos.git/blob_plain/refs/tags/slapos-0.92:/software/kvm/software.cfg"
},
"authorized-key": {
"title": "Authorized key for ssh connection",
"description": "Authorized key for ssh connection",
"type": "string",
"default": ""
}
}
}
......@@ -20,6 +20,13 @@
"description": "Password used to authenticate in the service webpage.",
"type": "uri",
"required": true
}
},
"ssh_connection": {
"title": "SSH connection",
"description": "SSH connection string",
"type": "string",
"required": true
}
}
}
......@@ -232,6 +232,8 @@ recipe = slapos.cookbook:publish
backend-url = https://[$${novnc-instance:ip}]:$${novnc-instance:port}/vnc_auto.html?host=[$${novnc-instance:ip}]&port=$${novnc-instance:port}&encrypt=1
password = $${kvm-instance:passwd}
url = $${request-slave-frontend:connection-url}/vnc_auto.html?host=$${request-slave-frontend:connection-domainname}&port=$${request-slave-frontend:connection-port}&encrypt=1&path=$${request-slave-frontend:connection-resource}
ssh_connection = ssh $${dropbear-server:host} -p $${dropbear-server:port}
ip = $${dropbear-server:host}
[dropbear-promise]
recipe = slapos.cookbook:check_port_listening
......@@ -251,7 +253,7 @@ curl_path = ${curl:location}/bin/curl
frontend-software-type = frontend
frontend-software-url = http://git.erp5.org/gitweb/slapos.git/blob_plain/refs/tags/slapos-0.92:/software/kvm/software.cfg
frontend-instance-guid =
#Default value for authorized-key
authorized-key =
nbd-port = 1024
......
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