Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Shipwright Overview

Shipwright Overview

This slide introduces the overview of "Shipwright", which is a framework for building container images on Kubernetes.

The slide was published at the following event.
[ Kubernetes Meetup Tokyo #45 ]
https://k8sjp.connpass.com/event/223232/

269258447d4284b5cb2ce0f048d143b2?s=128

Shingo.Kitayama

September 27, 2021
Tweet

Transcript

  1. None
  2. None
  3. None
  4. いらすとや $ docker build $ docker push $ docker run

  5. None
  6. None
  7. --- apiVersion: shipwright.io/v1alpha1 kind: Build metadata: name: go-tutorial-kaniko spec: source:

    url: https://github.com/shipwright-io/sample-go contextDir: docker-build strategy: name: kaniko kind: ClusterBuildStrategy output: image: docker.io/${REGISTRY_USER}/${REGISTRY_REPO}/go-tutorial credentials: name: dockerhub-token
  8. --- apiVersion: shipwright.io/v1alpha1 kind: BuildRun metadata: generateName: go-tutorial-kaniko-run- spec: buildRef:

    name: go-tutorial-kaniko ## Register the Build Object. $ cat ./builds/go-tutorial-kaniko.yaml |envsubst |kubectl apply -f – ## Execute Build process by BuildRun $ kubectl create -f ./buildruns/go-tutorial-kaniko-run.yaml
  9. None
  10. --- apiVersion: shipwright.io/v1alpha1 kind: ClusterBuildStrategy metadata: name: kaniko spec: buildSteps:

    - name: build-and-push image: gcr.io/kaniko-project/executor:v1.6.0 … command: - /kaniko/executor args: - --skip-tls-verify=true - --dockerfile=$(build.dockerfile) - --context=$(params.shp-source-context) - --destination=$(params.shp-output-image) - --oci-layout-path=/kaniko/oci-image-layout - --snapshotMode=redo - --push-retry=3
  11. None
  12. None
  13. None