Skip to content

Latest commit

 

History

History
89 lines (56 loc) · 2.27 KB

sc02-tc07.md

File metadata and controls

89 lines (56 loc) · 2.27 KB

SC02-TC07: Creating Consistent and Secure Build Images for Applications

Original Request from Charter: CaaS control plane shall provide curated platform(JVM, NodeJS, Python, Go) images


Test Case Summary

This test case demonstrates a user submitting an "Image" resource and allowing Tanzu Build Service build the image and push to a registry using curated buildpacks that are consistently patched for security and best-practice


Prerequisites

  • Completion of SC01-TC01, SC01-TC02, SC02-TC07
  • vSphere Administrator console and user credentials
  • Tanzu Build Service installed and running in Shared Services cluster
  • Have kpack CLI installed
  • Image Repo installed - Harbor installed with Project/Repo
  • Git CLI

Test Procedure

  1. switch kubecontext to build service cluster

  2. kubeapply image manifest - yaml file in directory (spring-petclinic)

  3. check image build logs

  4. check harbor for image

  5. Change context to the kubernetes cluster where Tanzu Build Service is installed

  6. Create a new repository called microservices-demo for the images to live in Harbor. For simplicity sake, we will make this a public repo

  7. Create the registry secret for the service account to publish images to your Harbor registry. (We will use the kpack helper)

    kp secret create harbor-credentials --registry $HARBOR_HOSTNAME --registry-user $HARBOR_USER
  8. Clone the microservices-demo repo

    git clone -b tbs https://github.com/logankimmel/microservices-demo.git && cd microservices-demo
    
  9. Replace the existing harbor registry with your Harbor registry

    sed -i 's/harbor.vmw.binbytes.io/${HARBOR_HOSTNAME}/g' tbs-build.yaml
  10. Submit build manifest to Tanzu Build Service

    kubectl apply -f tbs-build.yaml
    
  11. Check status of image builds

    kp image list
    
  12. Obvserve builds

    kp build list
    
  13. Inspect logs on a build

    kp build logs adservice
    
  14. Once an image has completed the build, check Harbor registry for the newly created image


Status Pass/Fail

  • [ ] Pass
  • [ ] Fail

Return to Test Cases Inventory