Skip to content

Commit

Permalink
security fix: removal of go-git (#896)
Browse files Browse the repository at this point in the history
* security fix: removal of go-git

* env harmonization: TARGET_RESOURCE_GROUP->TARGET_CLUSTER_NAME

* Update docs/development/integration_tests.md

Co-authored-by: Rishabh Patel <[email protected]>

* doc: TARGET_CLUSTER_NAME defn move to general setup section

---------

Co-authored-by: Rishabh Patel <[email protected]>
  • Loading branch information
elankath and rishabh-11 authored Jan 24, 2024
1 parent 357c319 commit 4c2e31b
Show file tree
Hide file tree
Showing 480 changed files with 24 additions and 83,299 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
*.html
.vscode
.idea
.run
**/.env
*.DS_Store
managevm
Expand Down
5 changes: 3 additions & 2 deletions docs/development/integration_tests.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@ Integration tests for `machine-controller-manager-provider-{provider-name}` can
1. In order to apply the CRDs when the Control Cluster is a Gardener Shoot or if none of the controller images are specified, `machine-controller-manager` repository will be cloned automatically. Incase, this repository already exists in local system, then create a softlink as below which helps to test changes in `machine-controller-manager` quickly.
```bash
ln -sf <path-for-machine-controller-manager-repo> dev/mcm
```
```
1. Please pass `TARGET_CLUSTER_NAME` in the `.env` file. It will be used to initialize the orphan resource tracker. Keep it as the cluster name whose kubeconfig is specified in the `TARGET_KUBECONFIG` variable.

## Scenario based additional configurations
### Gardener Shoot as the Control Cluster

Expand All @@ -33,7 +35,6 @@ If the Control Cluster is a Gardener SEED cluster, then the suite ideally employ

1. Define the variable `IS_CONTROL_CLUSTER_SEED` in the `.env` file and set it to `true`.
`Warning:` Make sure to set the `CONTROL_NAMESPACE` variable to the shoot namespace where the control plane of the target resides.
1. Please pass `TARGET_RESOURCE_GROUP` in the `.env` file. It will be used for the `ResourceGroupName` in Azure clusters. Keep it as target cluster name for gardener shoot clusters.This is compulsory for Azure clusters.
1. (Optional) User can employ a custom `MachineClass` for the tests using below steps:
1. Deploy a `Secret` named `test-mc-secret` (that contains the provider secret and cloud-config) in the shoot namespace of the Control Cluster. That is, the value of `metadata.namespace` should be `technicalID` of the Shoot and it will be of the pattern `shoot--<project>--<shoot-name>`.
1. Create a `dev/machineclassv1.yaml` file and add an entry in the `.env` file with `MACHINECLASS_V1=dev/machineclassv1.yaml`.
Expand Down
14 changes: 0 additions & 14 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ require (
github.com/Masterminds/semver v1.5.0
github.com/cenkalti/backoff/v4 v4.2.1
github.com/davecgh/go-spew v1.1.1
github.com/go-git/go-git/v5 v5.4.2
github.com/google/uuid v1.3.0
github.com/onsi/ginkgo/v2 v2.13.0
github.com/onsi/gomega v1.29.0
Expand All @@ -28,17 +27,11 @@ require (
)

require (
github.com/Microsoft/go-winio v0.4.16 // indirect
github.com/ProtonMail/go-crypto v0.0.0-20210428141323-04723f9f07d7 // indirect
github.com/acomagu/bufpipe v1.0.3 // indirect
github.com/beorn7/perks v1.0.1 // indirect
github.com/blang/semver/v4 v4.0.0 // indirect
github.com/cespare/xxhash/v2 v2.2.0 // indirect
github.com/emicklei/go-restful/v3 v3.9.0 // indirect
github.com/emirpasic/gods v1.12.0 // indirect
github.com/evanphx/json-patch v4.12.0+incompatible // indirect
github.com/go-git/gcfg v1.5.0 // indirect
github.com/go-git/go-billy/v5 v5.3.1 // indirect
github.com/go-logr/logr v1.3.0 // indirect
github.com/go-openapi/jsonpointer v0.19.6 // indirect
github.com/go-openapi/jsonreference v0.20.2 // indirect
Expand All @@ -53,24 +46,18 @@ require (
github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1 // indirect
github.com/imdario/mergo v0.3.12 // indirect
github.com/inconshreveable/mousetrap v1.1.0 // indirect
github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 // indirect
github.com/josharian/intern v1.0.0 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/kevinburke/ssh_config v0.0.0-20201106050909-4977a11b4351 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect
github.com/mitchellh/go-homedir v1.1.0 // indirect
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/prometheus/client_model v0.4.0 // indirect
github.com/prometheus/common v0.44.0 // indirect
github.com/prometheus/procfs v0.10.1 // indirect
github.com/sergi/go-diff v1.1.0 // indirect
github.com/spf13/cobra v1.7.0 // indirect
github.com/xanzy/ssh-agent v0.3.0 // indirect
golang.org/x/crypto v0.14.0 // indirect
golang.org/x/mod v0.13.0 // indirect
golang.org/x/net v0.17.0 // indirect
golang.org/x/oauth2 v0.8.0 // indirect
Expand All @@ -82,7 +69,6 @@ require (
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/protobuf v1.30.0 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/warnings.v0 v0.1.2 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/gengo v0.0.0-20220902162205-c0856e24416d // indirect
Expand Down
Loading

0 comments on commit 4c2e31b

Please sign in to comment.