Remove duplicated code

This commit is contained in:
Manuel Thalmann 2024-12-06 16:22:05 +01:00
parent 055955a1bf
commit 77d8c350b7

View file

@ -31,7 +31,6 @@ begin
set -l port set -l port
set -l file (mktemp) set -l file (mktemp)
set -l root (getServiceRoot $argv) set -l root (getServiceRoot $argv)
set -l bin /usr/local/bin/forgejo
set -l config "$root/docker-compose.base.yml" set -l config "$root/docker-compose.base.yml"
set -l overrides (getServiceOverrides $argv) set -l overrides (getServiceOverrides $argv)
set -l envKey "$(getServiceKey "$service").environment" set -l envKey "$(getServiceKey "$service").environment"
@ -72,14 +71,6 @@ begin
end end
rm "$file" rm "$file"
begin
printf "%s\n" \
"#!/bin/sh" \
"ssh -p $port -o StrictHostKeyChecking=no git@127.0.0.1 \"SSH_ORIGINAL_COMMAND=\\\"$SSH_ORIGINAL_COMMAND\\\" \$0 \$@\""
end | sudo tee "$bin" >/dev/null
chmod +x "$bin"
end end
function getServiceServers -V server function getServiceServers -V server