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:
Baptiste Daroussin
2026-05-06 22:14:17 +02:00
parent 84a9574180
commit c316ec2590
+1 -1
View File
@@ -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()