update process for public authorized_keys
This commit is contained in:
		
							parent
							
								
									b870537f47
								
							
						
					
					
						commit
						6c25bb5edd
					
				
					 3 changed files with 3 additions and 23 deletions
				
			
		|  | @ -2,9 +2,6 @@ | |||
| ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCoRxIS1Dr33Jhybd/ck7UCLQ1Df5msSpvw03w/ljgB+1sx/U+965+q597XRHHnzPey8NFrOdID4I1l0tfco1XG5DJG2yJ/zY+tbyK+0b0Yi4qbRFnH2kxKYcdHq29CiVk64o1VHJxxj78IO2wTUcgK4sXijm05LWqCik4LSfcOBEyOwK6f37Mew19KDq7UAojHLTEbVB6xiv2ufh9evn3PggirE1VtvQlTBnt3NdBDumxD1RzRoVgwMuU1FNvQeMwLnlMlvLX76vjPkRRrgBGEJ2k0BUm7slrAtRnBzIvIbouk55MIBzpPjCIi53L91KxwNkHNPldYG81C+BczN/R5 cardno:000604717732 | ||||
| 
 | ||||
| # Chromebook (GalliumOS) | ||||
| #ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIICIhbaWDDxwSn83MXmDes0ikUeighhfM/po1RPYYHDN lobo@chromebook | ||||
| 
 | ||||
| # Gallium - Chromebook running GalliumOS | ||||
| ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDxUNqjpukVhDXJnicD0dOhMMaQPOqYgPR14NSUd9rLp lobo@gallium | ||||
| 
 | ||||
| # Home server | ||||
|  |  | |||
|  | @ -1,21 +1,3 @@ | |||
| #!/bin/sh | ||||
| 
 | ||||
| # NOTE: %1 is the user being authorized. However, we'll make this only for | ||||
| #       the primary user | ||||
| 
 | ||||
| # Accomodate for local install | ||||
| PATH=$HOME/.local/bin:$PATH | ||||
| 
 | ||||
| # This is much slower than hitting DDB, so while it will work, we'll use | ||||
| # our codecommit -> DDB lambda function and pull direct from DDB. Also helps | ||||
| # with codecommit user count... | ||||
| 
 | ||||
| # aws codecommit get-file \ | ||||
| #   --repository-name authorized_keys \ | ||||
| #   --file-path authorized_keys \ | ||||
| #   --query 'fileContent' \ | ||||
| #   --cli-read-timeout 1 \ | ||||
| #   --cli-connect-timeout 1 \ | ||||
| #   --output text |base64 -d | ||||
| 
 | ||||
| aws dynamodb scan --table-name key --query 'Items[0].key.S' --output text | ||||
| curl -s https://emil.lerch.org/authorized_keys | ||||
|  |  | |||
							
								
								
									
										3
									
								
								makeitso
									
										
									
									
									
								
							
							
						
						
									
										3
									
								
								makeitso
									
										
									
									
									
								
							|  | @ -5,7 +5,8 @@ if [ $# -ne 1 ]; then | |||
|   exit 1 | ||||
| fi | ||||
| 
 | ||||
| sudo adduser --disabled-login --gecos 'User for AuthorizedKeysCommand' authorizedkeysuser | ||||
| #sudo adduser --disabled-login --gecos 'User for AuthorizedKeysCommand' authorizedkeysuser || | ||||
| sudo useradd -c 'User for AuthorizedKeysCommand' -d /home/authorizedkeysuser -m -s/usr/sbin/nologin authorizedkeysuser | ||||
| 
 | ||||
| sudo sh -c "echo 'Match User $1 | ||||
|   AuthorizedKeysCommand /etc/ssh/get_authorized_keys | ||||
|  |  | |||
		Loading…
	
	Add table
		
		Reference in a new issue