Commit Graph

34 Commits

Author SHA1 Message Date
Peter Rifel 701f01a26b
Use switch/case statement 2025-08-22 20:36:02 -05:00
Justin SB 98c1109cc6 gce: Add IPv6 support to subnet/instances
We need to specify StackType & IPv6AccessType
2023-03-31 09:33:47 -04:00
John Gardiner Myers 4d309b0b36 Move Cluster into CloudupSubContext 2022-12-20 08:11:01 -08:00
John Gardiner Myers f7383b29da Move Cloud into CloudupSubContext 2022-12-18 13:40:02 -08:00
John Gardiner Myers 7c3e32369a Refactor Context into separate cloudup and nodeup types 2022-12-17 17:42:46 -08:00
John Gardiner Myers 235aa61594 v1alpha3: move networking fields under networking 2022-12-02 19:19:59 -08:00
Ciprian Hacman d29812fc6e Replace fi.Bool/Float*/Int*/StringValue() with fi.ValueOf 2022-11-19 03:45:23 +02:00
Ciprian Hacman 8f79c9bd68 Replace fi.Bool/Float*/Int*/String() with fi.PtrTo() 2022-11-19 03:45:22 +02:00
Nat Henderson 9b08c4bb51 Enable internal load balancers when running on GCP
* Add ILBs, broadly following the AWS model.  The following new
capabilities are added for clusters in GCP:
  * Cluster's spec.api.loadBalancer can be set to 'type: internal' on
    GCP.
    * Therefore, GCP can now create:
        * regional backend services
        * regional (non-legacy) healthchecks
        * firewall rules with "internal" load-balancing scheme
        * firewall rules with dot-notation-specified IP addresses
  * Cluster's spec.api.loadBalancer's 'subnets' field functions
    as in the AWS model.

A few incidental changes are included, either because this change
touched the relevant code or because my use case happened to trigger the
issues that are fixed here.

* Cluster's spec.networkID field can be prefixed by project to use
  GCP's common cross-project networking model.
    * The presumption is that all specified subnets belong to this
      network and therefore this project.

* Add missing operation wait on forwarding rule creation.

* Some Terraform output improvements:
    * Permit no-ACL files in GCS buckets in Terraform output.
    * Enable marginally better cross-resource reference in Terraform outputs
    * Add project to network + subnetwork literals in Terraform output.
    * Add terraform output to backend services and health checks.

Testing:
  * Add mocks for backend services and health checks.
  * Add minimal integration test - copied from gce_private and ilb added.
  * Add update cluster goldens.

Co-authored-by: Travis Reid <travis_reid@apple.com>
2022-04-25 13:31:47 -07:00
Peter Rifel e0555bb431
Remove unused json field tags from terraform structs 2021-12-24 14:17:23 -06:00
justinsb d363bf3dad GCE: improve network & subnet terraform support
We should use the subnet spec in the Cluster, and default to creating
a new subnet/network, but allow an existing one to be specified.
2021-10-24 17:41:14 -04:00
justinsb 860b033ddc gce: allow network to be marked as shared 2021-10-23 23:54:39 -04:00
John Gardiner Myers 7c9e7e9286 Make Lifecycle field non-pointer 2021-06-02 23:02:16 -07:00
John Gardiner Myers 57dec35f68 Split out TerraformWriter 2021-05-02 21:54:46 -07:00
Kenji Kaneda 71f52363f8 Add a lifecycle test for GCE
- Move MockGCECloud to cloudmock/gce.
- Change Compute() and CloudDNS() of GCECloud to return interfaces
  for mocking
2021-04-26 13:05:27 -07:00
Li Zhijian 501df662d4 upup/pkg/fi/cloudup/gcetasks/subnet: Fix ineffectual assignment to patch
Signed-off-by: Li Zhijian <lizhijian@cn.fujitsu.com>
2021-02-05 16:41:55 +08:00
Peter Rifel 4d9f0128a3
Upgrade to klog2
This splits up the kubernetes 1.19 PR to make it easier to keep up to date until we get it sorted out.
2020-08-16 20:56:48 -05:00
John Gardiner Myers f72dac180d Switch to new fitasks marker 2020-07-28 11:48:08 -07:00
eric-hole 444ad7b4fd GCE: needs to use v1 network resources, not beta 2020-04-27 13:14:50 -07:00
eric-hole f25b26ff07 Migrates GCE sdk from v0.beta to v1 2020-04-24 10:54:19 -07:00
Peter Rifel 04a5ead08e Add cty field tags to Terraform structs 2020-04-05 21:18:02 -05:00
tanjunchen d5fef40863 upup/pkg/fi/cloudup/ upup/pkg/fi/nodeup/ hack/.staticcheck_failures : simplify code and remove code 2019-12-18 09:47:58 +08:00
mikesplain 9e55b8230a Update copyright notices
Also cleans some white spaces
2019-09-09 14:47:51 -04:00
Justin SB 62f7c26f98
Support "gce" networking mode, which uses ip aliases 2019-07-19 07:54:13 -04:00
Justin SB 3e33ac7682
Change code from glog to klog
We don't call klog.InitFlags yet, because that will cause a flag
redefinition error until we get everyone to stop using glog.  That
will happen when we update to k8s 1.13.
2019-05-06 12:54:51 -04:00
Justin Santa Barbara c14113a585 Apply goimports formatting to upup/pkg/fi/cloudup/gcetasks/ 2017-10-29 13:39:33 -04:00
chrislovecnm 0779fb6fc4 Implementing GCE as an inteface modelling aws cloud provider 2017-08-27 22:19:25 -06:00
Justin Santa Barbara 3e1ce4f950 Add Lifecycle 2017-07-15 22:01:03 -04:00
Justin Santa Barbara 645f330dad Re-enable GCE support
We move everything to the models.  We feature-flag it, because we
probably want to change the names etc, and we aren't going to be able to
offer smooth upgrades until that is done.
2017-02-28 20:08:03 -05:00
chrislovecnm 8fa2aac99f fixing more headers 2016-10-15 19:20:56 -06:00
Justin Santa Barbara d427858477 Rename to kops
The upup tool is now called kops, and we have moved repos
2016-06-30 09:25:25 -04:00
Justin Santa Barbara c72593fcf7 Use generators in tasks 2016-05-30 17:46:36 -04:00
Justin Santa Barbara caccb8953f UpUp: AWS support
Adds AWS support for both cloudup & nodeup.
Also cleaning up things found along the way!
2016-05-09 13:08:27 -04:00
Justin Santa Barbara d4c2cfaae7 Initial version of upup: cloudup & nodeup
* GCE support only
* Key and secret generation
* "Direct mode" makes API calls
* "Dry run mode" previews the changes
* Terraform output (though key generation not working for master ip)
* cloud-init output (though debian image does not ship with cloud-init)
2016-05-06 16:01:33 -04:00