Browse Source

fix: Include all providers in default dev build (#5851)

Co-authored-by: Gustavo Fernandes de Carvalho <17139678+gusfcarvalho@users.noreply.github.com>
Jean-Philippe Evrard 2 months ago
parent
commit
349d793b96
2 changed files with 4 additions and 2 deletions
  1. 1 1
      Makefile
  2. 3 1
      Tiltfile

+ 1 - 1
Makefile

@@ -192,7 +192,7 @@ generate: ## Generate code and crds
 # This is for running out-of-cluster locally, and is for convenience.
 # This is for running out-of-cluster locally, and is for convenience.
 # For more control, try running the binary directly with different arguments.
 # For more control, try running the binary directly with different arguments.
 run: generate ## Run app locally (without a k8s cluster)
 run: generate ## Run app locally (without a k8s cluster)
-	go run ./main.go
+	go run -tags $(PROVIDER) ./main.go
 
 
 manifests: helm.generate ## Generate manifests from helm chart
 manifests: helm.generate ## Generate manifests from helm chart
 	mkdir -p $(OUTPUT_DIR)/deploy/manifests
 	mkdir -p $(OUTPUT_DIR)/deploy/manifests

+ 3 - 1
Tiltfile

@@ -73,9 +73,11 @@ gcflags = ''
 if settings.get('debug').get('enabled'):
 if settings.get('debug').get('enabled'):
     gcflags = '-N -l'
     gcflags = '-N -l'
 
 
+buildtags = settings.get('buildtags', 'all_providers')
+
 local_resource(
 local_resource(
     'external-secret-binary',
     'external-secret-binary',
-    "CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -gcflags '{gcflags}' -v -o bin/external-secrets ./".format(gcflags=gcflags),
+    "CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -tags '{buildtags}' -gcflags '{gcflags}' -v -o bin/external-secrets ./".format(buildtags=buildtags, gcflags=gcflags),
     deps = [
     deps = [
         "main.go",
         "main.go",
         "go.mod",
         "go.mod",