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

Remove vendor dir #117

Merged
merged 3 commits into from
Mar 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,7 @@
#
# COMPONENT_PREFIXES: Set the image prefix that should be used to
# determine if an image is defined by another component.
# Defaults to "eu.gcr.io/gardener-project/gardener"
#
# GENERIC_DEPENDENCIES: Set images that are generic dependencies with no specific tag.
# Defaults to "hyperkube,kube-apiserver,kube-controller-manager,kube-scheduler,kube-proxy"
# Defaults to "eu.gcr.io/gardener-project/gardener,europe-docker.pkg.dev/gardener-project"
#
# COMPONENT_CLI_ARGS: Set all component-cli arguments.
# This should be used with care as all defaults are overwritten.
Expand Down Expand Up @@ -58,18 +55,14 @@ fi
if [[ ! -z "$image_vector_path" ]]; then
# default environment variables
if [[ -z "${COMPONENT_PREFIXES}" ]]; then
COMPONENT_PREFIXES="eu.gcr.io/gardener-project/gardener"
fi
if [[ -z "${GENERIC_DEPENDENCIES}" ]]; then
GENERIC_DEPENDENCIES="hyperkube,kube-apiserver,kube-controller-manager,kube-scheduler,kube-proxy"
COMPONENT_PREFIXES="eu.gcr.io/gardener-project/gardener,europe-docker.pkg.dev/gardener-project"
fi

if [[ -z "${COMPONENT_CLI_ARGS}" ]]; then
COMPONENT_CLI_ARGS="
--comp-desc ${BASE_DEFINITION_PATH} \
--image-vector "$image_vector_path" \
--component-prefixes "${COMPONENT_PREFIXES}" \
--generic-dependencies "${GENERIC_DEPENDENCIES}" \
"
fi

Expand All @@ -96,14 +89,7 @@ if [[ -d "$repo_root_dir/charts/" ]]; then
REPOSITORY=${imageAndTag[0]}
TAG=${imageAndTag[1]}

gardener="eu.gcr.io/gardener-project/gardener"
if [[ "$NAME" == "hyperkube" ]]; then
${ADD_DEPENDENCIES_CMD} --generic-dependencies "{\"name\": \"$NAME\", \"version\": \"$TAG\"}"
elif [[ $REPOSITORY =~ "eu.gcr.io/gardener-project/gardener"* ]]; then
${ADD_DEPENDENCIES_CMD} --generic-dependencies "{\"name\": \"$NAME\", \"version\": \"$TAG\"}"
else
${ADD_DEPENDENCIES_CMD} --container-image-dependencies "{\"name\": \"${NAME}\", \"image_reference\": \"${REPOSITORY}:${TAG}\", \"version\": \"$TAG\"}"
fi
${ADD_DEPENDENCIES_CMD} --container-image-dependencies "{\"name\": \"${NAME}\", \"image_reference\": \"${REPOSITORY}:${TAG}\", \"version\": \"$TAG\"}"
done < <(echo "$outputFile")
done
fi
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ elif name == 'logging':
elif name == 'etcd-custom-image':
names = ['etcd']
elif name == 'egress-filter-refresher':
names = ['egress-filter-blackholer', 'egress-filter-firewaller']
names = ['egress-filter']
elif name == 'apiserver-proxy':
names = ['apiserver-proxy-sidecar']
else:
Expand Down
5 changes: 0 additions & 5 deletions .ci/verify
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,4 @@ cd "$(dirname $0)/.."
git config --global user.email "[email protected]"
git config --global user.name "Gardener CI/CD"

# Required due to https://github.com/kubernetes/kubernetes/issues/86753 - can be removed once the issue is fixed.
mkdir -p /go/src/github.com/gardener/machine-controller-manager-provider-openstack
cp -r . /go/src/github.com/gardener/machine-controller-manager-provider-openstack
cd /go/src/github.com/gardener/machine-controller-manager-provider-openstack

make verify-extended
37 changes: 37 additions & 0 deletions .github/ISSUE_TEMPLATE/bug.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
---
name: Bug Report
about: Report a bug encountered while working with this Gardener extension

---

**How to categorize this issue?**
<!--
Please select area, kind, and priority for this issue. This helps the community categorizing it.
Replace below TODOs or exchange the existing identifiers with those that fit best in your opinion.
If multiple identifiers make sense you can also state the commands multiple times, e.g.
/area control-plane
/area auto-scaling
...

