Search icon
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Building CI/CD Systems Using Tekton

You're reading from  Building CI/CD Systems Using Tekton

Product type Book
Published in Sep 2021
Publisher Packt
ISBN-13 9781801078214
Pages 278 pages
Edition 1st Edition
Languages
Author (1):
Joel Lord Joel Lord
Profile icon Joel Lord

Table of Contents (20) Chapters

Preface 1. Section 1: Introduction to CI/CD
2. Chapter 1: A Brief History of CI/CD 3. Chapter 2: A Cloud-Native Approach to CI/CD 4. Section 2: Tekton Building Blocks
5. Chapter 3: Installation and Getting Started 6. Chapter 4: Stepping into Tasks 7. Chapter 5: Jumping into Pipelines 8. Chapter 6: Debugging and Cleaning Up Pipelines and Tasks 9. Chapter 7: Sharing Data with Workspaces 10. Chapter 8: Adding when Expressions 11. Chapter 9: Securing Authentication 12. Section 3: Tekton Triggers
13. Chapter 10: Getting Started with Triggers 14. Chapter 11: Triggering Tekton 15. Section 4: Putting It All Together
16. Chapter 12: Preparing for a New Pipeline 17. Chapter 13: Building a Deployment Pipeline 18. Assessments 19. Other Books You May Enjoy

Using workspaces in pipeline runs

As part of your pipeline definition, you cannot add a workspace the same way you could add default values to your parameters. If you want Tekton to start your pipeline automatically with the appropriate persistent volume claim, you will need to create a pipeline run:

  1. Start with a new file called pipelinerun.yaml. In there, create an object of kind PipelineRun. Like what you did with task runs, this object will have a generateName field instead of an actual name:
    apiVersion: tekton.dev/v1beta1 
    kind: PipelineRun 
    metadata: 
      generateName: clone-and-ls-pr- 
    spec: 
  2. This pipeline run will use the pipeline that you just built called clone-and-list:
      pipelineRef: 
        name: clone-and-list 
  3. Finally, add a workspace named codebase. This workspace uses a persistent volume claim, and the claimName is tekton-pvc:
     workspaces: 
       - name: codebase 
         persistentVolumeClaim...
lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €14.99/month. Cancel anytime}