Fix: set execute_in to ['lxc', 'vm'] for addon type in push_json_to_pocketbase workflow

Agent-Logs-Url: https://github.com/community-scripts/ProxmoxVED/sessions/229f4038-6916-4f1b-b6be-c6727b1274c1

Co-authored-by: MickLesk <47820557+MickLesk@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2026-03-29 09:51:00 +00:00
committed by GitHub
parent 1f1a8d2400
commit 5c2c89774f

View File

@@ -206,8 +206,8 @@ jobs:
if (!fs.existsSync(file)) continue; if (!fs.existsSync(file)) continue;
const data = JSON.parse(fs.readFileSync(file, 'utf8')); const data = JSON.parse(fs.readFileSync(file, 'utf8'));
if (!data.slug) { console.log('Skipping', file, '(no slug)'); continue; } if (!data.slug) { console.log('Skipping', file, '(no slug)'); continue; }
// execute_in: map type to canonical value (addon has no execute_in context) // execute_in: map type to canonical value (addon runs on both lxc and vm)
var executeInMap = { ct: 'lxc', lxc: 'lxc', turnkey: 'turnkey', pve: 'pve', vm: 'vm' }; var executeInMap = { ct: 'lxc', lxc: 'lxc', turnkey: 'turnkey', pve: 'pve', vm: 'vm', addon: ['lxc', 'vm'] };
var executeIn = data.type ? (executeInMap[data.type.toLowerCase()] || null) : null; var executeIn = data.type ? (executeInMap[data.type.toLowerCase()] || null) : null;
// github: extract owner/repo from full GitHub URL // github: extract owner/repo from full GitHub URL
var githubField = null; var githubField = null;