Linode/Setup: Difference between revisions

211 bytes removed ,  22:56, 8 October 2023
Removing a user from sudo group and removing an authorized key
m (setup admin account from CLI)
(Removing a user from sudo group and removing an authorized key)
 
(2 intermediate revisions by the same user not shown)
Line 20: Line 20:
usermod -aG sudo USERNAME
usermod -aG sudo USERNAME
</syntaxhighlight>
</syntaxhighlight>
* To remove a user from <code>sudo</code> group
<syntaxhighlight lang="bash">
sudo gpasswd -d USERNAME sudo
</syntaxhighlight>
Also, to remove their ability to ssh as root, remove their public key from <code>.ssh/authorized_keys</code>


== Security (only need to do this at setup) ==
== Security (only need to do this at setup) ==
Line 160: Line 168:
ip6tables-restore < /etc/iptables/rules.v6
ip6tables-restore < /etc/iptables/rules.v6
</syntaxhighlight>
</syntaxhighlight>
== Setting up an SMTP server ==
By default, Linode disables SMTP ports 587 etc. This requires a manual human-facing support ticket to remove. (Done by @Jonny on Nov 25 2022)
== Setting up an admin account from CLI w/ email confirmation ==
This command will work if the username and email have been registered from the UI. Very useful if SMTP server hasn't been setup yet. Note that you need to be logged in as the mastodon user for this to work.