User1: Hi
User1: ssh_authorized_keys is adding to /root, but disabling only one of the two keys...
User1: ...with "echo 'Please login as the user \"centos\" rather than the user
User1: Should it disable all the keys?
User1: The keys are correctly added to the default user with is centos (on  CentOS7 / cloud-init 0,7,5)
User1: root seems to get a malformed authorized_key file
User1: Line #1: no-port-forwarding...Please login as the user...<KEY1>
User1: Line #2: <KEY2>
User1: Should the lines get the "no-port-forwarding...Please login as the user..." prefix?
User1: I meant: Shouldn't all the lines...
User2: User1 why would you need disabled keys at all?
User1: The authorized_keys are meant for the centos/cloud-user default user
User1: but cloud-init seems to copy the keys to root anyway...
User1: and disables the login using the prefix command...
User1: but it only added the prefix commant to one of the keys...
User1: ...so it happened that the second key could be used to login to the root user...
User1: To be clearer: all the ssh_authorized_keys were added correctly to the default user...
User1: however the keys were also copied to the root user, and supposedly disabled with with a prefix command
User1: which echoed the message Please login as user centos instead of user root
User1: However one of the keys copied to /root/.ssh/authorized_keys was not disabled with this technique
User2: User1 I think that the keys should not be copied to the root user.
User1: Seems to be a bug...the key was an ECDSA key so the prefix was not prepended...
User1: With two DSA keys, /root/,ssh/authorized looks correct now.
User3: hey all
User3: im struggling hard with an issue
User3: im putting a dumb script on user-data on ec2 ,  something like " #!/bin/bash touch /tmp/test"
User3: but it seems to run it only sometimes
User3: im sure im missing something about how to "sysprep" a default ami
User3: im using a custom ami (that came from a 14.04 ami ) but im reading that there's some stuff that i have to remove
User4: bechampion, you shouldn't have to remove anything.
User4: but it will only run once "per-instance" by default.
User4: you can change that to run "always" (every boot). but normally thats probalby not what you want.
User3: thanks ,  is it ran by root?
User3: cause im running an s3cmd but it doesn;t log out nothing ...
cloud-init
Ubuntu IRC