Compare commits

...

3 commits

Author SHA1 Message Date
Armaël Guéneau 14c6dae001 sshtool: handle sudo passwords that contain quotes or backslashes 2024-04-27 11:56:53 +02:00
Armaël Guéneau 6307f7e62f caribou: update ipv6 address after ISP change 2024-04-26 18:00:56 +02:00
Armaël Guéneau 37192f9dff tlsproxy: better error message when no argument is passed 2024-04-26 13:15:52 +02:00
3 changed files with 5 additions and 5 deletions

View file

@ -9,7 +9,7 @@
boot.loader.efi.canTouchEfiVariables = true; boot.loader.efi.canTouchEfiVariables = true;
deuxfleurs.hostName = "caribou"; deuxfleurs.hostName = "caribou";
deuxfleurs.staticIPv6.address = "2001:910:1204:1::23"; deuxfleurs.staticIPv6.address = "2a01:e0a:2c:540::23";
deuxfleurs.isRaftServer = true; deuxfleurs.isRaftServer = true;
system.stateVersion = "21.05"; system.stateVersion = "21.05";

View file

@ -26,7 +26,7 @@ else
fi fi
if [ -z "$ROOT_PASS" ]; then if [ -z "$ROOT_PASS" ]; then
read -s -p "Enter remote sudo password: " ROOT_PASS read -r -s -p "Enter remote sudo password: " ROOT_PASS
echo echo
fi fi
@ -37,11 +37,11 @@ function header {
cat <<EOF cat <<EOF
cat > /tmp/deploytool_askpass_$RANDNAME <<EOG cat > /tmp/deploytool_askpass_$RANDNAME <<EOG
#!/usr/bin/env sh #!/usr/bin/env sh
echo "\\\$DEPLOYTOOL_ROOT_PASSWORD" echo "\\\$DEPLOYTOOL_ROOT_PASSWORD" | base64 -d
EOG EOG
chmod +x /tmp/deploytool_askpass_$RANDNAME chmod +x /tmp/deploytool_askpass_$RANDNAME
export SUDO_ASKPASS=/tmp/deploytool_askpass_$RANDNAME export SUDO_ASKPASS=/tmp/deploytool_askpass_$RANDNAME
export DEPLOYTOOL_ROOT_PASSWORD="$ROOT_PASS" export DEPLOYTOOL_ROOT_PASSWORD=$(echo $ROOT_PASS | base64)
sudo -A sh - <<'EOEVERYTHING' sudo -A sh - <<'EOEVERYTHING'
set -e set -e
EOF EOF

View file

@ -7,7 +7,7 @@ set -xe
cd $(dirname $0) cd $(dirname $0)
CLUSTER="$1" CLUSTER="$1"
if [ ! -d "cluster/$CLUSTER" ]; then if [ ! -d "cluster/$CLUSTER" ] || [ -z "$CLUSTER" ]; then
echo "Usage: $0 <cluster name>" echo "Usage: $0 <cluster name>"
echo "The cluster name must be the name of a subdirectory of cluster/" echo "The cluster name must be the name of a subdirectory of cluster/"
exit 1 exit 1