Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bastillion deletes any other ssh key from authorized_keys #399

Open
kais2019 opened this issue Nov 24, 2021 · 4 comments
Open

Bastillion deletes any other ssh key from authorized_keys #399

kais2019 opened this issue Nov 24, 2021 · 4 comments

Comments

@kais2019
Copy link

I noticed, that Bastillion deletes systems authorized_keys file everytime anythung is changed and write it new.

Thats not optimal, because I use some server that communicate with each other using ssh.
So the initial authorized_keys file of this servers includes some ssh keys that must stay in place.

Is there a chance to keep them save?

Maybe a kind of marker in the authorized_keys file, so that Bastillion will not cahnge content above this marker-line?

Best regards,
Kai

@snspinn
Copy link

snspinn commented Nov 24, 2021

Hi there Kai.

Totally new to Bastillion but this maybe define two authorized key files (one user managed, another Bastillion managed)?: https://serverfault.com/questions/1000636/how-can-i-have-multiple-authorized-keys-files

Duck-Duck_Go'd "multiple authorized_keys files" to find the above.

@vsilent
Copy link

vsilent commented Dec 20, 2021

Confirm, I used the same approach, just created another authorized_keys2 file for extra keys

@jl-678
Copy link

jl-678 commented Jun 24, 2022

Use case: I want the authorized key file to contain keys from other clients like my laptop, for example. Currently, Bastillion overwrites all keys in the authorized key file except for its own.

The suggested solution from this thread:

  1. Create the authorized_keys2 file and populate it with desired keys
  2. Verify that it works
  3. Login with Bastillion

Annoyingly, after step 3, Bastillion actually deletes the authoized_keys2 file along with resetting the authorized_keys file. Any ideas?

@jl-678
Copy link

jl-678 commented Jun 24, 2022

Update: this is covered clearly in the documentation which I missed. Check out the details here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants