balena-cli 23.2.7-build-validate-installer-secureboot-b46212b61823e87ee7a7b1931c4bbc435a40ba2e-1 → 23.2.8-build-renovate-apple-actions-import-codesign-certs-4-x-0c66c774af30a7e13043e4daae9146e9a72a1865-1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -4,11 +4,15 @@ All notable changes to this project will be documented in this file
4
4
  automatically by Versionist. DO NOT EDIT THIS FILE MANUALLY!
5
5
  This project adheres to [Semantic Versioning](http://semver.org/).
6
6
 
7
- ## 23.2.7 - 2025-12-06
7
+ ## 23.2.8 - 2025-12-08
8
+
9
+ * Update apple-actions/import-codesign-certs action to v4 [balena-renovate[bot]]
10
+
11
+ ## 23.2.7 - 2025-12-08
8
12
 
9
- * Add test for os configure --config using secureboot [Thodoris Greasidis]
10
- * os configure, device init: Validate that the config.json's installer.secureboot is a boolean when set [Thodoris Greasidis]
11
13
  * Update @balena/lint to 9.3.7 to support async disposables [Thodoris Greasidis]
14
+ * Add tests for os configure --config [Thodoris Greasidis]
15
+ * os configure: Fix asking interactive questions when --config is used [Thodoris Greasidis]
12
16
 
13
17
  ## 23.2.6 - 2025-12-05
14
18
 
@@ -58,10 +58,21 @@ class OsConfigureCmd extends core_1.Command {
58
58
  await validateDevOptionAndWarn(developmentMode, osVersion);
59
59
  const { validateSecureBootOptionAndWarn } = await Promise.resolve().then(() => require('../../utils/config'));
60
60
  await validateSecureBootOptionAndWarn(secureBoot, deviceTypeSlug, osVersion);
61
- const answers = await askQuestionsForDeviceType(deviceTypeManifest, options, configJson);
62
- answers.version = osVersion;
63
- answers.developmentMode = developmentMode;
64
- answers.secureBoot = secureBoot;
61
+ const _ = await Promise.resolve().then(() => require('lodash'));
62
+ const baseAnswers = configJson == null
63
+ ? await askQuestionsForDeviceType(deviceTypeManifest, options)
64
+ : {
65
+ appUpdatePollInterval: configJson.appUpdatePollInterval,
66
+ network: !configJson.wifiSsid && !configJson.wifiKey ? 'ethernet' : 'wifi',
67
+ ..._.pick(configJson, ['wifiSsid', 'wifiKey']),
68
+ };
69
+ const answers = {
70
+ ...baseAnswers,
71
+ deviceType: deviceTypeSlug,
72
+ version: osVersion,
73
+ developmentMode: developmentMode,
74
+ secureBoot: secureBoot,
75
+ };
65
76
  if (configJson == null) {
66
77
  answers.provisioningKeyName = options['provisioning-key-name'];
67
78
  answers.provisioningKeyExpiryDate =
@@ -70,7 +81,6 @@ class OsConfigureCmd extends core_1.Command {
70
81
  configJson = await generateDeviceConfig(device, undefined, answers);
71
82
  }
72
83
  else {
73
- answers.deviceType = deviceTypeSlug;
74
84
  configJson = await generateApplicationConfig(app, answers);
75
85
  }
76
86
  if (options['initial-device-name'] != null &&
@@ -235,7 +245,7 @@ async function checkDeviceTypeCompatibility(deviceType, app) {
235
245
  }
236
246
  }
237
247
  }
238
- async function askQuestionsForDeviceType(deviceType, options, configJson) {
248
+ async function askQuestionsForDeviceType(deviceType, options) {
239
249
  var _a;
240
250
  const answerSources = [
241
251
  {
@@ -247,9 +257,6 @@ async function askQuestionsForDeviceType(deviceType, options, configJson) {
247
257
  const defaultAnswers = {};
248
258
  const questions = (_a = deviceType.options) !== null && _a !== void 0 ? _a : [];
249
259
  let extraOpts;
250
- if (configJson != null) {
251
- answerSources.push(configJson);
252
- }
253
260
  if (!options.advanced) {
254
261
  const advancedGroup = questions.find((question) => question.name === 'advanced' && question.isGroup);
255
262
  if (advancedGroup != null && Object.keys(advancedGroup).length > 0) {
@@ -1 +1 @@
1
- {"version":3,"file":"configure.js","sourceRoot":"","sources":["../../../src/commands/os/configure.ts"],"names":[],"mappings":";;AAiBA,sCAAmD;AAGnD,yCAA6C;AAC7C,+CAA+C;AAC/C,2CAAyE;AACzE,mDAI8B;AAG9B,MAAM,kBAAkB,GAAG,qBAAqB,CAAC;AAkBjD,MAAqB,cAAe,SAAQ,cAAO;IAsH3C,KAAK,CAAC,GAAG;;QACf,MAAM,EAAE,I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+47,6 @@ function populateDeviceConfig(config, device, deviceApiKey) {
47
47
  config.uuid = device.uuid;
48
48
  }
49
49
  async function readAndValidateConfigJson(path) {
50
- var _a;
51
50
  const fs = await Promise.resolve().then(() => require('fs/promises'));
52
51
  const [rawConfig, { ExpectedError }] = await Promise.all([
53
52
  fs.readFile(path, 'utf8'),
@@ -64,10 +63,6 @@ async function readAndValidateConfigJson(path) {
64
63
  configJson.deviceType === '') {
65
64
  throw new ExpectedError('Missing or invalid deviceType in config.json');
66
65
  }
67
- const secureboot = (_a = configJson.installer) === null || _a === void 0 ? void 0 : _a.secureboot;
68
- if (secureboot != null && typeof secureboot !== 'boolean') {
69
- throw new ExpectedError(`Invalid installer.secureboot in config.json: value must be a boolean, found ${typeof secureboot}: '${secureboot}'`);
70
- }
71
66
  return configJson;
72
67
  }
73
68
  async function validateDevOptionAndWarn(dev, version, logger) {
@@ -1 +1 @@
1
- {"version":3,"file":"config.js","sourceRoot":"","sources":["../../src/utils/config.ts"],"names":[],"mappings":";;AA4DA,8DAuCC;AAED,oDA4BC;AAED,oDAgBC;AAED,8DA0BC;AAQD,4DAuBC;AAQD,0EA2CC;AAjPD,iCAAmD;AA4C5C,KAAK,UAAU,yBAAyB,CAC9C,WAAwD,EACxD,OAQC;;IAED,OAAO,GAAG;QACT,GAAG,OAAO;QAEV,qBAAqB,EAAE,OAAO,CAAC,qBAAqB,IAAI,EAAE;KAC1D,CAAC;IAEF,MAAM,MAAM,GAAG,CAAC,MAAM,IAAA,mBAAY,GAAE,CAAC,MAAM,CAAC,EAAE,CAAC,SAAS,CACvD,WAAW,CAAC,IAAI,EAChB,OAAO,CACP,CAAc,CAAC;IAGhB,IAAI,MAAA,OAAO,CAAC,EAAE,0CAAE,OAAO,EAAE,CAAC;QAEzB,MAAA,MAAM,CAAC,EAAE,oCAAT,MAAM,CAAC,EAAE,GAAK,EAAE,EAAC;QACjB,MAAM,CAAC,EAAE,CAAC,OAAO,GAAG,MAAM,CAAC,EAAE,CAAC,O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BAAgB,IAAI,EAAE,CAAC,CAAC;IACrE,CAAC;IAED,MAAM,QAAQ,GAAG,SAAS,CAAC,QAAqC,CAAC;IACjE,IACC,MAAA,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,QAAQ,0CAAE,IAAI,CAAC,CAAC,KAAK,EAAE,EAAE;QAClC,OAAO,KAAK,CAAC,IAAI,KAAK,YAAY,IAAI,KAAK,CAAC,IAAI,KAAK,YAAY,CAAC;IACnE,CAAC,CAAC,EACD,CAAC;QACF,IAAI,CAAC,MAAM,EAAE,CAAC;YACb,MAAM,MAAM,GAAG,2CAAa,UAAU,EAAC,CAAC;YACxC,MAAM,GAAG,MAAM,CAAC,SAAS,EAAE,CAAC;QAC7B,CAAC;QACD,MAAM,CAAC,OAAO,CAAC,IAAA,kBAAW,EAAA;;8CAEkB,CAAC,CAAC;IAC/C,CAAC;SAAM,CAAC;QACP,MAAM,IAAI,aAAa,CACtB,yDAAyD,IAAI,OAAO,OAAO,EAAE,CAC7E,CAAC;IACH,CAAC;AACF,CAAC"}
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "balena-cli",
3
- "version": "23.2.7-build-validate-installer-secureboot-b46212b61823e87ee7a7b1931c4bbc435a40ba2e-1",
3
+ "version": "23.2.8-build-renovate-apple-actions-import-codesign-certs-4-x-0c66c774af30a7e13043e4daae9146e9a72a1865-1",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "balena-cli",
9
- "version": "23.2.7-build-validate-installer-secureboot-b46212b61823e87ee7a7b1931c4bbc435a40ba2e-1",
9
+ "version": "23.2.8-build-renovate-apple-actions-import-codesign-certs-4-x-0c66c774af30a7e13043e4daae9146e9a72a1865-1",
10
10
  "hasInstallScript": true,
11
11
  "license": "Apache-2.0",
12
12
  "dependencies": {
@@ -3258,6 +3258,301 @@
3258
3258
  "list.js"
3259
3259
  ]
3260
3260
  },
3261
+ "preload": {
3262
+ "aliases": [],
3263
+ "args": {
3264
+ "image": {
3265
+ "description": "the image file path",
3266
+ "name": "image",
3267
+ "required": true
3268
+ }
3269
+ },
3270
+ "description": "Preload a release on a disk image (or Edison zip archive).\n\nPreload a release (service images/containers) from a balena fleet, and optionally\na balenaOS splash screen, in a previously downloaded '.img' balenaOS image file\nin the local disk (a zip file is only accepted for the Intel Edison device type).\nAfter preloading, the balenaOS image file can be flashed to a device's SD card.\nWhen the device boots, it will not need to download the release, as it was\npreloaded. This is usually combined with release pinning\n(https://www.balena.io/docs/learn/deploy/release-strategy/release-policy/)\nto avoid the device downloading a newer release straight away, if available.\nCheck also the Preloading and Preregistering section of the balena CLI's advanced\nmasterclass document:\nhttps://www.balena.io/docs/learn/more/masterclasses/advanced-cli/#5-preloading-and-preregistering\n\nFleets may be specified by fleet name or slug. Fleet slugs are\nthe recommended option, as they are unique and unambiguous. Slugs can be\nlisted with the `balena fleet list` command. Note that slugs may change if the\nfleet is renamed. Fleet names are not unique and may result in \"Fleet is\nambiguous\" errors at any time (even if it \"used to work in the past\"), for\nexample if the name clashes with a newly created public fleet, or with fleets\nfrom other balena accounts that you may be invited to join under any role.\nFor this reason, fleet names are especially discouraged in scripts (e.g. CI\nenvironments).\n\nNote that the this command requires Docker to be installed, as further detailed\nin the balena CLI's installation instructions:\nhttps://github.com/balena-io/balena-cli/blob/master/INSTALL.md\nThe `--dockerHost` and `--dockerPort` flags allow a remote Docker engine to\nbe used, however the image file must be accessible to the remote Docker engine\non the same path given on the command line. This is because Docker's bind mount\nfeature is used to \"share\" the image with a container that performs the preload.",
3271
+ "examples": [
3272
+ "$ balena preload balena.img --fleet MyFleet --commit e1f2592fc6ee949e68756d4f4a48e49bff8d72a0",
3273
+ "$ balena preload balena.img --fleet myorg/myfleet --splash-image image.png",
3274
+ "$ balena preload balena.img"
3275
+ ],
3276
+ "flags": {
3277
+ "fleet": {
3278
+ "char": "f",
3279
+ "description": "fleet name or slug (preferred)",
3280
+ "name": "fleet",
3281
+ "hasDynamicHelp": false,
3282
+ "multiple": false,
3283
+ "type": "option"
3284
+ },
3285
+ "commit": {
3286
+ "char": "c",
3287
+ "description": "The commit hash of the release to preload. Use \"current\" to specify the current\nrelease (ignored if no appId is given). The current release is usually also the\nlatest, but can be pinned to a specific release. See:\nhttps://www.balena.io/docs/learn/deploy/release-strategy/release-policy/\nhttps://www.balena.io/docs/learn/more/masterclasses/fleet-management/#63-pin-using-the-api\nhttps://github.com/balena-io-examples/staged-releases",
3288
+ "name": "commit",
3289
+ "hasDynamicHelp": false,
3290
+ "multiple": false,
3291
+ "type": "option"
3292
+ },
3293
+ "splash-image": {
3294
+ "char": "s",
3295
+ "description": "path to a png image to replace the splash screen",
3296
+ "name": "splash-image",
3297
+ "hasDynamicHelp": false,
3298
+ "multiple": false,
3299
+ "type": "option"
3300
+ },
3301
+ "dont-check-arch": {
3302
+ "description": "disable architecture compatibility check between image and fleet",
3303
+ "name": "dont-check-arch",
3304
+ "allowNo": false,
3305
+ "type": "boolean"
3306
+ },
3307
+ "pin-device-to-release": {
3308
+ "char": "p",
3309
+ "description": "pin the preloaded device to the preloaded release on provision",
3310
+ "name": "pin-device-to-release",
3311
+ "allowNo": true,
3312
+ "type": "boolean"
3313
+ },
3314
+ "additional-space": {
3315
+ "description": "expand the image by this amount of bytes instead of automatically estimating the required amount",
3316
+ "name": "additional-space",
3317
+ "hasDynamicHelp": false,
3318
+ "multiple": false,
3319
+ "type": "option"
3320
+ },
3321
+ "add-certificate": {
3322
+ "description": "Add the given certificate (in PEM format) to /etc/ssl/certs in the preloading container.\nThe file name must end with '.crt' and must not be already contained in the preloader's\n/etc/ssl/certs folder.\nCan be repeated to add multiple certificates.",
3323
+ "name": "add-certificate",
3324
+ "hasDynamicHelp": false,
3325
+ "multiple": true,
3326
+ "type": "option"
3327
+ },
3328
+ "docker": {
3329
+ "char": "P",
3330
+ "description": "Path to a local docker socket (e.g. /var/run/docker.sock)",
3331
+ "name": "docker",
3332
+ "hasDynamicHelp": false,
3333
+ "multiple": false,
3334
+ "type": "option"
3335
+ },
3336
+ "dockerHost": {
3337
+ "char": "h",
3338
+ "description": "Docker daemon hostname or IP address (dev machine or balena device) ",
3339
+ "name": "dockerHost",
3340
+ "hasDynamicHelp": false,
3341
+ "multiple": false,
3342
+ "type": "option"
3343
+ },
3344
+ "dockerPort": {
3345
+ "description": "Docker daemon TCP port number (hint: 2375 for balena devices)",
3346
+ "name": "dockerPort",
3347
+ "hasDynamicHelp": false,
3348
+ "multiple": false,
3349
+ "type": "option"
3350
+ },
3351
+ "ca": {
3352
+ "description": "Docker host TLS certificate authority file",
3353
+ "name": "ca",
3354
+ "hasDynamicHelp": false,
3355
+ "multiple": false,
3356
+ "type": "option"
3357
+ },
3358
+ "cert": {
3359
+ "description": "Docker host TLS certificate file",
3360
+ "name": "cert",
3361
+ "hasDynamicHelp": false,
3362
+ "multiple": false,
3363
+ "type": "option"
3364
+ },
3365
+ "key": {
3366
+ "description": "Docker host TLS key file",
3367
+ "name": "key",
3368
+ "hasDynamicHelp": false,
3369
+ "multiple": false,
3370
+ "type": "option"
3371
+ }
3372
+ },
3373
+ "hasDynamicHelp": false,
3374
+ "hiddenAliases": [],
3375
+ "id": "preload",
3376
+ "pluginAlias": "balena-cli",
3377
+ "pluginName": "balena-cli",
3378
+ "pluginType": "core",
3379
+ "strict": true,
3380
+ "enableJsonFlag": false,
3381
+ "authenticated": true,
3382
+ "primary": true,
3383
+ "isESM": false,
3384
+ "relativePath": [
3385
+ "build",
3386
+ "commands",
3387
+ "preload",
3388
+ "index.js"
3389
+ ]
3390
+ },
3391
+ "push": {
3392
+ "aliases": [],
3393
+ "args": {
3394
+ "fleetOrDevice": {
3395
+ "description": "fleet name or slug, or local device IP address or \".local\" hostname",
3396
+ "name": "fleetOrDevice",
3397
+ "required": true
3398
+ }
3399
+ },
3400
+ "description": "Build release images on balenaCloud servers or on a local mode device.\n\nBuild release images on balenaCloud servers or on a local mode device.\n\nWhen building on the balenaCloud servers, the given source directory will be\nsent to the remote server. This can be used as a drop-in replacement for the\n\"git push\" deployment method.\n\nWhen building on a local mode device, the given source directory will be\nbuilt on the device, and the resulting containers will be run on the device.\nLogs will be streamed back from the device as part of the same invocation.\nThe web dashboard can be used to switch a device to local mode:\nhttps://www.balena.io/docs/learn/develop/local-mode/\nNote that local mode requires a supervisor version of at least v7.21.0.\nThe logs from only a single service can be shown with the --service flag, and\nshowing only the system logs can be achieved with --system. Note that these\nflags can be used together.\n\nWhen pushing to a local device a live session will be started.\nThe project source folder is watched for filesystem events, and changes\nto files and folders are automatically synchronized to the running\ncontainers. The synchronization is only in one direction, from this machine to\nthe device, and changes made on the device itself may be overwritten.\nThis feature requires a device running supervisor version v9.7.0 or greater.\n\nREGISTRY SECRETS \nThe --registry-secrets option specifies a JSON or YAML file containing private\nDocker registry usernames and passwords to be used when pulling base images.\nSample registry-secrets YAML file:\n```\n\t'my-registry-server.com:25000':\n\t\tusername: ann\n\t\tpassword: hunter2\n\t'': # Use the empty string to refer to the Docker Hub\n\t\tusername: mike\n\t\tpassword: cze14\n\t'eu.gcr.io': # Google Container Registry\n\t\tusername: '_json_key'\n\t\tpassword: '{escaped contents of the GCR keyfile.json file}'\n```\nFor a sample project using registry secrets with the Google Container Registry,\ncheck: https://github.com/balena-io-examples/sample-gcr-registry-secrets\n\nIf the --registry-secrets option is not specified, and a secrets.yml or\nsecrets.json file exists in the balena directory (usually $HOME/.balena),\nthis file will be used instead.\n\nDOCKERIGNORE AND GITIGNORE FILES \nBy default, the balena CLI will use a single \".dockerignore\" file (if any) at\nthe project root (--source directory) in order to decide which source files to\nexclude from the \"build context\" (tar stream) sent to balenaCloud, Docker\ndaemon or balenaEngine. In a microservices (multicontainer) fleet, the\nsource directory is the directory that contains the \"docker-compose.yml\" file.\n\nThe --multi-dockerignore (-m) option may be used with microservices\n(multicontainer) fleets that define a docker-compose.yml file. When this\noption is used, each service subdirectory (defined by the `build` or\n`build.context` service properties in the docker-compose.yml file) is\nfiltered separately according to a .dockerignore file defined in the service\nsubdirectory. If no .dockerignore file exists in a service subdirectory, then\nonly the default .dockerignore patterns (see below) apply for that service\nsubdirectory.\n\nWhen the --multi-dockerignore (-m) option is used, the .dockerignore file (if\nany) defined at the overall project root will be used to filter files and\nsubdirectories other than service subdirectories. It will not have any effect\non service subdirectories, whether or not a service subdirectory defines its\nown .dockerignore file. Multiple .dockerignore files are not merged or added\ntogether, and cannot override or extend other files. This behavior maximizes\ncompatibility with the standard docker-compose tool, while still allowing a\nroot .dockerignore file (at the overall project root) to filter files and\nfolders that are outside service subdirectories.\n\nbalena CLI v11 also took .gitignore files into account. This behavior was\ndeprecated in CLI v12 and removed in CLI v13. Please use .dockerignore files\ninstead.\n\nDefault .dockerignore patterns \nA few default/hardcoded dockerignore patterns are \"merged\" (in memory) with the\npatterns found in the applicable .dockerignore files, in the following order:\n```\n **/.git\n < user's patterns from the applicable '.dockerignore' file, if any >\n !**/.balena\n !**/.resin\n !**/Dockerfile\n !**/Dockerfile.*\n !**/docker-compose.yml\n```\nThese patterns always apply, whether or not .dockerignore files exist in the\nproject. If necessary, the effect of the `**/.git` pattern may be modified by\nadding exception patterns to the applicable .dockerignore file(s), for example\n`!mysubmodule/.git`. For documentation on pattern format, see:\n- https://docs.docker.com/engine/reference/builder/#dockerignore-file\n- https://www.npmjs.com/package/@balena/dockerignore\n\nNote: the --service and --env flags must come after the fleetOrDevice\nparameter, as per examples.",
3401
+ "examples": [
3402
+ "$ balena push myFleet",
3403
+ "$ balena push myFleet --source <source directory>",
3404
+ "$ balena push myFleet -s <source directory>",
3405
+ "$ balena push myFleet --source <source directory> --note \"this is the note for this release\"",
3406
+ "$ balena push myFleet --release-tag key1 \"\" key2 \"value2 with spaces\"",
3407
+ "$ balena push myorg/myfleet",
3408
+ "",
3409
+ "$ balena push 10.0.0.1",
3410
+ "$ balena push 10.0.0.1 --source <source directory>",
3411
+ "$ balena push 10.0.0.1 --service my-service",
3412
+ "$ balena push 10.0.0.1 --env MY_ENV_VAR=value --env my-service:SERVICE_VAR=value",
3413
+ "$ balena push 10.0.0.1 --nolive",
3414
+ "",
3415
+ "$ balena push 23c73a1.local --system",
3416
+ "$ balena push 23c73a1.local --system --service my-service"
3417
+ ],
3418
+ "flags": {
3419
+ "source": {
3420
+ "char": "s",
3421
+ "description": "Source directory to be sent to balenaCloud or balenaOS device\n(default: current working dir)",
3422
+ "name": "source",
3423
+ "default": ".",
3424
+ "hasDynamicHelp": false,
3425
+ "multiple": false,
3426
+ "type": "option"
3427
+ },
3428
+ "emulated": {
3429
+ "char": "e",
3430
+ "description": "Don't use the faster, native balenaCloud ARM builders; force slower QEMU ARM\nemulation on Intel x86-64 builders. This flag is sometimes used to investigate\nsuspected issues with the balenaCloud backend.",
3431
+ "name": "emulated",
3432
+ "allowNo": false,
3433
+ "type": "boolean"
3434
+ },
3435
+ "dockerfile": {
3436
+ "description": "Alternative Dockerfile name/path, relative to the source folder",
3437
+ "name": "dockerfile",
3438
+ "hasDynamicHelp": false,
3439
+ "multiple": false,
3440
+ "type": "option"
3441
+ },
3442
+ "nocache": {
3443
+ "char": "c",
3444
+ "description": "Don't use cached layers of previously built images for this project. This\nensures that the latest base image and packages are pulled. Note that build\nlogs may still display the message _\"Pulling previous images for caching\npurposes\" (as the cloud builder needs previous images to compute delta\nupdates), but the logs will not display the \"Using cache\" lines for each\nbuild step of a Dockerfile.",
3445
+ "name": "nocache",
3446
+ "allowNo": false,
3447
+ "type": "boolean"
3448
+ },
3449
+ "pull": {
3450
+ "description": "When pushing to a local device, force the base images to be pulled again.\nCurrently this option is ignored when pushing to the balenaCloud builders.",
3451
+ "name": "pull",
3452
+ "allowNo": false,
3453
+ "type": "boolean"
3454
+ },
3455
+ "noparent-check": {
3456
+ "description": "Disable project validation check of 'docker-compose.yml' file in parent folder",
3457
+ "name": "noparent-check",
3458
+ "allowNo": false,
3459
+ "type": "boolean"
3460
+ },
3461
+ "registry-secrets": {
3462
+ "char": "R",
3463
+ "description": "Path to a local YAML or JSON file containing Docker registry passwords used\nto pull base images. Note that if registry-secrets are not provided on the\ncommand line, a secrets configuration file from the balena directory will be\nused (usually $HOME/.balena/secrets.yml|.json)",
3464
+ "name": "registry-secrets",
3465
+ "hasDynamicHelp": false,
3466
+ "multiple": false,
3467
+ "type": "option"
3468
+ },
3469
+ "nolive": {
3470
+ "description": "Don't run a live session on this push. The filesystem will not be monitored,\nand changes will not be synchronized to any running containers. Note that both\nthis flag and --detached are required to cause the process to end once the\ninitial build has completed.",
3471
+ "name": "nolive",
3472
+ "allowNo": false,
3473
+ "type": "boolean"
3474
+ },
3475
+ "detached": {
3476
+ "char": "d",
3477
+ "description": "When pushing to the cloud, this option will cause the build to start, then\nreturn execution back to the shell, with the status and release ID (if\napplicable). When pushing to a local mode device, this option will cause\nthe command to not tail logs when the build has completed.",
3478
+ "name": "detached",
3479
+ "allowNo": false,
3480
+ "type": "boolean"
3481
+ },
3482
+ "service": {
3483
+ "description": "Reject logs not originating from this service.\nThis can be used in combination with --system and other --service flags.\nOnly valid when pushing to a local mode device.",
3484
+ "name": "service",
3485
+ "hasDynamicHelp": false,
3486
+ "multiple": true,
3487
+ "type": "option"
3488
+ },
3489
+ "system": {
3490
+ "description": "Only show system logs. This can be used in combination with --service.\nOnly valid when pushing to a local mode device.",
3491
+ "name": "system",
3492
+ "allowNo": false,
3493
+ "type": "boolean"
3494
+ },
3495
+ "env": {
3496
+ "description": "When performing a push to device, run the built containers with environment\nvariables provided with this argument. Environment variables can be applied\nto individual services by adding their service name before the argument,\nseparated by a colon, e.g:\n\t--env main:MY_ENV=value\nNote that if the service name cannot be found in the composition, the entire\nleft hand side of the = character will be treated as the variable name.",
3497
+ "name": "env",
3498
+ "hasDynamicHelp": false,
3499
+ "multiple": true,
3500
+ "type": "option"
3501
+ },
3502
+ "noconvert-eol": {
3503
+ "description": "Don't convert line endings from CRLF (Windows format) to LF (Unix format).",
3504
+ "name": "noconvert-eol",
3505
+ "allowNo": false,
3506
+ "type": "boolean"
3507
+ },
3508
+ "multi-dockerignore": {
3509
+ "char": "m",
3510
+ "description": "Have each service use its own .dockerignore file. See \"balena help push\".",
3511
+ "name": "multi-dockerignore",
3512
+ "allowNo": false,
3513
+ "type": "boolean"
3514
+ },
3515
+ "release-tag": {
3516
+ "description": "Set release tags if the image build is successful (balenaCloud only). Multiple\narguments may be provided, alternating tag keys and values (see examples).\nHint: Empty values may be specified with \"\" (bash, cmd.exe) or '\"\"' (PowerShell).",
3517
+ "exclusive": [
3518
+ "detached"
3519
+ ],
3520
+ "name": "release-tag",
3521
+ "hasDynamicHelp": false,
3522
+ "multiple": true,
3523
+ "type": "option"
3524
+ },
3525
+ "draft": {
3526
+ "description": "Instruct the builder to create the release as a draft. Draft releases are ignored\nby the 'track latest' release policy but can be used through release pinning.\nDraft releases can be marked as final through the API. Releases are created\nas final by default unless this option is given.",
3527
+ "name": "draft",
3528
+ "allowNo": false,
3529
+ "type": "boolean"
3530
+ },
3531
+ "note": {
3532
+ "description": "The notes for this release",
3533
+ "name": "note",
3534
+ "hasDynamicHelp": false,
3535
+ "multiple": false,
3536
+ "type": "option"
3537
+ }
3538
+ },
3539
+ "hasDynamicHelp": false,
3540
+ "hiddenAliases": [],
3541
+ "id": "push",
3542
+ "pluginAlias": "balena-cli",
3543
+ "pluginName": "balena-cli",
3544
+ "pluginType": "core",
3545
+ "strict": true,
3546
+ "enableJsonFlag": false,
3547
+ "primary": true,
3548
+ "isESM": false,
3549
+ "relativePath": [
3550
+ "build",
3551
+ "commands",
3552
+ "push",
3553
+ "index.js"
3554
+ ]
3555
+ },
3261
3556
  "os:configure": {
3262
3557
  "aliases": [],
3263
3558
  "args": {
@@ -3460,250 +3755,23 @@
3460
3755
  "$ balena os download raspberrypi3 -o ../foo/bar/raspberry-pi.img --version 2.60.1+rev1.dev",
3461
3756
  "$ balena os download raspberrypi3 -o ../foo/bar/raspberry-pi.img --version 2021.10.2.prod",
3462
3757
  "$ balena os download raspberrypi3 -o ../foo/bar/raspberry-pi.img --version latest",
3463
- "$ balena os download raspberrypi3 -o ../foo/bar/raspberry-pi.img --version default",
3464
- "$ balena os download raspberrypi3 -o ../foo/bar/raspberry-pi.img --version menu",
3465
- "$ balena os download raspberrypi3 -o ../foo/bar/raspberry-pi.img --version menu-esr"
3466
- ],
3467
- "flags": {
3468
- "output": {
3469
- "char": "o",
3470
- "description": "output path",
3471
- "name": "output",
3472
- "required": true,
3473
- "hasDynamicHelp": false,
3474
- "multiple": false,
3475
- "type": "option"
3476
- },
3477
- "version": {
3478
- "description": "version number (ESR or non-ESR versions),\nor semver range (non-ESR versions only),\nor 'latest' (includes pre-releases),\nor 'default' (excludes pre-releases if at least one released version is available),\nor 'recommended' (excludes pre-releases, will fail if only pre-release versions are available),\nor 'menu' (interactive menu, non-ESR versions),\nor 'menu-esr' (interactive menu, ESR versions)",
3479
- "name": "version",
3480
- "hasDynamicHelp": false,
3481
- "multiple": false,
3482
- "type": "option"
3483
- }
3484
- },
3485
- "hasDynamicHelp": false,
3486
- "hiddenAliases": [],
3487
- "id": "os:download",
3488
- "pluginAlias": "balena-cli",
3489
- "pluginName": "balena-cli",
3490
- "pluginType": "core",
3491
- "strict": true,
3492
- "enableJsonFlag": false,
3493
- "isESM": false,
3494
- "relativePath": [
3495
- "build",
3496
- "commands",
3497
- "os",
3498
- "download.js"
3499
- ]
3500
- },
3501
- "os:initialize": {
3502
- "aliases": [],
3503
- "args": {
3504
- "image": {
3505
- "description": "path to OS image",
3506
- "name": "image",
3507
- "required": true
3508
- }
3509
- },
3510
- "description": "Initialize an os image for a device.\n\n\t\tInitialize an os image for a device with a previously\n\t\tconfigured operating system image and flash the\n\t\tan external storage drive or the device's storage\n\t\tmedium depending on the device type.\n\t\t\n\nNote: Initializing the device may ask for administrative permissions\nbecause we need to access the raw devices directly.",
3511
- "examples": [
3512
- "$ balena os initialize ../path/rpi.img --type raspberry-pi"
3513
- ],
3514
- "flags": {
3515
- "type": {
3516
- "char": "t",
3517
- "description": "device type (Check available types with `balena device-type list`)",
3518
- "name": "type",
3519
- "required": true,
3520
- "hasDynamicHelp": false,
3521
- "multiple": false,
3522
- "type": "option"
3523
- },
3524
- "drive": {
3525
- "char": "d",
3526
- "description": "the drive to write the image to, eg. `/dev/sdb` or `/dev/mmcblk0`.\nCareful with this as you can erase your hard drive.\nCheck `balena util available-drives` for available options.",
3527
- "name": "drive",
3528
- "hasDynamicHelp": false,
3529
- "multiple": false,
3530
- "type": "option"
3531
- },
3532
- "yes": {
3533
- "char": "y",
3534
- "description": "answer \"yes\" to all questions (non interactive use)",
3535
- "name": "yes",
3536
- "allowNo": false,
3537
- "type": "boolean"
3538
- }
3539
- },
3540
- "hasDynamicHelp": false,
3541
- "hiddenAliases": [],
3542
- "id": "os:initialize",
3543
- "pluginAlias": "balena-cli",
3544
- "pluginName": "balena-cli",
3545
- "pluginType": "core",
3546
- "strict": true,
3547
- "enableJsonFlag": false,
3548
- "authenticated": true,
3549
- "isESM": false,
3550
- "relativePath": [
3551
- "build",
3552
- "commands",
3553
- "os",
3554
- "initialize.js"
3555
- ]
3556
- },
3557
- "os:versions": {
3558
- "aliases": [],
3559
- "args": {
3560
- "type": {
3561
- "description": "device type",
3562
- "name": "type",
3563
- "required": true
3564
- }
3565
- },
3566
- "description": "Show available balenaOS versions for the given device type.\n\nShow the available balenaOS versions for the given device type.\nCheck available types with `balena device-type list`.\n\nbalenaOS ESR versions can be listed with the '--esr' option. See also:\nhttps://www.balena.io/docs/reference/OS/extended-support-release/",
3567
- "examples": [
3568
- "$ balena os versions raspberrypi3"
3569
- ],
3570
- "flags": {
3571
- "esr": {
3572
- "description": "select balenaOS ESR versions",
3573
- "name": "esr",
3574
- "allowNo": false,
3575
- "type": "boolean"
3576
- },
3577
- "include-draft": {
3578
- "description": "include pre-release balenaOS versions",
3579
- "name": "include-draft",
3580
- "allowNo": false,
3581
- "type": "boolean"
3582
- }
3583
- },
3584
- "hasDynamicHelp": false,
3585
- "hiddenAliases": [],
3586
- "id": "os:versions",
3587
- "pluginAlias": "balena-cli",
3588
- "pluginName": "balena-cli",
3589
- "pluginType": "core",
3590
- "strict": true,
3591
- "enableJsonFlag": false,
3592
- "isESM": false,
3593
- "relativePath": [
3594
- "build",
3595
- "commands",
3596
- "os",
3597
- "versions.js"
3598
- ]
3599
- },
3600
- "preload": {
3601
- "aliases": [],
3602
- "args": {
3603
- "image": {
3604
- "description": "the image file path",
3605
- "name": "image",
3606
- "required": true
3607
- }
3608
- },
3609
- "description": "Preload a release on a disk image (or Edison zip archive).\n\nPreload a release (service images/containers) from a balena fleet, and optionally\na balenaOS splash screen, in a previously downloaded '.img' balenaOS image file\nin the local disk (a zip file is only accepted for the Intel Edison device type).\nAfter preloading, the balenaOS image file can be flashed to a device's SD card.\nWhen the device boots, it will not need to download the release, as it was\npreloaded. This is usually combined with release pinning\n(https://www.balena.io/docs/learn/deploy/release-strategy/release-policy/)\nto avoid the device downloading a newer release straight away, if available.\nCheck also the Preloading and Preregistering section of the balena CLI's advanced\nmasterclass document:\nhttps://www.balena.io/docs/learn/more/masterclasses/advanced-cli/#5-preloading-and-preregistering\n\nFleets may be specified by fleet name or slug. Fleet slugs are\nthe recommended option, as they are unique and unambiguous. Slugs can be\nlisted with the `balena fleet list` command. Note that slugs may change if the\nfleet is renamed. Fleet names are not unique and may result in \"Fleet is\nambiguous\" errors at any time (even if it \"used to work in the past\"), for\nexample if the name clashes with a newly created public fleet, or with fleets\nfrom other balena accounts that you may be invited to join under any role.\nFor this reason, fleet names are especially discouraged in scripts (e.g. CI\nenvironments).\n\nNote that the this command requires Docker to be installed, as further detailed\nin the balena CLI's installation instructions:\nhttps://github.com/balena-io/balena-cli/blob/master/INSTALL.md\nThe `--dockerHost` and `--dockerPort` flags allow a remote Docker engine to\nbe used, however the image file must be accessible to the remote Docker engine\non the same path given on the command line. This is because Docker's bind mount\nfeature is used to \"share\" the image with a container that performs the preload.",
3610
- "examples": [
3611
- "$ balena preload balena.img --fleet MyFleet --commit e1f2592fc6ee949e68756d4f4a48e49bff8d72a0",
3612
- "$ balena preload balena.img --fleet myorg/myfleet --splash-image image.png",
3613
- "$ balena preload balena.img"
3614
- ],
3615
- "flags": {
3616
- "fleet": {
3617
- "char": "f",
3618
- "description": "fleet name or slug (preferred)",
3619
- "name": "fleet",
3620
- "hasDynamicHelp": false,
3621
- "multiple": false,
3622
- "type": "option"
3623
- },
3624
- "commit": {
3625
- "char": "c",
3626
- "description": "The commit hash of the release to preload. Use \"current\" to specify the current\nrelease (ignored if no appId is given). The current release is usually also the\nlatest, but can be pinned to a specific release. See:\nhttps://www.balena.io/docs/learn/deploy/release-strategy/release-policy/\nhttps://www.balena.io/docs/learn/more/masterclasses/fleet-management/#63-pin-using-the-api\nhttps://github.com/balena-io-examples/staged-releases",
3627
- "name": "commit",
3628
- "hasDynamicHelp": false,
3629
- "multiple": false,
3630
- "type": "option"
3631
- },
3632
- "splash-image": {
3633
- "char": "s",
3634
- "description": "path to a png image to replace the splash screen",
3635
- "name": "splash-image",
3636
- "hasDynamicHelp": false,
3637
- "multiple": false,
3638
- "type": "option"
3639
- },
3640
- "dont-check-arch": {
3641
- "description": "disable architecture compatibility check between image and fleet",
3642
- "name": "dont-check-arch",
3643
- "allowNo": false,
3644
- "type": "boolean"
3645
- },
3646
- "pin-device-to-release": {
3647
- "char": "p",
3648
- "description": "pin the preloaded device to the preloaded release on provision",
3649
- "name": "pin-device-to-release",
3650
- "allowNo": true,
3651
- "type": "boolean"
3652
- },
3653
- "additional-space": {
3654
- "description": "expand the image by this amount of bytes instead of automatically estimating the required amount",
3655
- "name": "additional-space",
3656
- "hasDynamicHelp": false,
3657
- "multiple": false,
3658
- "type": "option"
3659
- },
3660
- "add-certificate": {
3661
- "description": "Add the given certificate (in PEM format) to /etc/ssl/certs in the preloading container.\nThe file name must end with '.crt' and must not be already contained in the preloader's\n/etc/ssl/certs folder.\nCan be repeated to add multiple certificates.",
3662
- "name": "add-certificate",
3663
- "hasDynamicHelp": false,
3664
- "multiple": true,
3665
- "type": "option"
3666
- },
3667
- "docker": {
3668
- "char": "P",
3669
- "description": "Path to a local docker socket (e.g. /var/run/docker.sock)",
3670
- "name": "docker",
3671
- "hasDynamicHelp": false,
3672
- "multiple": false,
3673
- "type": "option"
3674
- },
3675
- "dockerHost": {
3676
- "char": "h",
3677
- "description": "Docker daemon hostname or IP address (dev machine or balena device) ",
3678
- "name": "dockerHost",
3679
- "hasDynamicHelp": false,
3680
- "multiple": false,
3681
- "type": "option"
3682
- },
3683
- "dockerPort": {
3684
- "description": "Docker daemon TCP port number (hint: 2375 for balena devices)",
3685
- "name": "dockerPort",
3686
- "hasDynamicHelp": false,
3687
- "multiple": false,
3688
- "type": "option"
3689
- },
3690
- "ca": {
3691
- "description": "Docker host TLS certificate authority file",
3692
- "name": "ca",
3693
- "hasDynamicHelp": false,
3694
- "multiple": false,
3695
- "type": "option"
3696
- },
3697
- "cert": {
3698
- "description": "Docker host TLS certificate file",
3699
- "name": "cert",
3758
+ "$ balena os download raspberrypi3 -o ../foo/bar/raspberry-pi.img --version default",
3759
+ "$ balena os download raspberrypi3 -o ../foo/bar/raspberry-pi.img --version menu",
3760
+ "$ balena os download raspberrypi3 -o ../foo/bar/raspberry-pi.img --version menu-esr"
3761
+ ],
3762
+ "flags": {
3763
+ "output": {
3764
+ "char": "o",
3765
+ "description": "output path",
3766
+ "name": "output",
3767
+ "required": true,
3700
3768
  "hasDynamicHelp": false,
3701
3769
  "multiple": false,
3702
3770
  "type": "option"
3703
3771
  },
3704
- "key": {
3705
- "description": "Docker host TLS key file",
3706
- "name": "key",
3772
+ "version": {
3773
+ "description": "version number (ESR or non-ESR versions),\nor semver range (non-ESR versions only),\nor 'latest' (includes pre-releases),\nor 'default' (excludes pre-releases if at least one released version is available),\nor 'recommended' (excludes pre-releases, will fail if only pre-release versions are available),\nor 'menu' (interactive menu, non-ESR versions),\nor 'menu-esr' (interactive menu, ESR versions)",
3774
+ "name": "version",
3707
3775
  "hasDynamicHelp": false,
3708
3776
  "multiple": false,
3709
3777
  "type": "option"
@@ -3711,185 +3779,117 @@
3711
3779
  },
3712
3780
  "hasDynamicHelp": false,
3713
3781
  "hiddenAliases": [],
3714
- "id": "preload",
3782
+ "id": "os:download",
3715
3783
  "pluginAlias": "balena-cli",
3716
3784
  "pluginName": "balena-cli",
3717
3785
  "pluginType": "core",
3718
3786
  "strict": true,
3719
3787
  "enableJsonFlag": false,
3720
- "authenticated": true,
3721
- "primary": true,
3722
3788
  "isESM": false,
3723
3789
  "relativePath": [
3724
3790
  "build",
3725
3791
  "commands",
3726
- "preload",
3727
- "index.js"
3792
+ "os",
3793
+ "download.js"
3728
3794
  ]
3729
3795
  },
3730
- "push": {
3796
+ "os:initialize": {
3731
3797
  "aliases": [],
3732
3798
  "args": {
3733
- "fleetOrDevice": {
3734
- "description": "fleet name or slug, or local device IP address or \".local\" hostname",
3735
- "name": "fleetOrDevice",
3799
+ "image": {
3800
+ "description": "path to OS image",
3801
+ "name": "image",
3736
3802
  "required": true
3737
3803
  }
3738
3804
  },
3739
- "description": "Build release images on balenaCloud servers or on a local mode device.\n\nBuild release images on balenaCloud servers or on a local mode device.\n\nWhen building on the balenaCloud servers, the given source directory will be\nsent to the remote server. This can be used as a drop-in replacement for the\n\"git push\" deployment method.\n\nWhen building on a local mode device, the given source directory will be\nbuilt on the device, and the resulting containers will be run on the device.\nLogs will be streamed back from the device as part of the same invocation.\nThe web dashboard can be used to switch a device to local mode:\nhttps://www.balena.io/docs/learn/develop/local-mode/\nNote that local mode requires a supervisor version of at least v7.21.0.\nThe logs from only a single service can be shown with the --service flag, and\nshowing only the system logs can be achieved with --system. Note that these\nflags can be used together.\n\nWhen pushing to a local device a live session will be started.\nThe project source folder is watched for filesystem events, and changes\nto files and folders are automatically synchronized to the running\ncontainers. The synchronization is only in one direction, from this machine to\nthe device, and changes made on the device itself may be overwritten.\nThis feature requires a device running supervisor version v9.7.0 or greater.\n\nREGISTRY SECRETS \nThe --registry-secrets option specifies a JSON or YAML file containing private\nDocker registry usernames and passwords to be used when pulling base images.\nSample registry-secrets YAML file:\n```\n\t'my-registry-server.com:25000':\n\t\tusername: ann\n\t\tpassword: hunter2\n\t'': # Use the empty string to refer to the Docker Hub\n\t\tusername: mike\n\t\tpassword: cze14\n\t'eu.gcr.io': # Google Container Registry\n\t\tusername: '_json_key'\n\t\tpassword: '{escaped contents of the GCR keyfile.json file}'\n```\nFor a sample project using registry secrets with the Google Container Registry,\ncheck: https://github.com/balena-io-examples/sample-gcr-registry-secrets\n\nIf the --registry-secrets option is not specified, and a secrets.yml or\nsecrets.json file exists in the balena directory (usually $HOME/.balena),\nthis file will be used instead.\n\nDOCKERIGNORE AND GITIGNORE FILES \nBy default, the balena CLI will use a single \".dockerignore\" file (if any) at\nthe project root (--source directory) in order to decide which source files to\nexclude from the \"build context\" (tar stream) sent to balenaCloud, Docker\ndaemon or balenaEngine. In a microservices (multicontainer) fleet, the\nsource directory is the directory that contains the \"docker-compose.yml\" file.\n\nThe --multi-dockerignore (-m) option may be used with microservices\n(multicontainer) fleets that define a docker-compose.yml file. When this\noption is used, each service subdirectory (defined by the `build` or\n`build.context` service properties in the docker-compose.yml file) is\nfiltered separately according to a .dockerignore file defined in the service\nsubdirectory. If no .dockerignore file exists in a service subdirectory, then\nonly the default .dockerignore patterns (see below) apply for that service\nsubdirectory.\n\nWhen the --multi-dockerignore (-m) option is used, the .dockerignore file (if\nany) defined at the overall project root will be used to filter files and\nsubdirectories other than service subdirectories. It will not have any effect\non service subdirectories, whether or not a service subdirectory defines its\nown .dockerignore file. Multiple .dockerignore files are not merged or added\ntogether, and cannot override or extend other files. This behavior maximizes\ncompatibility with the standard docker-compose tool, while still allowing a\nroot .dockerignore file (at the overall project root) to filter files and\nfolders that are outside service subdirectories.\n\nbalena CLI v11 also took .gitignore files into account. This behavior was\ndeprecated in CLI v12 and removed in CLI v13. Please use .dockerignore files\ninstead.\n\nDefault .dockerignore patterns \nA few default/hardcoded dockerignore patterns are \"merged\" (in memory) with the\npatterns found in the applicable .dockerignore files, in the following order:\n```\n **/.git\n < user's patterns from the applicable '.dockerignore' file, if any >\n !**/.balena\n !**/.resin\n !**/Dockerfile\n !**/Dockerfile.*\n !**/docker-compose.yml\n```\nThese patterns always apply, whether or not .dockerignore files exist in the\nproject. If necessary, the effect of the `**/.git` pattern may be modified by\nadding exception patterns to the applicable .dockerignore file(s), for example\n`!mysubmodule/.git`. For documentation on pattern format, see:\n- https://docs.docker.com/engine/reference/builder/#dockerignore-file\n- https://www.npmjs.com/package/@balena/dockerignore\n\nNote: the --service and --env flags must come after the fleetOrDevice\nparameter, as per examples.",
3805
+ "description": "Initialize an os image for a device.\n\n\t\tInitialize an os image for a device with a previously\n\t\tconfigured operating system image and flash the\n\t\tan external storage drive or the device's storage\n\t\tmedium depending on the device type.\n\t\t\n\nNote: Initializing the device may ask for administrative permissions\nbecause we need to access the raw devices directly.",
3740
3806
  "examples": [
3741
- "$ balena push myFleet",
3742
- "$ balena push myFleet --source <source directory>",
3743
- "$ balena push myFleet -s <source directory>",
3744
- "$ balena push myFleet --source <source directory> --note \"this is the note for this release\"",
3745
- "$ balena push myFleet --release-tag key1 \"\" key2 \"value2 with spaces\"",
3746
- "$ balena push myorg/myfleet",
3747
- "",
3748
- "$ balena push 10.0.0.1",
3749
- "$ balena push 10.0.0.1 --source <source directory>",
3750
- "$ balena push 10.0.0.1 --service my-service",
3751
- "$ balena push 10.0.0.1 --env MY_ENV_VAR=value --env my-service:SERVICE_VAR=value",
3752
- "$ balena push 10.0.0.1 --nolive",
3753
- "",
3754
- "$ balena push 23c73a1.local --system",
3755
- "$ balena push 23c73a1.local --system --service my-service"
3807
+ "$ balena os initialize ../path/rpi.img --type raspberry-pi"
3756
3808
  ],
3757
3809
  "flags": {
3758
- "source": {
3759
- "char": "s",
3760
- "description": "Source directory to be sent to balenaCloud or balenaOS device\n(default: current working dir)",
3761
- "name": "source",
3762
- "default": ".",
3763
- "hasDynamicHelp": false,
3764
- "multiple": false,
3765
- "type": "option"
3766
- },
3767
- "emulated": {
3768
- "char": "e",
3769
- "description": "Don't use the faster, native balenaCloud ARM builders; force slower QEMU ARM\nemulation on Intel x86-64 builders. This flag is sometimes used to investigate\nsuspected issues with the balenaCloud backend.",
3770
- "name": "emulated",
3771
- "allowNo": false,
3772
- "type": "boolean"
3773
- },
3774
- "dockerfile": {
3775
- "description": "Alternative Dockerfile name/path, relative to the source folder",
3776
- "name": "dockerfile",
3777
- "hasDynamicHelp": false,
3778
- "multiple": false,
3779
- "type": "option"
3780
- },
3781
- "nocache": {
3782
- "char": "c",
3783
- "description": "Don't use cached layers of previously built images for this project. This\nensures that the latest base image and packages are pulled. Note that build\nlogs may still display the message _\"Pulling previous images for caching\npurposes\" (as the cloud builder needs previous images to compute delta\nupdates), but the logs will not display the \"Using cache\" lines for each\nbuild step of a Dockerfile.",
3784
- "name": "nocache",
3785
- "allowNo": false,
3786
- "type": "boolean"
3787
- },
3788
- "pull": {
3789
- "description": "When pushing to a local device, force the base images to be pulled again.\nCurrently this option is ignored when pushing to the balenaCloud builders.",
3790
- "name": "pull",
3791
- "allowNo": false,
3792
- "type": "boolean"
3793
- },
3794
- "noparent-check": {
3795
- "description": "Disable project validation check of 'docker-compose.yml' file in parent folder",
3796
- "name": "noparent-check",
3797
- "allowNo": false,
3798
- "type": "boolean"
3799
- },
3800
- "registry-secrets": {
3801
- "char": "R",
3802
- "description": "Path to a local YAML or JSON file containing Docker registry passwords used\nto pull base images. Note that if registry-secrets are not provided on the\ncommand line, a secrets configuration file from the balena directory will be\nused (usually $HOME/.balena/secrets.yml|.json)",
3803
- "name": "registry-secrets",
3810
+ "type": {
3811
+ "char": "t",
3812
+ "description": "device type (Check available types with `balena device-type list`)",
3813
+ "name": "type",
3814
+ "required": true,
3804
3815
  "hasDynamicHelp": false,
3805
3816
  "multiple": false,
3806
3817
  "type": "option"
3807
3818
  },
3808
- "nolive": {
3809
- "description": "Don't run a live session on this push. The filesystem will not be monitored,\nand changes will not be synchronized to any running containers. Note that both\nthis flag and --detached are required to cause the process to end once the\ninitial build has completed.",
3810
- "name": "nolive",
3811
- "allowNo": false,
3812
- "type": "boolean"
3813
- },
3814
- "detached": {
3819
+ "drive": {
3815
3820
  "char": "d",
3816
- "description": "When pushing to the cloud, this option will cause the build to start, then\nreturn execution back to the shell, with the status and release ID (if\napplicable). When pushing to a local mode device, this option will cause\nthe command to not tail logs when the build has completed.",
3817
- "name": "detached",
3818
- "allowNo": false,
3819
- "type": "boolean"
3820
- },
3821
- "service": {
3822
- "description": "Reject logs not originating from this service.\nThis can be used in combination with --system and other --service flags.\nOnly valid when pushing to a local mode device.",
3823
- "name": "service",
3824
- "hasDynamicHelp": false,
3825
- "multiple": true,
3826
- "type": "option"
3827
- },
3828
- "system": {
3829
- "description": "Only show system logs. This can be used in combination with --service.\nOnly valid when pushing to a local mode device.",
3830
- "name": "system",
3831
- "allowNo": false,
3832
- "type": "boolean"
3833
- },
3834
- "env": {
3835
- "description": "When performing a push to device, run the built containers with environment\nvariables provided with this argument. Environment variables can be applied\nto individual services by adding their service name before the argument,\nseparated by a colon, e.g:\n\t--env main:MY_ENV=value\nNote that if the service name cannot be found in the composition, the entire\nleft hand side of the = character will be treated as the variable name.",
3836
- "name": "env",
3821
+ "description": "the drive to write the image to, eg. `/dev/sdb` or `/dev/mmcblk0`.\nCareful with this as you can erase your hard drive.\nCheck `balena util available-drives` for available options.",
3822
+ "name": "drive",
3837
3823
  "hasDynamicHelp": false,
3838
- "multiple": true,
3824
+ "multiple": false,
3839
3825
  "type": "option"
3840
3826
  },
3841
- "noconvert-eol": {
3842
- "description": "Don't convert line endings from CRLF (Windows format) to LF (Unix format).",
3843
- "name": "noconvert-eol",
3827
+ "yes": {
3828
+ "char": "y",
3829
+ "description": "answer \"yes\" to all questions (non interactive use)",
3830
+ "name": "yes",
3844
3831
  "allowNo": false,
3845
3832
  "type": "boolean"
3846
- },
3847
- "multi-dockerignore": {
3848
- "char": "m",
3849
- "description": "Have each service use its own .dockerignore file. See \"balena help push\".",
3850
- "name": "multi-dockerignore",
3833
+ }
3834
+ },
3835
+ "hasDynamicHelp": false,
3836
+ "hiddenAliases": [],
3837
+ "id": "os:initialize",
3838
+ "pluginAlias": "balena-cli",
3839
+ "pluginName": "balena-cli",
3840
+ "pluginType": "core",
3841
+ "strict": true,
3842
+ "enableJsonFlag": false,
3843
+ "authenticated": true,
3844
+ "isESM": false,
3845
+ "relativePath": [
3846
+ "build",
3847
+ "commands",
3848
+ "os",
3849
+ "initialize.js"
3850
+ ]
3851
+ },
3852
+ "os:versions": {
3853
+ "aliases": [],
3854
+ "args": {
3855
+ "type": {
3856
+ "description": "device type",
3857
+ "name": "type",
3858
+ "required": true
3859
+ }
3860
+ },
3861
+ "description": "Show available balenaOS versions for the given device type.\n\nShow the available balenaOS versions for the given device type.\nCheck available types with `balena device-type list`.\n\nbalenaOS ESR versions can be listed with the '--esr' option. See also:\nhttps://www.balena.io/docs/reference/OS/extended-support-release/",
3862
+ "examples": [
3863
+ "$ balena os versions raspberrypi3"
3864
+ ],
3865
+ "flags": {
3866
+ "esr": {
3867
+ "description": "select balenaOS ESR versions",
3868
+ "name": "esr",
3851
3869
  "allowNo": false,
3852
3870
  "type": "boolean"
3853
3871
  },
3854
- "release-tag": {
3855
- "description": "Set release tags if the image build is successful (balenaCloud only). Multiple\narguments may be provided, alternating tag keys and values (see examples).\nHint: Empty values may be specified with \"\" (bash, cmd.exe) or '\"\"' (PowerShell).",
3856
- "exclusive": [
3857
- "detached"
3858
- ],
3859
- "name": "release-tag",
3860
- "hasDynamicHelp": false,
3861
- "multiple": true,
3862
- "type": "option"
3863
- },
3864
- "draft": {
3865
- "description": "Instruct the builder to create the release as a draft. Draft releases are ignored\nby the 'track latest' release policy but can be used through release pinning.\nDraft releases can be marked as final through the API. Releases are created\nas final by default unless this option is given.",
3866
- "name": "draft",
3872
+ "include-draft": {
3873
+ "description": "include pre-release balenaOS versions",
3874
+ "name": "include-draft",
3867
3875
  "allowNo": false,
3868
3876
  "type": "boolean"
3869
- },
3870
- "note": {
3871
- "description": "The notes for this release",
3872
- "name": "note",
3873
- "hasDynamicHelp": false,
3874
- "multiple": false,
3875
- "type": "option"
3876
3877
  }
3877
3878
  },
3878
3879
  "hasDynamicHelp": false,
3879
3880
  "hiddenAliases": [],
3880
- "id": "push",
3881
+ "id": "os:versions",
3881
3882
  "pluginAlias": "balena-cli",
3882
3883
  "pluginName": "balena-cli",
3883
3884
  "pluginType": "core",
3884
3885
  "strict": true,
3885
3886
  "enableJsonFlag": false,
3886
- "primary": true,
3887
3887
  "isESM": false,
3888
3888
  "relativePath": [
3889
3889
  "build",
3890
3890
  "commands",
3891
- "push",
3892
- "index.js"
3891
+ "os",
3892
+ "versions.js"
3893
3893
  ]
3894
3894
  },
3895
3895
  "release:finalize": {
@@ -4509,6 +4509,28 @@
4509
4509
  "index.js"
4510
4510
  ]
4511
4511
  },
4512
+ "util:available-drives": {
4513
+ "aliases": [],
4514
+ "args": {},
4515
+ "description": "List available drives.\n\nList available drives which are usable for writing an OS image to.\nDoes not list system drives.",
4516
+ "flags": {},
4517
+ "hasDynamicHelp": false,
4518
+ "hiddenAliases": [],
4519
+ "id": "util:available-drives",
4520
+ "pluginAlias": "balena-cli",
4521
+ "pluginName": "balena-cli",
4522
+ "pluginType": "core",
4523
+ "strict": true,
4524
+ "enableJsonFlag": false,
4525
+ "offlineCompatible": true,
4526
+ "isESM": false,
4527
+ "relativePath": [
4528
+ "build",
4529
+ "commands",
4530
+ "util",
4531
+ "available-drives.js"
4532
+ ]
4533
+ },
4512
4534
  "tag:list": {
4513
4535
  "aliases": [],
4514
4536
  "args": {},
@@ -4729,28 +4751,6 @@
4729
4751
  "set.js"
4730
4752
  ]
4731
4753
  },
4732
- "util:available-drives": {
4733
- "aliases": [],
4734
- "args": {},
4735
- "description": "List available drives.\n\nList available drives which are usable for writing an OS image to.\nDoes not list system drives.",
4736
- "flags": {},
4737
- "hasDynamicHelp": false,
4738
- "hiddenAliases": [],
4739
- "id": "util:available-drives",
4740
- "pluginAlias": "balena-cli",
4741
- "pluginName": "balena-cli",
4742
- "pluginType": "core",
4743
- "strict": true,
4744
- "enableJsonFlag": false,
4745
- "offlineCompatible": true,
4746
- "isESM": false,
4747
- "relativePath": [
4748
- "build",
4749
- "commands",
4750
- "util",
4751
- "available-drives.js"
4752
- ]
4753
- },
4754
4754
  "whoami": {
4755
4755
  "aliases": [],
4756
4756
  "args": {},
@@ -4777,5 +4777,5 @@
4777
4777
  ]
4778
4778
  }
4779
4779
  },
4780
- "version": "23.2.7"
4780
+ "version": "23.2.8"
4781
4781
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "balena-cli",
3
- "version": "23.2.7-build-validate-installer-secureboot-b46212b61823e87ee7a7b1931c4bbc435a40ba2e-1",
3
+ "version": "23.2.8-build-renovate-apple-actions-import-codesign-certs-4-x-0c66c774af30a7e13043e4daae9146e9a72a1865-1",
4
4
  "description": "The official balena Command Line Interface",
5
5
  "main": "./build/app.js",
6
6
  "homepage": "https://github.com/balena-io/balena-cli",
@@ -262,6 +262,6 @@
262
262
  "balena-request": "14.0.6"
263
263
  },
264
264
  "versionist": {
265
- "publishedAt": "2025-12-06T21:44:16.004Z"
265
+ "publishedAt": "2025-12-08T17:56:48.253Z"
266
266
  }
267
267
  }
@@ -35,13 +35,16 @@ type FlagsDef = Interfaces.InferredFlags<typeof OsConfigureCmd.flags>;
35
35
 
36
36
  interface Answers {
37
37
  appUpdatePollInterval: number; // in minutes
38
+ network: 'ethernet' | 'wifi';
39
+ wifiSsid?: string;
40
+ wifiKey?: string;
41
+ }
42
+
43
+ interface AugmentedAnswers extends Answers {
38
44
  developmentMode?: boolean; // balenaOS development variant
39
45
  secureBoot?: boolean;
40
46
  deviceType: string; // e.g. "raspberrypi3"
41
- network: 'ethernet' | 'wifi';
42
47
  version: string; // e.g. "2.32.0+rev1"
43
- wifiSsid?: string;
44
- wifiKey?: string;
45
48
  provisioningKeyName?: string;
46
49
  provisioningKeyExpiryDate?: string;
47
50
  }
@@ -243,14 +246,23 @@ export default class OsConfigureCmd extends Command {
243
246
  osVersion,
244
247
  );
245
248
 
246
- const answers: Answers = await askQuestionsForDeviceType(
247
- deviceTypeManifest,
248
- options,
249
- configJson,
250
- );
251
- answers.version = osVersion;
252
- answers.developmentMode = developmentMode;
253
- answers.secureBoot = secureBoot;
249
+ const _ = await import('lodash');
250
+ const baseAnswers: Answers =
251
+ configJson == null
252
+ ? await askQuestionsForDeviceType(deviceTypeManifest, options)
253
+ : {
254
+ appUpdatePollInterval: configJson.appUpdatePollInterval,
255
+ network:
256
+ !configJson.wifiSsid && !configJson.wifiKey ? 'ethernet' : 'wifi',
257
+ ..._.pick(configJson, ['wifiSsid', 'wifiKey']),
258
+ };
259
+ const answers: AugmentedAnswers = {
260
+ ...baseAnswers,
261
+ deviceType: deviceTypeSlug,
262
+ version: osVersion,
263
+ developmentMode: developmentMode,
264
+ secureBoot: secureBoot,
265
+ };
254
266
 
255
267
  if (configJson == null) {
256
268
  answers.provisioningKeyName = options['provisioning-key-name'];
@@ -259,7 +271,6 @@ export default class OsConfigureCmd extends Command {
259
271
  if (device != null) {
260
272
  configJson = await generateDeviceConfig(device, undefined, answers);
261
273
  } else {
262
- answers.deviceType = deviceTypeSlug;
263
274
  configJson = await generateApplicationConfig(app!, answers);
264
275
  }
265
276
  if (
@@ -401,7 +412,6 @@ async function checkDeviceTypeCompatibility(
401
412
  async function askQuestionsForDeviceType(
402
413
  deviceType: BalenaSdk.DeviceTypeJson.DeviceType,
403
414
  options: FlagsDef,
404
- configJson: import('../../utils/config').ImgConfig | undefined,
405
415
  ): Promise<Answers> {
406
416
  const answerSources: any[] = [
407
417
  {
@@ -414,10 +424,6 @@ async function askQuestionsForDeviceType(
414
424
  const questions = deviceType.options ?? [];
415
425
  let extraOpts: { override: Partial<Answers> } | undefined;
416
426
 
417
- if (configJson != null) {
418
- answerSources.push(configJson);
419
- }
420
-
421
427
  if (!options.advanced) {
422
428
  const advancedGroup = questions.find(
423
429
  (question) => question.name === 'advanced' && question.isGroup,
@@ -166,12 +166,6 @@ export async function readAndValidateConfigJson(path: string) {
166
166
  ) {
167
167
  throw new ExpectedError('Missing or invalid deviceType in config.json');
168
168
  }
169
- const secureboot = configJson.installer?.secureboot;
170
- if (secureboot != null && typeof secureboot !== 'boolean') {
171
- throw new ExpectedError(
172
- `Invalid installer.secureboot in config.json: value must be a boolean, found ${typeof secureboot}: '${secureboot}'`,
173
- );
174
- }
175
169
  return configJson;
176
170
  }
177
171