mirror of
https://github.com/apache/cloudstack.git
synced 2025-12-15 18:12:35 +01:00
CLOUDSTACK-2450: Fix userdata to be urlencoded safely
urlencoding the userdata and quoting the = since apiserver will strip them out. This will send an invalid userdata down to the plugin (vmops) where base64 decoding fails causing vm deployment to fail. Signed-off-by: Prasanna Santhanam <tsp@apache.org>
This commit is contained in:
parent
32c8cd3cd7
commit
4be18aefc4
@ -376,7 +376,7 @@ class VirtualMachine:
|
||||
cmd.hostid = hostid
|
||||
|
||||
if "userdata" in services:
|
||||
cmd.userdata = base64.b64encode(services["userdata"])
|
||||
cmd.userdata = base64.urlsafe_b64encode(services["userdata"])
|
||||
|
||||
if group:
|
||||
cmd.group = group
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user