sshUser mit und ohne @

This commit is contained in:
Jakobus Schürz 2019-08-01 22:52:35 +02:00
parent 544a26c54a
commit 3d479977f0

View file

@ -21,7 +21,11 @@ def serve_principal(sshUser, principals):
TEMPLATE=('command="gitosis-serve %(user)s",no-port-forwarding,'
+'no-X11-forwarding,no-agent-forwarding,no-pty %(principals)s')
print TEMPLATE % dict(user=sshUser, principals=principals)
if '@' in sshUser:
for user in [ sshUser, sshUser.split('@')[0] ]
print TEMPLATE % dict(user=user, principals=principals)
else:
print TEMPLATE % dict(user=sshUser, principals=principals)
class Main(app.App):