From a26204fe38c128218c01ade32ffaa47d03a84dd4 Mon Sep 17 00:00:00 2001 From: Brendan Golden Date: Sun, 5 Jan 2025 15:43:21 +0000 Subject: [PATCH] feat: login to teh server step completed --- src/procedures/skynet/new_server.md | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/src/procedures/skynet/new_server.md b/src/procedures/skynet/new_server.md index 38dee07..b347178 100644 --- a/src/procedures/skynet/new_server.md +++ b/src/procedures/skynet/new_server.md @@ -6,7 +6,7 @@ Rough steps are as follows: 1. Plan the servers config 2. Login to Proxmox 3. Create Container using the base LXC image -4. Grab server details +4. Login to Server 5. Push new configuration ## Plan server Configuration @@ -124,11 +124,29 @@ There are a few gotcha's outlined above that ye do have to look over. #### Start after created Tick this box if you want it to boot up immediately after being installed. +## Login to Server +Now that the server is up and running it is time to login to it. +Assuming you have your SSH configured like (TODO: admin ssh config). +You just have to use ``ssh root@IP`` (for example ``ssh root@192.99.1.111``) +### Getting the server ssh key +We are logging in because we need to get the servers own ssh key. +You can find it in ``/etc/ssh``. +You have a choice between ``ssh_host_ed25519_key.pub`` and ``ssh_host_rsa_key.pub``. +``ssh_host_ed25519_key.pub`` is the recommended one. + +### Using the server ssh key +This key is used to decrypt secrets stored in our Nixos repo and as such needs to be added there. +1. Add the key with the other system keys [here][nixos_secrets]. +2. Add it to the systems array underneath that. +3. In the ``secrets`` folder run ``cd secrets && agenix -r`` to rekey the secrets. + * This is to give the new server access. +4. Commit all the changed files [server_name_skynet]: https://2009.skynet.ie/history.html [server_names]: https://forgejo.skynet.ie/Skynet/nixos/src/branch/main/Possible_Server_Names.md [server_inventory]: https://forgejo.skynet.ie/Skynet/nixos/src/branch/main/ITD/Server_Inventory.csv -[proxmox_lxc]: https://pve.proxmox.com/wiki/Linux_Container \ No newline at end of file +[proxmox_lxc]: https://pve.proxmox.com/wiki/Linux_Container +[nixos_secrets]: https://forgejo.skynet.ie/Skynet/nixos/src/branch/main/secrets/secrets.nix#L35 \ No newline at end of file