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

gce: Set firewall rules for Internal LBs also #15611

Merged
merged 1 commit into from
Jul 10, 2023

Conversation

justinsb
Copy link
Member

@justinsb justinsb commented Jul 9, 2023

It seems we can use the exact same rules.

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. area/provider/gcp Issues or PRs related to gcp provider labels Jul 9, 2023
@justinsb
Copy link
Member Author

justinsb commented Jul 9, 2023

cc @hakman I had to do this to get any access (from the bastion), but I haven't found a nice way to actually test this properly. Have you found any tricks? (Maybe running kOps on a GCE VM in the same project/network?)

Edit: Actually I figured out one trick: we can scp kubectl and ~/.kube/config to the bastion and easily access the cluster from there.

It seems we can use the exact same rules.
@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Jul 9, 2023
Copy link
Member

@hakman hakman left a comment

Choose a reason for hiding this comment

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

Small nit, but otherwise nice find.
/lgtm
/approve
/hod in case you want to move the call to b.addFirewallRules() outside the create*LB functions.

@@ -215,8 +219,7 @@ func createInternalLB(b *APILoadBalancerBuilder, c *fi.CloudupModelBuilderContex
})
}
}

return nil
return b.addFirewallRules(c)
Copy link
Member

Choose a reason for hiding this comment

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

This may be better outside the create*LB methods.

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 10, 2023
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hakman

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jul 10, 2023
@hakman hakman changed the title GCE: Set firewall rules for Internal LBs also gce: Set firewall rules for Internal LBs also Jul 10, 2023
@k8s-ci-robot k8s-ci-robot merged commit 4ad116e into kubernetes:master Jul 10, 2023
k8s-ci-robot added a commit that referenced this pull request Jul 15, 2023
…15332-#15611-#15614-#15607-upstream-release-1.27

Automated cherry pick of #15602: gce: Add support for bastions#15332: gce: Update logic for internal LB#15611: gce: Set firewall rules for Internal LBs also#15614: gce: Rename firewall SSH rules for bastion#15607: gce: Use `user-data` instead of `startup-script` metadata
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/provider/gcp Issues or PRs related to gcp provider cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants