Skip to content

Commit

Permalink
OS-???? imgadm will not import active images if they have any inactiv…
Browse files Browse the repository at this point in the history
…e origin images
  • Loading branch information
Marsell Kukuljevic authored and danmcd committed Nov 20, 2023
1 parent 76b9002 commit a2c7f63
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/img/lib/sources/imgapi.js
Expand Up @@ -21,6 +21,7 @@
* CDDL HEADER END
*
* Copyright (c) 2015, Joyent, Inc. All rights reserved.
* Copyright 2023 Spearhead Systems SRL.
*/

var p = console.log;
Expand Down Expand Up @@ -227,9 +228,11 @@ ImgapiSource.prototype.getImgAncestry = function getImgAncestry(opts, cb) {
getNextOrigin(opts.manifest.origin);

function getNextOrigin(uuid) {
// We do not want to ensure an origin image is active, since active
// leaf images sometimes depend on deactivated origin images.
var iOpts = {
arg: uuid,
ensureActive: true,
ensureActive: false,
errOn404: true
};
self.getImportInfo(iOpts, function (err, importInfo) {
Expand Down

0 comments on commit a2c7f63

Please sign in to comment.