widdix / aws-ec2-ssh

Manage AWS EC2 SSH access with IAM

Home Page:https://cloudonaut.io/manage-aws-ec2-ssh-access-with-iam/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Auth fails with AuthorizedKeysCommandUser nobody

adamcrown opened this issue · comments

Metadata:

  • Operating System: Amazon Linux AMI release 2017.09
  • Installation method: install.sh
  • AWS CLI Version: aws-cli/1.14.9 Python/2.7.12 Linux/4.9.75-25.55.amzn1.x86_64 botocore/1.8.13

I'm unable to SSH into the machine when AuthorizedKeysCommandUser is set to nobody.
I get this error in the logs:

error: AuthorizedKeysCommand /opt/authorized_keys_command.sh adam.crownoble failed, status 1

If I change the AuthorizedKeysCommandUser to root it works fine. I haven't been able to find any details on what the actual error is and I don't see any way to customize the user in the project. So at this point I'll probably just have to write my own sed command to overwrite it every time.

Any help on a better solution would be appreciated. Thanks.

P.S. I'm using this on an Elastic Beanstalk server. Not sure if that really matters.

How to you execute install.sh with Elastic Beanstalk?

there hasn't been any progress for a while. feel free to reopen if that changes.