"/area" identifiers: audit-logging|auto-scaling|backup|certification|control-plane-migration|control-plane|cost|delivery|dev-productivity|disaster-recovery|documentation|high-availability|logging|metering|monitoring|networking|open-source|ops-productivity|os|performance|quality|robustness|scalability|security|storage|testing|usability|user-management
"/kind" identifiers: api-change|bug|cleanup|discussion|enhancement|epic|impediment|poc|post-mortem|question|regression|task|technical-debt|test
-->
/area TODO
/kind bug
/platform aws

**What happened**:

**What you expected to happen**:

**How to reproduce it (as minimally and precisely as possible)**:

**Anything else we need to know?**:

**Environment**:

- Gardener version (if relevant):
- Extension version:
- Kubernetes version (use `kubectl version`):
- Cloud provider or hardware configuration:
- Others:
25 changes: 25 additions & 0 deletions .github/ISSUE_TEMPLATE/feature.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
---
name: Enhancement Request
about: Suggest an enhancement for this extension

---

**How to categorize this issue?**
<!--
Please select area, kind, and priority for this issue. This helps the community categorizing it.
Replace below TODOs or exchange the existing identifiers with those that fit best in your opinion.
If multiple identifiers make sense you can also state the commands multiple times, e.g.
/area control-plane
/area auto-scaling
...

"/area" identifiers: audit-logging|auto-scaling|backup|certification|control-plane-migration|control-plane|cost|delivery|dev-productivity|disaster-recovery|documentation|high-availability|logging|metering|monitoring|networking|open-source|ops-productivity|os|performance|quality|robustness|scalability|security|storage|testing|usability|user-management
"/kind" identifiers: api-change|bug|cleanup|discussion|enhancement|epic|impediment|poc|post-mortem|question|regression|task|technical-debt|test
-->
/area TODO
/kind enhancement
/platform aws

**What would you like to be added**:

**Why is this needed**:
33 changes: 33 additions & 0 deletions .github/ISSUE_TEMPLATE/flaking-test.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
---
name: Flaking Test
about: Report flaky tests or jobs in Gardener CI
title: "[Flaky Test] FLAKING TEST/SUITE"

---

<!-- Please only use this template for submitting reports about flaky tests or jobs (pass or fail with no underlying change in code) in Gardener CI -->

**How to categorize this issue?**
<!--
Please select area, kind, and priority for this issue. This helps the community categorizing it.
Replace below TODOs or exchange the existing identifiers with those that fit best in your opinion.
If multiple identifiers make sense you can also state the commands multiple times, e.g.
/area control-plane
/area auto-scaling
...

"/area" identifiers: audit-logging|auto-scaling|backup|certification|control-plane-migration|control-plane|cost|delivery|dev-productivity|disaster-recovery|documentation|high-availability|logging|metering|monitoring|networking|open-source|ops-productivity|os|performance|quality|robustness|scalability|security|storage|testing|usability|user-management
"/kind" identifiers: api-change|bug|cleanup|discussion|enhancement|epic|impediment|poc|post-mortem|question|regression|task|technical-debt|test
-->
/area testing
/kind flake
/platform aws

**Which test(s)/suite(s) are flaking**:

**CI link**:

**Reason for failure**:

**Anything else we need to know**:

13 changes: 13 additions & 0 deletions .github/ISSUE_TEMPLATE/support.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
name: Support Request
about: Support request or question relating to this extension

---

<!--
STOP -- PLEASE READ!

GitHub is not the right place for support requests.

If you're looking for help, please post your question on the [Kubernetes Slack](http://slack.k8s.io/) ([#gardener](https://kubernetes.slack.com/messages/gardener) channel) or join our [bi-weekly meetings](https://gardener.cloud/docs/contribute/#bi-weekly-meetings).
-->
24 changes: 21 additions & 3 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,21 @@
**How to categorize this PR?**
<!--
Please select area, kind, and priority for this pull request. This helps the community categorizing it.
Replace below TODOs or exchange the existing identifiers with those that fit best in your opinion.
If multiple identifiers make sense you can also state the commands multiple times, e.g.
/area control-plane
/area auto-scaling
...

"/area" identifiers: audit-logging|auto-scaling|backup|compliance|control-plane-migration|control-plane|cost|delivery|dev-productivity|disaster-recovery|documentation|high-availability|logging|metering|monitoring|networking|open-source|ops-productivity|os|performance|quality|robustness|scalability|security|storage|testing|usability|user-management
"/kind" identifiers: api-change|bug|cleanup|discussion|enhancement|epic|flake|impediment|poc|post-mortem|question|regression|task|technical-debt|test

