Skip to content

Commit d152a52

Browse files
Update deploy.yaml
1 parent 536828b commit d152a52

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

.github/workflows/deploy.yaml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ on:
7070
default: ""
7171

7272
# Mode B (multi app)
73-
applicationDetails:
73+
application_details:
7474
description: >-
7575
JSON array where each item maps:
7676
{ "name" => application, "images" => image_base_names[], "path" => deploy_path }
@@ -363,7 +363,7 @@ jobs:
363363
id: apps
364364
uses: actions/github-script@v7
365365
env:
366-
APP_DETAILS: ${{ inputs.applicationDetails }}
366+
APP_DETAILS: ${{ inputs.application_details }}
367367
APPLICATION: ${{ inputs.application }}
368368
DEPLOY_PATH: ${{ inputs.deploy_path }}
369369
IMG_ONE: ${{ inputs.image_base_name }}
@@ -375,15 +375,15 @@ jobs:
375375
if (detailsRaw) {
376376
let arr;
377377
try { arr = JSON.parse(detailsRaw); }
378-
catch(e){ core.setFailed(`❌ applicationDetails is not valid JSON: ${e.message}`); return; }
379-
if (!Array.isArray(arr)) { core.setFailed('❌ applicationDetails must be a JSON array'); return; }
378+
catch(e){ core.setFailed(`❌ application_details is not valid JSON: ${e.message}`); return; }
379+
if (!Array.isArray(arr)) { core.setFailed('❌ application_details must be a JSON array'); return; }
380380
for (let i=0;i<arr.length;i++){
381381
const it = arr[i] || {};
382382
const name = String(it.name || '').trim();
383383
const path = String(it.path || '').trim();
384384
const images = Array.isArray(it.images) ? it.images.map(String) : [];
385-
if (!name) { core.setFailed(`❌ applicationDetails[${i}].name is required`); return; }
386-
if (!path) { core.setFailed(`❌ applicationDetails[${i}].path is required`); return; }
385+
if (!name) { core.setFailed(`❌ application_details[${i}].name is required`); return; }
386+
if (!path) { core.setFailed(`❌ application_details[${i}].path is required`); return; }
387387
apps.push({ name, path, images });
388388
}
389389
} else {
@@ -395,8 +395,8 @@ jobs:
395395
if ((process.env.IMG_LIST || '').trim()) {
396396
for (const s of process.env.IMG_LIST.split(',').map(x => x.trim()).filter(Boolean)) images.push(s);
397397
}
398-
if (!name) { core.setFailed('❌ application is required when applicationDetails is not provided'); return; }
399-
if (!path) { core.setFailed('❌ deploy_path is required when applicationDetails is not provided'); return; }
398+
if (!name) { core.setFailed('❌ application is required when application_details is not provided'); return; }
399+
if (!path) { core.setFailed('❌ deploy_path is required when application_details is not provided'); return; }
400400
apps.push({ name, path, images });
401401
}
402402
core.setOutput('apps', JSON.stringify(apps));

0 commit comments

Comments
 (0)