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

Generate and install SSH key #2

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Generate and install SSH key #2

wants to merge 1 commit into from

Conversation

ares
Copy link
Owner

@ares ares commented Mar 8, 2019

@ehelms I tried to follow the same pattern. With this, I'm able to run REX jobs against localhost right away. The last issue is that the proxy was not registered to default org,loc but that's not related to this change.

@@ -9,6 +9,11 @@
name: rubygem-smart_proxy_ansible
state: latest

- name: 'Install smart_proxy_ansible'
yum:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not required, but I did bad using yum earlier and not package

state: link

- name: Generate /etc/ssh/ RSA host key
command: 'ssh-keygen -q -t rsa -b 4096 -f {{ foreman_proxy_remote_execution_ssh_dir }}/{{ foreman_proxy_remote_execution_ssh_keypair_name }} -C "Foreman Remote execuction key" -N ""'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would also let you drop the next two file tasks

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Welp, I see further down below you already had that thought.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe move it before these command so thats more obvious reading top-bottom

src: "{{ foreman_proxy_remote_execution_ssh_dir }}/{{ foreman_proxy_remote_execution_ssh_keypair_name }}"
register: foreman_rex_ssh_private_key


Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Silly nitpick extra line here.

@ehelms
Copy link
Contributor

ehelms commented Mar 8, 2019

The generation of the keys and the deployment of the keys seem separate to me. Is there a reason I am missing for the two being coupled? Can I as a user supply my own set of ssh keys (I assume yes given the pattern you copied).

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

Successfully merging this pull request may close these issues.

2 participants