Skip to content

Enable GCP native fencing#271

Merged
mpagot merged 1 commit intoSUSE:mainfrom
BillAnastasiadis:gcp_native
Sep 6, 2024
Merged

Enable GCP native fencing#271
mpagot merged 1 commit intoSUSE:mainfrom
BillAnastasiadis:gcp_native

Conversation

@BillAnastasiadis
Copy link
Copy Markdown
Collaborator

@BillAnastasiadis BillAnastasiadis commented Sep 5, 2024

This PR enables GCP native fencing, by passing the required variables from terraform to ansible and adding the gcp-specific stonith commands for ansible.

Verification Run

GCP

Native fencing

SBD

GCP SBD: http://openqaworker15.qa.suse.cz/tests/296342

AWS

AWS Native: http://openqaworker15.qa.suse.cz/tests/296341

AZURE

AZURE MSI: http://openqaworker15.qa.suse.cz/tests/296343

@BillAnastasiadis BillAnastasiadis changed the title WIP: Enable GCP native fencing Enable GCP native fencing Sep 6, 2024
Comment thread ansible/playbooks/tasks/cluster-bootstrap.yaml Outdated
Copy link
Copy Markdown
Collaborator

@alvarocarvajald alvarocarvajald left a comment

Choose a reason for hiding this comment

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

LGTM


- name: Set primary and secondary hostnames
ansible.builtin.set_fact:
primary_hostname: "{{ groups['hana'][0] }}"
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

We use similar query to calculate is_primary. Differences are:

  • all of them calculate it ad playbook level and not at task level
  • other places are using group.hana[0]
  • other places are using a combination like:
hosts: hana
vars:
        is_primary: "{{ ansible_play_hosts[0] == inventory_hostname }}"

Let's keep it like this here but revisit it everywhere in all files.

gcp_cluster_ip: ${hana-vip}
prefix: ${name_prefix}
project: ${gcp_project}
primary_zone: ${gcp_primary_zone}
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Similar to the other comment, we can think about moving them to hosts>>hana section of the playbook

Copy link
Copy Markdown
Collaborator

@mpagot mpagot left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Copy Markdown
Collaborator

@lilyeyes lilyeyes left a comment

Choose a reason for hiding this comment

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

Generally LGTM.

@mpagot mpagot merged commit 9f4aa9c into SUSE:main Sep 6, 2024
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.

4 participants