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

Refactor binaries download and fix few linting issues and typo #484

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

rabin-io
Copy link

@rabin-io rabin-io commented May 7, 2024

No description provided.

ansible.cfg Outdated Show resolved Hide resolved
ansible/roles/bastion-install/tasks/main.yml Outdated Show resolved Hide resolved
ansible/roles/bastion-install/tasks/main.yml Outdated Show resolved Hide resolved
ansible/roles/bastion-install/tasks/main.yml Outdated Show resolved Hide resolved
ansible.cfg Outdated Show resolved Hide resolved
@rabin-io rabin-io force-pushed the fix-1 branch 3 times, most recently from b96008b to 290bedf Compare May 10, 2024 12:43
@rabin-io rabin-io changed the title Fix few linting issues and typo Refactor binaries download and fix few linting issues and typo May 10, 2024
@rabin-io rabin-io requested review from dbutenhof and akrzos May 10, 2024 12:45
ansible/roles/bastion-install/defaults/main.yml Outdated Show resolved Hide resolved
ansible.cfg Outdated Show resolved Hide resolved
@rabin-io rabin-io force-pushed the fix-1 branch 2 times, most recently from eb739f3 to 48ef960 Compare May 13, 2024 13:02
@rabin-io rabin-io requested a review from dbutenhof May 13, 2024 13:05
@rabin-io
Copy link
Author

Any update?

Copy link
Member

@akrzos akrzos left a comment

Choose a reason for hiding this comment

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

Hi Rabin, I attempted to run the setup-bastion in my environment and immediate ran into this issue:

TASK [bastion-install : Get rhel8 opm] *******************************************************************************************************************************************************
Tuesday 28 May 2024  13:51:47 -0400 (0:00:16.220)       0:00:44.929 *********** 
fatal: [e38-h01-000-r650.rdu2.scalelab.redhat.com]: FAILED! => {"msg": "'openshift_client_url' is undefined. 'openshift_client_url' is undefined"}

ansible/roles/bastion-install/tasks/main.yml Outdated Show resolved Hide resolved
ansible/roles/bastion-install/defaults/main.yml Outdated Show resolved Hide resolved
mode: "0700"
- url: "{{ yq_url }}"
dest: "{{ bastion_cluster_config_dir }}/yq_linux_amd64.tar.gz"
force: false
Copy link
Member

Choose a reason for hiding this comment

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

Why was this changed? I believe believe force was set to guarantee it pulls the item down.

Copy link
Author

Choose a reason for hiding this comment

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

Yes correct, but you can optimize it when using the checksum, if the file in the destination have the same checksum, you won't need to download the file again.

@@ -9,14 +9,14 @@ address=/{{ groups['bastion'][0] }}/{{ bastion_controlplane_ip }}
address=/api.{{ cluster_name }}.{{ base_dns_name }}/{{ controlplane_network_api }}
address=/apps.{{ cluster_name }}.{{ base_dns_name }}/{{ controlplane_network_ingress }}

{% if groups['hv_vm'] is defined and (groups['hv_vm'] | length > 0) %}
Copy link
Member

Choose a reason for hiding this comment

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

I'm not sure I am in a current position to test the changes to the jinja statements here just yet. I'm trying to recall if there will be any un-intended side affects by adjusting what gates what here, so it might take me a few days to test this.

+ Refactor the task which downloads the helper files
  to use checksum to verify the downloads
+ ansible-lint auto fix
  - Truthy value should be one of [false, true]
  - File permissions unset or incorrect
  - Use FQCN for builtin module actions

Signed-off-by: Rabin Yasharzadehe <rabin@rabin.io>
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.

None yet

3 participants