Adding public key system to update script.
There should be no issue with this. The SSH server will already advertise the keys to all connecting instances.
This commit is contained in:
parent
1bc305b48e
commit
0edd5d513a
12
ssh/makefile
12
ssh/makefile
|
@ -1,6 +1,6 @@
|
|||
SRC_DIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
|
||||
SOURCE := $(SRC_DIR)/config
|
||||
TARGET := ~/.ssh/config
|
||||
CONFIG_SRC := $(SRC_DIR)/config
|
||||
CONFIG_TRGT := ~/.ssh/config
|
||||
JPATRICK_KEY := ~/.ssh/git.jpatrick.io
|
||||
|
||||
include ../lib/shared.mk
|
||||
|
@ -9,10 +9,16 @@ install: | init update
|
|||
|
||||
init:
|
||||
$(info => Setting up ssh)
|
||||
$(mk_link) $(SOURCE) $(TARGET)
|
||||
$(mk_link) $(CONFIG_SRC) $(CONFIG_TRGT)
|
||||
$(mk_link) $(SRC_DIR)/public_keys ~/.ssh/public_keys
|
||||
$(MAKE) -C $(SRC_DIR) init_jpatrick_key
|
||||
|
||||
update:
|
||||
cd ~/.ssh \
|
||||
&& mkdir -p public_keys/`hostname` \
|
||||
&& for i in *.pub ; do ; \
|
||||
cp $$i public_keys/`hostname`/$$i ; \
|
||||
done
|
||||
|
||||
remove:
|
||||
$(info => Remvoing ssh)
|
||||
|
|
1
ssh/public_keys/zuk/git.jpatrick.io.pub
Normal file
1
ssh/public_keys/zuk/git.jpatrick.io.pub
Normal file
|
@ -0,0 +1 @@
|
|||
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHc429ju3N/DoIe7r4F35asaZeNv6/ZWPGXlQiEHUMtf zuk Tue Apr 16 21:54:38 EDT 2019
|
1
ssh/public_keys/zuk/id_ed25519.pub
Normal file
1
ssh/public_keys/zuk/id_ed25519.pub
Normal file
|
@ -0,0 +1 @@
|
|||
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIC9pheTZRF6Yo2Od0b8CyxLuazodEtB/5oAEDei8cBvi zuk: Sun 10 Nov 2019 11:50:45 AM EST
|
1
ssh/public_keys/zuk/jpatrick.io.pub
Normal file
1
ssh/public_keys/zuk/jpatrick.io.pub
Normal file
|
@ -0,0 +1 @@
|
|||
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICmLHzD7WneJQEHCNgT5k/4wa8rM07yQVu8w7nH3dNU5 zuk: 20190430235108
|
Loading…
Reference in New Issue
Block a user