Added ONEADMIN_USER_SSH_PUBLIC_KEY parameter to load oneadmin user's ssh key by default when creating VM via DCL flow

This commit is contained in:
PCoder 2017-08-15 02:29:01 +05:30
parent 3b1cd200d6
commit 73721f16d2
2 changed files with 4 additions and 0 deletions

View file

@ -482,6 +482,7 @@ class OrderConfirmationView(DetailView):
vm_id = manager.create_vm(
template_id=vm_template_id,
specs=specs,
ssh_key=settings.ONEADMIN_USER_SSH_PUBLIC_KEY,
vm_name="{email}-{template_name}-{date}".format(
email=user.get('email'),
template_name=template.get('name'),

View file

@ -504,6 +504,9 @@ OPENNEBULA_PORT = env('OPENNEBULA_PORT')
# default value is /RPC2
OPENNEBULA_ENDPOINT = env('OPENNEBULA_ENDPOINT')
# The public ssh key of the oneadmin user
ONEADMIN_USER_SSH_PUBLIC_KEY = env('ONEADMIN_USER_SSH_PUBLIC_KEY')
# dcl email configurations
DCL_TEXT = env('DCL_TEXT')
DCL_SUPPORT_FROM_ADDRESS = env('DCL_SUPPORT_FROM_ADDRESS')