"Virtual hosts" for ssh

Johannes Ernst johannes.ernst at gmail.com
Sat Jun 8 12:42:59 EST 2013


On Jun 7, 2013, at 17:59, Peter Stuge <peter at stuge.se> wrote:

> Johannes Ernst wrote:
>> very cool if ssh supported something like Apache "virtual hosts"
> 
> That makes not much sense,

Elaborate?

> but you could of course consider
> jails/containers/etc.

I don't see how this would work other than by assigning different IP addresses to the same server or at least using different ports. What am I missing?

Perhaps I wasn't as clear about the use case as I thought I was:

I'd like to be able to use the same user (say "git") on multiple git repositories on the same host, distinguished only by the hostname, but reaching different logical accounts with different credentials. Just like http://host1/blog and http://host2/blog can point to different installs of Wordpress on the same server (both of which have a user "admin" through the web interface that have nothing to do with each other), I'd like git commits by the same user for different virtual hostnames on the same server to have different credentials, and reach different repositories.

Think mass hosting of git installs (or gitolite, or gitorious, or ...) on the same host just like virtual HTTP hosting at your typical Wordpress host.

> host multiple installs of git on the same server
> 
> You can use real user accounts and POSIX ACLs:
> 
> # git init --shared "${repodir}" && find "${repodir}" -type d -execdir \
>  setfacl -m u::rwx,g::rwx,o::r-x,d:u::rwx,d:g::rwx,d:m::rwx,d:o::r-x '{}' +
> 
> ..or use something like gitolite in order to avoid learning about ACLs.

I think this is an issue unrelated to my problem / suggestion.

> 
> 
> //Peter
> _______________________________________________
> openssh-unix-dev mailing list
> openssh-unix-dev at mindrot.org
> https://lists.mindrot.org/mailman/listinfo/openssh-unix-dev



More information about the openssh-unix-dev mailing list