Last active
April 18, 2016 09:06
-
-
Save j3tm0t0/10006334 to your computer and use it in GitHub Desktop.
loadkey
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/vbash | |
source /opt/vyatta/etc/functions/script-template | |
configure | |
loadkey vyos http://169.254.169.254/latest/meta-data/public-keys/0/openssh-key | |
set service ssh disable-password-authentication | |
commit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
vyos@vyos:~$ configure | |
[edit] | |
vyos@vyos# set interfaces vti vti0 | |
[edit] | |
vyos@vyos# exit discard | |
exit | |
vyos@vyos:~$ cat > /var/tmp/loadkey.sh | |
#!/bin/vbash | |
source /opt/vyatta/etc/functions/script-template | |
configure | |
loadkey vyos http://169.254.169.254/latest/meta-data/public-keys/0/openssh-key | |
set service ssh disable-password-authentication | |
commit | |
vyos@vyos:~$ sudo vbash /var/tmp/loadkey.sh | |
######################################################################## 100.0% | |
Done | |
[ service ssh ] | |
Restarting OpenBSD Secure Shell server: sshd. | |
vyos@vyos:~$ configure | |
[edit] | |
vyos@vyos# set interfaces vti vti0 | |
Set failed | |
[edit] | |
vyos@vyos# |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment