Move Bifrost Persona feedback deployment onto Yggdrasil
This commit is contained in:
parent
2873dc3568
commit
0d9fd12628
3 changed files with 42 additions and 36 deletions
|
|
@ -1,14 +0,0 @@
|
|||
[CmdletBinding()]
|
||||
param([string] $SshTarget = "yggdrasil")
|
||||
$ErrorActionPreference = "Stop"
|
||||
if ($env:IDUNN_ACTUATOR -ne "1" -or $env:IDUNN_COMMAND_AUTHORITY -ne "idunn-daemon") {
|
||||
throw "This command is owned by Idunn's deployment actuator."
|
||||
}
|
||||
if ($env:IDUNN_DEPLOYMENT_REQUEST_ID -notmatch '^deploy:yggdrasil-bifrost-persona-feedback:.+') {
|
||||
throw "Idunn deployment request identity is absent or targets another daemon."
|
||||
}
|
||||
$requestId = $env:IDUNN_DEPLOYMENT_REQUEST_ID
|
||||
if ($requestId -notmatch '^[A-Za-z0-9._:-]+$') { throw "Idunn deployment request identity contains unsafe characters." }
|
||||
$remote = "sudo -n env IDUNN_ACTUATOR=1 IDUNN_COMMAND_AUTHORITY=idunn-daemon IDUNN_DEPLOYMENT_REQUEST_ID='$requestId' /usr/local/sbin/idunn-deploy-bifrost-persona-feedback-yggdrasil"
|
||||
& ssh.exe $SshTarget $remote
|
||||
if ($LASTEXITCODE -ne 0) { throw "Yggdrasil Bifrost Persona-feedback deployment failed with exit code $LASTEXITCODE." }
|
||||
|
|
@ -19,7 +19,7 @@ compose=/srv/compose/yggdrasil-apps.yaml
|
|||
|
||||
require_release_lineage() {
|
||||
case "$target" in
|
||||
epiphany) target_requires_bifrost_authority=true ;;
|
||||
epiphany|bifrost-persona-feedback) target_requires_bifrost_authority=true ;;
|
||||
voidbot|heimdall|repixelizer|streampixels) target_requires_bifrost_authority=false ;;
|
||||
*) echo "deployment target has no release-authority policy: $target" >&2; exit 1 ;;
|
||||
esac
|
||||
|
|
@ -88,7 +88,7 @@ case "$action:$target" in
|
|||
IDUNN_REQUIRES_BIFROST_AUTHORITY="$requires_bifrost_authority" \
|
||||
exec "$manifest" "$action"
|
||||
;;
|
||||
deploy:heimdall|deploy:repixelizer|deploy:streampixels)
|
||||
deploy:heimdall|deploy:repixelizer|deploy:streampixels|deploy:bifrost-persona-feedback)
|
||||
manifest="/srv/odin/deploy-manifests/$target"
|
||||
if [ ! -x "$manifest" ] || [ ! -O "$manifest" ]; then
|
||||
echo "root-owned executable deploy manifest is not installed: $manifest" >&2
|
||||
|
|
|
|||
Loading…
Reference in a new issue