New: user support for ssh!

Hey folks! We’ve got some new ssh features for you. Our ssh server (hallpass) that powers the flyctl ssh * commands now supports logging in as users other than root. Previously no matter what user you tried to log in under, as long as the authentication checked out, you would be logged in as root.

Try this out

Prerequisites

  1. A wireguard tunnel into your fly private network

Steps

  1. Create an app flyctl apps create YOURAPPNAME
  2. Create a new machine flyctl m run nginx -a YOURAPPNAME
  3. SSH into your machine and create a user
    • flyctl ssh console -a YOURAPPNAME
      • useradd fly (and follow the prompts)
  4. Create an ssh cert flyctl ssh issue (follow the prompts)
  5. SSH in to your new user ssh -i ./path-to-cert-you-made fly@yourmachineip
    • check who you are whoami!

Caveats

  1. the sftp feature only works with root. attempting to sftp in as another user for now will result in an authentication error
6 Likes