fix: git docker shim
This commit is contained in:
parent
8d45311e0d
commit
ce0042117c
4 changed files with 3 additions and 2 deletions
|
@ -4,4 +4,5 @@ if ! getent passwd git &>/dev/null; then
|
|||
echo "creating git user..."
|
||||
useradd -m git
|
||||
usermod git -aG docker
|
||||
chsh -s /home/git/docker-shell git
|
||||
fi
|
|
@ -1,3 +1,3 @@
|
|||
Match User git
|
||||
AuthorizedKeysCommandUser git
|
||||
AuthorizedKeysCommand /usr/bin/docker exec -i git /usr/local/bin/gitea keys -c /data/gitea/conf/app.ini -e git -u %u -t %t -k %k
|
||||
AuthorizedKeysCommand /usr/bin/docker exec -iu git git /usr/local/bin/gitea keys -c /data/gitea/conf/app.ini -e git -u %u -t %t -k %k
|
|
@ -1,2 +1,2 @@
|
|||
#!/bin/sh
|
||||
/usr/bin/docker exec -i --env SSH_ORIGINAL_COMMAND="$SSH_ORIGINAL_COMMAND" gitea sh "$@"
|
||||
/usr/bin/docker exec -iu git --env SSH_ORIGINAL_COMMAND="$SSH_ORIGINAL_COMMAND" git sh "$@"
|
Loading…
Reference in a new issue