Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions app/registries/providers/lscr/Lscr.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,13 @@ const Ghcr = require('../ghcr/Ghcr');
*/
class Lscr extends Ghcr {
getConfigurationSchema() {
return this.joi.object().keys({
username: this.joi.string().required(),
token: this.joi.string().required(),
});
return this.joi.alternatives([
this.joi.string().allow(''),
this.joi.object().keys({
username: this.joi.string().required(),
token: this.joi.string().required(),
}),
]);
}

/**
Expand Down
19 changes: 13 additions & 6 deletions app/registries/providers/trueforge/trueforge.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,21 @@
const Ghcr = require('../ghcr/Ghcr');
const Quay = require('../quay/Quay');

/**
* Linux-Server Container Registry integration.
*/
class Trueforge extends Ghcr {
class Trueforge extends Quay {
getConfigurationSchema() {
return this.joi.object().keys({
username: this.joi.string().required(),
token: this.joi.string().required(),
});
return this.joi.alternatives([
// Anonymous configuration
this.joi.string().allow(''),

// Auth configuration
this.joi.object().keys({
namespace: this.joi.string().required(),
account: this.joi.string().required(),
token: this.joi.string().required(),
}),
]);
}

/**
Expand Down