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

adding sonar major version 4.16 #424

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

Conversation

jagdeep-sonar
Copy link
Collaborator

No description provided.

@jagdeep-sonar
Copy link
Collaborator Author

Hi Linda,

5 Checks failed above and I see following error:
module.hub_hadr[0].null_resource.exec_replication_cycle_on_dr (remote-exec): The exception was: "Replication script exited with code 1, full error: {'ok': 0.0, 'errmsg': 'Replication script exited with code 1', 'code': 151}"

Please share the access instructions for a live system so that I can pass on to respective team to look into this error.

@lindanasredin
Copy link
Collaborator

Hi Jagdeep, the ssh keys of the environment are added to the github action as "Artifact", you can see then if you scroll down the action main page. By default, when an action runs, whether successful or failed, the resources are destroyed. To keep the resources for an investigation, you can use the "delay destroy" feature when you run the action manually.

@jagdeep-sonar
Copy link
Collaborator Author

Hi Linda - I was able to find the SSH key from Sonar machine from "Artifacts" section on Github actions page. and I successfully manually triggered the github actions with "delay destroy" option. But, I am facing issue while finding the public ip of host servers. I think I need to go through jumphost. Please share the jumphost information so that we can ssh to those servers.

@lindanasredin
Copy link
Collaborator

Hi Jagdeep, you are right, when the machine is not publicly accessible, you have to go via a jump server. Usually, depending on the terraform example/recipe, the Hub is accessible directly and the gateways are accessible via a jump server which is the Hub. Now, you don't need to build the ssh command yourself, we generate it and we take into account whether there is a jump server or not. You can see in the terraform output, for each machine, what is the ssh command to reach it. You can find the terraform output in one of the steps in the github action output.

@jagdeep-sonar
Copy link
Collaborator Author

HI Linda. thanks for the information. I checked terraform output and i think i found the ssh command. I will try sshing with it.

@lindanasredin
Copy link
Collaborator

Sure

@jagdeep-sonar
Copy link
Collaborator Author

Hi Team.. while pushing changes for adding major 4.16 version, github actions is failing. to debug, i re-ran the workflow manually with delay destroy. now i need to ssh to the created DR machine. i have the ssh key and ssh command. but i am getting following error:

➜ ~ ssh -i ssh_keys/dsf_ssh_key-dsf_cli-sonar-132-1- [email protected]
ssh: connect to host ec2-13-41-252-225.eu-west-2.compute.amazonaws.com port 22: Operation timed out

manual run link: https://github.com/imperva/dsfkit/actions/runs/9811668509

what might be the issue here?

@jagdeep-sonar
Copy link
Collaborator Author

HI Linda,

workflow run: https://github.com/imperva/dsfkit/actions/runs/10376028524

i tried within the 30 min window.
image

but still getting operation timeout for hub_dr and hub_main.
image

my branch has the latest ssh_cidr code as well to allow vancouver traffic:
image

can we get on a call to sort this out? or can you try manually running and then sshing into hub_dr machine? need to know if i am missing something.

@lindanasredin
Copy link
Collaborator

Hi Jagdeep, I just started a manual run with a destroy delay. I will let you know. We can have a call if needed.

@lindanasredin
Copy link
Collaborator

Hi Jagdeep, I successfully sshed to the Hub DR.
image
Please check that the CIDRs I used for your location are correct. Does your IP fall in one of these two? "209.66.79.224/28", "208.98.210.80/28"
If not, please let me know what are the correct CIDRs for your location. Thanks.

@jagdeep-sonar
Copy link
Collaborator Author

HI Linda,

my ip doesn't fall under above mentioned 2 ranges. Correct CIDRs for our location are mentioned below:
{
"id": "GP-US-North-West",
"comment":"Global-Protect VPN POP, US-North-West",
"ipRanges": [
"134.238.191.246/32",
"134.238.191.247/32",
"134.238.234.241/32",
"134.238.234.242/32",
"134.238.234.243/32",
"134.238.234.244/32"
]
},
{
"id": "GP-Canada-West",
"comment":"Global-Protect VPN POP, Canada-West",
"ipRanges": [
"134.238.194.107/32",
"134.238.194.108/32",
"165.1.251.20/32",
"165.1.251.21/32",
"165.1.251.8/32",
"165.1.251.9/32"
]
},

Reference: https://gitlab.imperva.local/imperva_infrastructure/it-networking/-/blob/master/Imperva-GP-Public-IPs.json

Please add these to the ALLOWED_SSH_CIDRS secret in Github.

@lindanasredin
Copy link
Collaborator

lindanasredin commented Aug 15, 2024

Hi Jagdeep, I have added CIDRs of GP-Canada-West and GP-US-North-West to ALLOWED_SSH_CIDRS secret.

@jagdeep-sonar
Copy link
Collaborator Author

HI Linda,
Thanks for adding the new CIDRs. it works. i am able to SSH into machines.
Shared audit.log with David. will also fetch replication.log and share.

@jagdeep-sonar
Copy link
Collaborator Author

shared replication.log with David.

@eytannnaim
Copy link
Collaborator

shared replication.log with David.

Any updates with that?

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

4 participants