66 lines
2 KiB
Text
66 lines
2 KiB
Text
|
|
let mp = import "schemas/lib/manifest_plan.ncl" in
|
||
|
|
|
||
|
|
{
|
||
|
|
manifest_plan | mp.ManifestPlan = {
|
||
|
|
init = [
|
||
|
|
{ file = "namespace", action = 'apply, skip_if_exists = true },
|
||
|
|
{ action = 'create-credentials' },
|
||
|
|
{ action = 'apply-tls-secret' },
|
||
|
|
{ file = "pvc", action = 'apply, skip_if_exists = true },
|
||
|
|
{ file = "configmap", action = 'apply },
|
||
|
|
{ file = "deployment", action = 'apply },
|
||
|
|
{ file = "lb-ipam-pool", action = 'apply, skip_if_exists = true },
|
||
|
|
{ file = "service", action = 'apply },
|
||
|
|
{ file = "service-admin", action = 'apply },
|
||
|
|
{
|
||
|
|
action = 'wait-ready,
|
||
|
|
post = [
|
||
|
|
{ action = 'protect-volume, params = { pvc = "stalwart-data" } },
|
||
|
|
],
|
||
|
|
},
|
||
|
|
{
|
||
|
|
action = 'smtp-check,
|
||
|
|
delay = 5,
|
||
|
|
post = [
|
||
|
|
{ action = 'notify-redeploy,
|
||
|
|
params = { message = "stalwart deployed to ${STALWART_HOSTNAME}" } },
|
||
|
|
],
|
||
|
|
},
|
||
|
|
],
|
||
|
|
update = [
|
||
|
|
{ file = "configmap", action = 'apply },
|
||
|
|
{ action = 'apply-tls-secret' },
|
||
|
|
{ file = "lb-ipam-pool", action = 'apply },
|
||
|
|
{ file = "service", action = 'recreate },
|
||
|
|
{ file = "service-admin", action = 'recreate },
|
||
|
|
{
|
||
|
|
file = "deployment",
|
||
|
|
action = 'rollout-restart,
|
||
|
|
delay = 3,
|
||
|
|
post = [
|
||
|
|
{ action = 'wait-ready' },
|
||
|
|
{ action = 'smtp-check, delay = 5 },
|
||
|
|
{ action = 'notify-redeploy,
|
||
|
|
params = { message = "stalwart updated on ${STALWART_HOSTNAME}" } },
|
||
|
|
],
|
||
|
|
},
|
||
|
|
],
|
||
|
|
delete = [
|
||
|
|
{ file = "deployment", action = 'delete },
|
||
|
|
{ file = "service", action = 'delete },
|
||
|
|
{ file = "service-admin", action = 'delete },
|
||
|
|
{ file = "configmap", action = 'delete },
|
||
|
|
{ file = "lb-ipam-pool", action = 'delete },
|
||
|
|
],
|
||
|
|
restart = [
|
||
|
|
{
|
||
|
|
file = "deployment",
|
||
|
|
action = 'rollout-restart,
|
||
|
|
post = [
|
||
|
|
{ action = 'wait-ready' },
|
||
|
|
],
|
||
|
|
},
|
||
|
|
],
|
||
|
|
},
|
||
|
|
}
|