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

Revert "Update go version to 1.21" #104

Merged
merged 1 commit into from
Feb 7, 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
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Build the manager binary
FROM golang:1.21-bullseye as builder
FROM golang:1.17 as builder

WORKDIR /workspace
# Copy the Go Modules manifests
Expand Down
12 changes: 6 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -138,26 +138,26 @@ undeploy: ## Undeploy controller from the K8s cluster specified in ~/.kube/confi

CONTROLLER_GEN = $(shell pwd)/bin/controller-gen
controller-gen: ## Download controller-gen locally if necessary.
$(call go-install-tool,$(CONTROLLER_GEN),sigs.k8s.io/controller-tools/cmd/[email protected])
$(call go-get-tool,$(CONTROLLER_GEN),sigs.k8s.io/controller-tools/cmd/[email protected])

KUSTOMIZE = $(shell pwd)/bin/kustomize
kustomize: ## Download kustomize locally if necessary.
$(call go-install-tool,$(KUSTOMIZE),sigs.k8s.io/kustomize/kustomize/[email protected])
$(call go-get-tool,$(KUSTOMIZE),sigs.k8s.io/kustomize/kustomize/[email protected])

CRD_REF_DOCS = $(shell pwd)/bin/crd-ref-docs
crd-ref-docs: ## Download crd-ref-docs locally if necessary.
$(call go-install-tool,$(CRD_REF_DOCS),github.com/elastic/crd-ref-docs@master)
$(call go-get-tool,$(CRD_REF_DOCS),github.com/elastic/crd-ref-docs@master)

# go-install-tool will 'go get' any package $2 and install it to $1.
# go-get-tool will 'go get' any package $2 and install it to $1.
PROJECT_DIR := $(shell dirname $(abspath $(lastword $(MAKEFILE_LIST))))
define go-install-tool
define go-get-tool
@[ -f $(1) ] || { \
set -e ;\
TMP_DIR=$$(mktemp -d) ;\
cd $$TMP_DIR ;\
go mod init tmp ;\
echo "Downloading $(2)" ;\
GOBIN=$(PROJECT_DIR)/bin go install $(2) ;\
GOBIN=$(PROJECT_DIR)/bin go get $(2) ;\
rm -rf $$TMP_DIR ;\
}
endef
8 changes: 4 additions & 4 deletions controllers/gatling_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -464,8 +464,8 @@ func (r *GatlingReconciler) newGatlingRunnerJobForCR(gatling *gatlingv1alpha1.Ga
},
Spec: batchv1.JobSpec{
BackoffLimit: &noRestarts,
Parallelism: r.getGatlingRunnerJobParallelism(gatling),
Completions: r.getGatlingRunnerJobParallelism(gatling),
Parallelism: r.getGatlingRunnerJobParallelism(gatling),
Completions: r.getGatlingRunnerJobParallelism(gatling),
Template: corev1.PodTemplateSpec{
ObjectMeta: metav1.ObjectMeta{
Name: r.getObjectMeta(gatling).Name,
Expand Down Expand Up @@ -531,8 +531,8 @@ func (r *GatlingReconciler) newGatlingRunnerJobForCR(gatling *gatlingv1alpha1.Ga
},
Spec: batchv1.JobSpec{
BackoffLimit: &noRestarts,
Parallelism: &gatling.Spec.TestScenarioSpec.Parallelism,
Completions: &gatling.Spec.TestScenarioSpec.Parallelism,
Parallelism: &gatling.Spec.TestScenarioSpec.Parallelism,
Completions: &gatling.Spec.TestScenarioSpec.Parallelism,
Template: corev1.PodTemplateSpec{
ObjectMeta: metav1.ObjectMeta{
Name: r.getObjectMeta(gatling).Name,
Expand Down
Loading