Skip to content

Commit

Permalink
Merge branch 'main' into fix-ess-alpha-feature
Browse files Browse the repository at this point in the history
  • Loading branch information
jeanduplessis authored Oct 7, 2024
2 parents 8d880a1 + 05ed12d commit e8f0fc4
Show file tree
Hide file tree
Showing 29 changed files with 656 additions and 810 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ on:

env:
# Common versions
GO_VERSION: '1.19'
GOLANGCI_VERSION: 'v1.50.0'
GO_VERSION: '1.21'
GOLANGCI_VERSION: 'v1.54.0'
DOCKER_BUILDX_VERSION: 'v0.8.2'

# Common users. We can't run a step 'if secrets.XXX != ""' but we can run a
Expand Down
25 changes: 17 additions & 8 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,15 @@
PROJECT_NAME ?= upjet-provider-template
PROJECT_REPO ?= github.com/upbound/$(PROJECT_NAME)

export TERRAFORM_VERSION ?= 1.2.1
export TERRAFORM_VERSION ?= 1.5.7

# Do not allow a version of terraform greater than 1.5.x, due to versions 1.6+ being
# licensed under BSL, which is not permitted.
TERRAFORM_VERSION_VALID := $(shell [ "$(TERRAFORM_VERSION)" = "`printf "$(TERRAFORM_VERSION)\n1.6" | sort -V | head -n1`" ] && echo 1 || echo 0)

export TERRAFORM_PROVIDER_SOURCE ?= hashicorp/null
export TERRAFORM_PROVIDER_REPO ?= https://github.com/hashicorp/terraform-provider-null
export TERRAFORM_PROVIDER_VERSION ?= 3.1.0
export TERRAFORM_PROVIDER_VERSION ?= 3.2.2
export TERRAFORM_PROVIDER_DOWNLOAD_NAME ?= terraform-provider-null
export TERRAFORM_PROVIDER_DOWNLOAD_URL_PREFIX ?= https://releases.hashicorp.com/$(TERRAFORM_PROVIDER_DOWNLOAD_NAME)/$(TERRAFORM_PROVIDER_VERSION)
export TERRAFORM_NATIVE_PROVIDER_BINARY ?= terraform-provider-null_v3.1.0_x5
Expand Down Expand Up @@ -40,8 +44,8 @@ NPROCS ?= 1
# to half the number of CPU cores.
GO_TEST_PARALLEL := $(shell echo $$(( $(NPROCS) / 2 )))

GO_REQUIRED_VERSION ?= 1.19
GOLANGCILINT_VERSION ?= 1.50.0
GO_REQUIRED_VERSION ?= 1.21
GOLANGCILINT_VERSION ?= 1.54.0
GO_STATIC_PACKAGES = $(GO_PROJECT)/cmd/provider $(GO_PROJECT)/cmd/generator
GO_LDFLAGS += -X $(GO_PROJECT)/internal/version.Version=$(VERSION)
GO_SUBDIRS += cmd internal apis
Expand All @@ -51,7 +55,7 @@ GO_SUBDIRS += cmd internal apis
# Setup Kubernetes tools

KIND_VERSION = v0.15.0
UP_VERSION = v0.18.0
UP_VERSION = v0.28.0
UP_CHANNEL = stable
UPTEST_VERSION = v0.5.0
-include build/makelib/k8s_tools.mk
Expand Down Expand Up @@ -93,15 +97,20 @@ xpkg.build.upjet-provider-template: do.build.images

# NOTE(hasheddan): we ensure up is installed prior to running platform-specific
# build steps in parallel to avoid encountering an installation race condition.
build.init: $(UP)
build.init: $(UP) check-terraform-version

# ====================================================================================
# Setup Terraform for fetching provider schema
TERRAFORM := $(TOOLS_HOST_DIR)/terraform-$(TERRAFORM_VERSION)
TERRAFORM_WORKDIR := $(WORK_DIR)/terraform
TERRAFORM_PROVIDER_SCHEMA := config/schema.json

$(TERRAFORM):
check-terraform-version:
ifneq ($(TERRAFORM_VERSION_VALID),1)
$(error invalid TERRAFORM_VERSION $(TERRAFORM_VERSION), must be less than 1.6.0 since that version introduced a not permitted BSL license))
endif

$(TERRAFORM): check-terraform-version
@$(INFO) installing terraform $(HOSTOS)-$(HOSTARCH)
@mkdir -p $(TOOLS_HOST_DIR)/tmp-terraform
@curl -fsSL https://releases.hashicorp.com/terraform/$(TERRAFORM_VERSION)/terraform_$(TERRAFORM_VERSION)_$(SAFEHOST_PLATFORM).zip -o $(TOOLS_HOST_DIR)/tmp-terraform/terraform.zip
Expand All @@ -127,7 +136,7 @@ pull-docs:

generate.init: $(TERRAFORM_PROVIDER_SCHEMA) pull-docs

.PHONY: $(TERRAFORM_PROVIDER_SCHEMA) pull-docs
.PHONY: $(TERRAFORM_PROVIDER_SCHEMA) pull-docs check-terraform-version
# ====================================================================================
# Targets

Expand Down
10 changes: 10 additions & 0 deletions apis/null/v1alpha1/zz_generated.conversion_hubs.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions apis/null/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions apis/null/v1alpha1/zz_generated.managed.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions apis/null/v1alpha1/zz_generated.managedlist.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 1 addition & 5 deletions apis/null/v1alpha1/zz_groupversion_info.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

21 changes: 13 additions & 8 deletions apis/null/v1alpha1/zz_resource_types.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions apis/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions apis/v1beta1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions apis/v1beta1/zz_generated.pc.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions apis/v1beta1/zz_generated.pcu.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions apis/v1beta1/zz_generated.pculist.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 1 addition & 5 deletions apis/zz_register.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit e8f0fc4

Please sign in to comment.