[Komodo] Commit Sync: update master_sync.toml
This commit is contained in:
@@ -143,14 +143,6 @@ additional_env_files = ["stack.env"]
|
|||||||
|
|
||||||
##
|
##
|
||||||
|
|
||||||
[[stack]]
|
|
||||||
name = "repoflow"
|
|
||||||
[stack.config]
|
|
||||||
server = "unraid"
|
|
||||||
linked_repo = "compose-repoflow"
|
|
||||||
|
|
||||||
##
|
|
||||||
|
|
||||||
[[stack]]
|
[[stack]]
|
||||||
name = "resilio-sync"
|
name = "resilio-sync"
|
||||||
[stack.config]
|
[stack.config]
|
||||||
@@ -691,7 +683,6 @@ branch = "master"
|
|||||||
[[procedure]]
|
[[procedure]]
|
||||||
name = "Image Pull"
|
name = "Image Pull"
|
||||||
config.schedule_timezone = "America/New_York"
|
config.schedule_timezone = "America/New_York"
|
||||||
config.schedule = "every day at 2:00 AM"
|
|
||||||
|
|
||||||
[[procedure.config.stage]]
|
[[procedure.config.stage]]
|
||||||
name = "Stage 1 - Update All Images"
|
name = "Stage 1 - Update All Images"
|
||||||
@@ -702,6 +693,39 @@ executions = [
|
|||||||
|
|
||||||
##
|
##
|
||||||
|
|
||||||
|
[[action]]
|
||||||
|
name = "Deploy if Changed"
|
||||||
|
[action.config]
|
||||||
|
file_contents = """
|
||||||
|
// Same as BatchDeployStacksIfChanged, but with an exclusion filter
|
||||||
|
console.log('Deploying all non-excluded stacks...\n');
|
||||||
|
|
||||||
|
// Get Tag Id. The API should throw if it's not found, but we employ safety checks just in case
|
||||||
|
const exclusionTagId = (await komodo.read("GetTag", { tag: "ad-hoc" }))?._id?.$oid ?? null; // YOUR TAG HERE
|
||||||
|
if (!exclusionTagId)
|
||||||
|
console.log('Exclusion tag not found!\n');
|
||||||
|
|
||||||
|
// Deploy all stacks, minus the excluded ones
|
||||||
|
const allStacks = await komodo.read("ListStacks", {});
|
||||||
|
for(const stack of allStacks) {
|
||||||
|
const name = stack.name;
|
||||||
|
const id = stack.id;
|
||||||
|
const tags = stack.tags;
|
||||||
|
|
||||||
|
if(tags.includes(exclusionTagId)) {
|
||||||
|
console.log('Skipping stack', name, '(excuded)')
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
console.log('Deploying', name)
|
||||||
|
await komodo.execute("DeployStackIfChanged", {
|
||||||
|
stack: id,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
"""
|
||||||
|
|
||||||
|
##
|
||||||
|
|
||||||
[[builder]]
|
[[builder]]
|
||||||
name = "local"
|
name = "local"
|
||||||
[builder.config]
|
[builder.config]
|
||||||
|
|||||||
Reference in New Issue
Block a user