Browse Source

bugfix launch script

feature/startup-from-labels
Mario Alegre 5 years ago
parent
commit
85cb7475ea
  1. 9
      bin/pdm-launch
  2. 1
      src/debian/assets/bash.bashrc

9
bin/pdm-launch

@ -39,10 +39,10 @@ else
fi
if [[ $FLAGS_config == $FLAGS_TRUE ]]; then
echo "Getting deploy options from image metadata label \"$FLAGS_deployopts\" ..."
deployopts=$(podman image inspect -f "{{ .Config.Labels.${FLAGS_deployopts} }}" $image)
echo "Getting deploy options from image metadata label \"$FLAGS_label\" ..."
deployopts=$(podman image inspect -f "{{ .Config.Labels.${FLAGS_label} }}" $image)
if [[ $deployopts == "<no value>" ]]; then
echo "Error: image metadata label \"$FLAGS_deployopts\" is empty or nonexistent."
echo "Error: image metadata label \"$FLAGS_label\" is empty or nonexistent."
exit 2
fi
else
@ -53,5 +53,6 @@ if [[ $FLAGS_overwrite ]]; then
podman rm -i -f $name
fi
podman run -itd --name $name --hostname $name --userns=keep-id $deployopts $image
podman run -itd --name $name --hostname $name $deployopts $image
# --userns=keep-id
echo "Done!"

1
src/debian/assets/bash.bashrc

@ -83,4 +83,3 @@ fi
alias dir='ls -lFAh'
alias rsyn='rsync -vaSH'
alias sudo='sudo -S'

Loading…
Cancel
Save