For Gardener Enhancement Proposals (GEPs), please check the following [documentation](https://github.com/gardener/gardener/tree/master/docs/proposals/README.md) before submitting this pull request.
-->
/area TODO
/kind TODO
/platform aws

**What this PR does / why we need it**:

**Which issue(s) this PR fixes**:
Expand All @@ -13,9 +31,9 @@ Write your release note:

Format of block header: <category> <target_group>
Possible values:
- category: breaking|feature|bugfix|doc|other
- category: breaking|noteworthy|feature|bugfix|doc|other
- target_group: user|operator|developer|dependency
-->
```improvement user
```other operator

```
```
86 changes: 39 additions & 47 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
#
# SPDX-License-Identifier: Apache-2.0

include vendor/github.com/gardener/gardener/hack/tools.mk
-include .env
ENSURE_GARDENER_MOD := $(shell go get github.com/gardener/gardener@$$(go list -m -f "{{.Version}}" github.com/gardener/gardener))
GARDENER_HACK_DIR := $(shell go list -m -f "{{.Dir}}" github.com/gardener/gardener)/hack


BINARY_PATH := bin/
REPO_ROOT := $(shell dirname $(realpath $(firstword $(MAKEFILE_LIST))))
HACK_DIR := $(REPO_ROOT)/hack
COVERPROFILE := test/output/coverprofile.out
Expand All @@ -21,32 +21,40 @@ LEADER_ELECT := "true"
MACHINE_CONTROLLER_MANAGER_DEPLOYMENT_NAME := machine-controller-manager

#########################################
# Tools
# Tools & Cleanup
#########################################

TOOLS_DIR := hack/tools
TOOLS_DIR := $(HACK_DIR)/tools
include $(GARDENER_HACK_DIR)/tools.mk
-include .env

.PHONY: tidy
tidy:
@go mod tidy
@mkdir -p $(REPO_ROOT)/.ci/hack && cp $(GARDENER_HACK_DIR)/.ci/* $(REPO_ROOT)/.ci/hack/ && chmod +xw $(REPO_ROOT)/.ci/hack/*
@GARDENER_HACK_DIR=$(GARDENER_HACK_DIR) bash $(REPO_ROOT)/hack/update-github-templates.sh
@cp $(GARDENER_HACK_DIR)/cherry-pick-pull.sh $(HACK_DIR)/cherry-pick-pull.sh && chmod +xw $(HACK_DIR)/cherry-pick-pull.sh

#################################################
# Rules for starting machine-controller locally
#################################################

.PHONY: start
start:
@GO111MODULE=on go run \
-mod=vendor \
cmd/machine-controller/main.go \
--control-kubeconfig=$(CONTROL_KUBECONFIG) \
--target-kubeconfig=$(TARGET_KUBECONFIG) \
--namespace=$(CONTROL_NAMESPACE) \
--machine-creation-timeout=20m \
--machine-drain-timeout=5m \
--machine-health-timeout=10m \
--machine-pv-detach-timeout=2m \
--machine-safety-apiserver-statuscheck-timeout=30s \
--machine-safety-apiserver-statuscheck-period=1m \
--machine-safety-orphan-vms-period=30m \
--leader-elect=$(LEADER_ELECT) \
--v=3
go run \
cmd/machine-controller/main.go \
--control-kubeconfig=$(CONTROL_KUBECONFIG) \
--target-kubeconfig=$(TARGET_KUBECONFIG) \
--namespace=$(CONTROL_NAMESPACE) \
--machine-creation-timeout=20m \
--machine-drain-timeout=5m \
--machine-health-timeout=10m \
--machine-pv-detach-timeout=2m \
--machine-safety-apiserver-statuscheck-timeout=30s \
--machine-safety-apiserver-statuscheck-period=1m \
--machine-safety-orphan-vms-period=30m \
--leader-elect=$(LEADER_ELECT) \
--v=3

#####################################################################
# Rules for verification, formatting, linting, testing and cleaning
Expand All @@ -55,37 +63,37 @@ start:
.PHONY: install
install:
@LD_FLAGS="-w -X github.com/gardener/$(NAME)/pkg/version.Version=$(VERSION)" \
$(REPO_ROOT)/vendor/github.com/gardener/gardener/hack/install.sh ./...
bash $(GARDENER_HACK_DIR)/install.sh ./...

.PHONY: generate
generate: $(CONTROLLER_GEN) $(GEN_CRD_API_REFERENCE_DOCS) $(HELM) $(MOCKGEN)
@$(REPO_ROOT)/vendor/github.com/gardener/gardener/hack/generate-sequential.sh ./charts/... ./cmd/... ./example/... ./pkg/...
generate: $(VGOPATH) $(CONTROLLER_GEN) $(GEN_CRD_API_REFERENCE_DOCS) $(HELM) $(MOCKGEN)
@REPO_ROOT=$(REPO_ROOT) VGOPATH=$(VGOPATH) GARDENER_HACK_DIR=$(GARDENER_HACK_DIR) bash $(GARDENER_HACK_DIR)/generate-sequential.sh ./charts/... ./cmd/... ./example/... ./pkg/...
$(MAKE) format

.PHONY: check-generate
check-generate:
@$(REPO_ROOT)/vendor/github.com/gardener/gardener/hack/check-generate.sh $(REPO_ROOT)
@bash $(GARDENER_HACK_DIR)/check-generate.sh $(REPO_ROOT)

.PHONY: format
format: $(GOIMPORTS) $(GOIMPORTSREVISER)
@$(REPO_ROOT)/vendor/github.com/gardener/gardener/hack/format.sh ./cmd ./pkg ./test
@bash $(GARDENER_HACK_DIR)/format.sh ./cmd ./pkg ./test

.PHONY: check
check: $(GOIMPORTS) $(GOLANGCI_LINT)
@$(REPO_ROOT)/vendor/github.com/gardener/gardener/hack/check.sh --golangci-lint-config=./.golangci.yaml ./cmd/... ./pkg/... ./test/...
@$(REPO_ROOT)/vendor/github.com/gardener/gardener/hack/check-charts.sh ./charts
@bash $(GARDENER_HACK_DIR)/check.sh --golangci-lint-config=./.golangci.yaml ./cmd/... ./pkg/... ./test/...
@bash $(GARDENER_HACK_DIR)/check-charts.sh ./charts

.PHONY: test
test:
@SKIP_FETCH_TOOLS=1 $(REPO_ROOT)/vendor/github.com/gardener/gardener/hack/test.sh ./cmd/... ./pkg/...
@SKIP_FETCH_TOOLS=1 bash $(GARDENER_HACK_DIR)/test.sh ./cmd/... ./pkg/...

.PHONY: test-cov
test-cov:
@SKIP_FETCH_TOOLS=1 $(REPO_ROOT)/vendor/github.com/gardener/gardener/hack/test-cover.sh ./cmd/... ./pkg/...
@SKIP_FETCH_TOOLS=1 bash $(GARDENER_HACK_DIR)/test-cover.sh ./cmd/... ./pkg/...

.PHONY: test-clean
test-clean:
@$(REPO_ROOT)/vendor/github.com/gardener/gardener/hack/test-cover-clean.sh
@bash $(GARDENER_HACK_DIR)/test-cover-clean.sh

.PHONY: verify
verify: check format test
Expand All @@ -95,7 +103,7 @@ verify-extended: check-generate check format test-cov test-clean

.PHONY: clean
clean:
@$(REPO_ROOT)/vendor/github.com/gardener/gardener/hack/clean.sh ./cmd/... ./pkg/...
@bash $(GARDENER_HACK_DIR)/clean.sh ./cmd/... ./pkg/...

.PHONY: test-integration
test-integration:
Expand All @@ -109,22 +117,6 @@ test-integration:
export MACHINE_CONTROLLER_MANAGER_DEPLOYMENT_NAME=$(MACHINE_CONTROLLER_MANAGER_DEPLOYMENT_NAME); \
.ci/local_integration_test

#########################################
# Rules for re-vendoring
#########################################

.PHONY: revendor
revendor:
@env GO111MODULE=on go mod tidy -v
@env GO111MODULE=on go mod vendor -v
@chmod +x $(REPO_ROOT)/vendor/github.com/gardener/gardener/hack/*
@chmod +x $(REPO_ROOT)/vendor/github.com/gardener/gardener/hack/.ci/*
@ln -sf ../vendor/github.com/gardener/gardener/hack/cherry-pick-pull.sh $(HACK_DIR)/cherry-pick-pull.sh

.PHONY: update-dependencies
update-dependencies:
@env GO111MODULE=on go get -u

#########################################
# Rules for build/release
#########################################
Expand Down
Loading
Loading