nuageinit: only parse user_data as yaml when necessary
This fixes a regression introduced in cae280931c which prevents
user_data as a shell script to be used
PR: 295062
Reported by: Ross McKelvie <ross@exitzero.uk>
MFC After: 1 day
This commit is contained in:
@@ -727,7 +727,7 @@ local function load_userdata()
|
||||
f:close()
|
||||
|
||||
local obj = nil
|
||||
if ud then
|
||||
if ud and line == "#cloud-config" then
|
||||
f = io.open(ni_path .. "/" .. ud)
|
||||
obj = yaml.load(f:read("*a"))
|
||||
f:close()
|
||||
|
||||
Reference in New Issue
Block a user