mattia
October 1, 2018, 11:23am
1
I would like to create a snapshot of the DO Droplet, and following this guide (https://www.digitalocean.com/docs/images/snapshots/how-to/snapshot-droplets/ ), they suggest to run sudo shutdown -h now
before make the snapshot.
i tried to run this and the console asks for [sudo] password for web:
I tried with the root password, and with the passwords in the group_vars/production/vault.yml, but with no luck.
Am i missing something?
where I can find this password?
By default in Trellis I don’t believe the web user has a password; it uses SSH keys for access. More importantly, though, the web user can’t reboot the server. You’ll need to use the admin
user for that.
mattia
October 1, 2018, 11:35am
3
i can correctly connect to the server with this ssh web@namewebsite.co.uk
, but when I run sudo shutdown -h now
it asks for the web passoword.
in the group_vars/all/security.yml, I set sshd_permit_root_login: false
How can I use the admin user? What I should run?
You can connect to the server as the admin user with ssh:
ssh admin@example.com
Or if you’re already connected as web
you can probably change users with
su admin
And typing the admin user’s password.
You can set or review the admin user’s password in group_vars/[environment]/vault.yml
2 Likes
mattia
October 1, 2018, 1:40pm
5
thanks @MWDelaney .
it was my error, I changed the admin_user in the group_vars/all/users.yml, I completely forgot about this.
Is it better to keep always the user “admin” or it is a good practice to change the admin_user name for security reason?
i switched off the server, and I made a snapshot, can I switch on the server directly from digital ocean or it would be better to do via command line?