Hi, how do you run forgejo under a reverse proxy while using an ssh channel to pull/push commits?

From what I understand caddy is only able to proxy http traffic.

  • @pe1uca@lemmy.pe1uca.dev
    link
    fedilink
    English
    24 months ago

    I can’t give you the technical explanation, but it works.
    My Caddyfile only something like this

    @forgejo host forgejo.pe1uca
    handle @forgejo {
    	reverse_proxy :8000
    }
    

    and everything else has worked properly cloning via ssh with git@forgejo.pe1uca:pe1uca/my_repo.git

    My guess is git only needs the host to resolve the IP and then connects to the port directly.

    • @wireless_purposely832@lemmy.world
      link
      fedilink
      English
      14 months ago

      I believe the reverse proxy settings in your post is just configured to handle the http/https connection, not the SSH connection. Instead, SSH connections are likely being routed to the machine running Foegejo via DNS and your reverse proxy is not involved with anything related to SSH.

      I assume you either have SSH disabled on your host or SSH on your host uses a port other than 22?