Follow DLS' breaking changes, init rename and unlock API

This commit is contained in:
Guillaume
2023-11-06 17:17:02 +01:00
parent 01a457ccfe
commit 09e63cf400
4 changed files with 8 additions and 9 deletions

View File

@ -73,7 +73,7 @@ unlock_store() {
pinfo "Direktil Local Server store already unlocked"
else
pinfo "Unlocking the DLS store ..."
DLS_ADM_TOKEN=$(dls /public/unlock-store -d "\"${DLS_UNLOCK_TOKEN}\""|tr -d \")
DLS_ADM_TOKEN=$(dls /public/unlock-store -d '{"Name": "novit", "Passphrase": "'$(echo -n ${DLS_UNLOCK_TOKEN}|base64 -w0)'"}'|tr -d \")
pinfo "Admin access token is $DLS_ADM_TOKEN"
echo $DLS_ADM_TOKEN > $tknfile
chmod 444 $tknfile
@ -94,7 +94,7 @@ get_hosts() {
get_parts() {
for host in ${!hosts[*]}; do
mkdir -p $ctxdir/data/$host
for part in kernel initrd-v2
for part in kernel initrd
do
partfile=$ctxdir/data/$host/$part
test -f $partfile || { pinfo "Downloading $part for host $host" && dls /hosts/$host/$part -o $partfile; }