-
Notifications
You must be signed in to change notification settings - Fork 84
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #66 from jastang/jastang-use-bundled-xpkg
Use bundled packages and update CI for publishing
- Loading branch information
Showing
9 changed files
with
82 additions
and
72 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Submodule build
updated
4 files
+9 −6 | makelib/helm.mk | |
+1 −1 | makelib/k8s_tools.mk | |
+1 −0 | makelib/local.mk | |
+123 −0 | makelib/xpkg.mk |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,9 @@ | ||
FROM BASEIMAGE | ||
FROM gcr.io/distroless/static@sha256:1f580b0a1922c3e54ae15b0758b5747b260bd99d39d40c2edb3e7f6e2452298b | ||
|
||
COPY package.yaml . | ||
ARG TARGETOS | ||
ARG TARGETARCH | ||
|
||
ADD bin/$TARGETOS\_$TARGETARCH/provider /usr/local/bin/crossplane-kubernetes-provider | ||
|
||
USER 65532 | ||
ENTRYPOINT ["crossplane-kubernetes-provider"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,34 @@ | ||
# ==================================================================================== | ||
# Setup Project | ||
|
||
PLATFORMS := linux_amd64 linux_arm64 | ||
include ../../../build/makelib/common.mk | ||
|
||
# ==================================================================================== | ||
# Options | ||
IMAGE = $(BUILD_REGISTRY)/provider-kubernetes-$(ARCH) | ||
OSBASEIMAGE = scratch | ||
include ../../../build/makelib/image.mk | ||
include ../../../build/makelib/imagelight.mk | ||
|
||
# ==================================================================================== | ||
# Targets | ||
|
||
img.build: | ||
@$(INFO) docker build $(IMAGE) | ||
@$(MAKE) BUILD_ARGS="--load" img.build.shared | ||
@$(OK) docker build $(IMAGE) | ||
|
||
img.publish: | ||
@$(INFO) Skipping image publish for $(IMAGE) | ||
@echo Publish is deferred to xpkg machinery | ||
@$(OK) Image publish skipped for $(IMAGE) | ||
|
||
img.build.shared: | ||
@cp Dockerfile $(IMAGE_TEMP_DIR) || $(FAIL) | ||
@cp -R ../../../package $(IMAGE_TEMP_DIR) || $(FAIL) | ||
@cd $(IMAGE_TEMP_DIR) && $(SED_CMD) 's|BASEIMAGE|$(OSBASEIMAGE)|g' Dockerfile || $(FAIL) | ||
@cd $(IMAGE_TEMP_DIR) && $(SED_CMD) 's|VERSION|$(VERSION)|g' package/crossplane.yaml || $(FAIL) | ||
@cd $(IMAGE_TEMP_DIR) && find package -type f -name '*.yaml' -exec cat {} >> 'package.yaml' \; -exec printf '\n---\n' \; || $(FAIL) | ||
@docker build $(BUILD_ARGS) \ | ||
--build-arg ARCH=$(ARCH) \ | ||
--build-arg TINI_VERSION=$(TINI_VERSION) \ | ||
@cp -r $(OUTPUT_DIR)/bin/ $(IMAGE_TEMP_DIR)/bin || $(FAIL) | ||
@docker buildx build $(BUILD_ARGS) \ | ||
--platform $(IMAGE_PLATFORMS) \ | ||
-t $(IMAGE) \ | ||
$(IMAGE_TEMP_DIR) || $(FAIL) | ||
@$(OK) docker build $(IMAGE) | ||
|
||
img.promote: | ||
@$(INFO) Skipping image promotion from $(FROM_IMAGE) to $(TO_IMAGE) | ||
@echo Promote is deferred to xpkg machinery | ||
@$(OK) Image promotion skipped for $(FROM_IMAGE) to $(TO_IMAGE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,18 @@ | ||
apiVersion: meta.pkg.crossplane.io/v1alpha1 | ||
apiVersion: meta.pkg.crossplane.io/v1 | ||
kind: Provider | ||
metadata: | ||
name: provider-kubernetes | ||
annotations: | ||
descriptionShort: | | ||
meta.crossplane.io/maintainer: Crossplane Maintainers <[email protected]> | ||
meta.crossplane.io/source: github.com/crossplane-contrib/provider-kubernetes | ||
meta.crossplane.io/license: Apache-2.0 | ||
meta.crossplane.io/description: | | ||
The Crossplane Kubernetes provider enables management of Kubernetes Objects. | ||
spec: | ||
controller: | ||
image: crossplane/provider-kubernetes-controller:VERSION | ||
meta.crossplane.io/readme: | | ||
`provider-kubernetes` is a Crossplane Provider that enables deployment and management | ||
of arbitrary Kubernetes objects on clusters typically provisioned by Crossplane: | ||
- A `Provider` resource type that only points to a credentials `Secret`. | ||
- An `Object` resource type that is to manage Kubernetes Objects. | ||
- A managed resource controller that reconciles `Object` typed resources and manages | ||
arbitrary Kubernetes Objects. |