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

Cloud Native Development - Openshift Pipelines

Cloud Native Development - Openshift Pipelines

Cloud-Native Development - Openshift Pipelines

Pooja Mistry

April 14, 2021
Tweet

More Decks by Pooja Mistry

Other Decks in Technology

Transcript

  1. Cloud Native Development
    Getting Started with OpenShift Pipelines
    Pooja - IBM, Developer Advocate
    Balaji - Infosys, Principal, Education Training and Assessment

    View Slide

  2. https://ibm.biz/cloudnative-gist

    View Slide

  3. Cloud native development is about how apps are built and deployed
    12 Factor is a methodology for building software
    Infosys and IBM have world class experience in cloud native development
    OpenShift is the most ideal platform for application deployment

    View Slide

  4. Cloud Native Principles
    Real-world Use Cases
    IBM Cloud Native Toolkit
    Hands-on Lab: Deploy with Tekton Pipelines

    View Slide

  5. Cloud native is about
    how an application is
    built and deployed, not
    where it resides.

    View Slide

  6. Cloud Native Building Blocks
    6
    Microservices
    Automated
    DevOps
    Containers
    Results in a lightweight, modular, highly automated approach

    View Slide

  7. Codebase Dependencies Configuration Backing Services
    Build Release Run Stateless Processes Port Binding Concurrency
    Disposability Dev Prod Parity Logs Admin Processes
    12 Factors

    View Slide

  8. Local
    Dev/Text
    Release
    Deploy
    Operate
    Measure
    Plan
    Code
    Build
    Test
    Enterprise Grade Software Development Life Cycle (SDLC)
    CI CD
    Jenkins
    (Build)
    Zenhub
    (Project mgmt)
    Image Registry
    (Container Images)
    (Store assets and
    dependencies)
    (Analyze and test code)
    CodeReady
    Workspaces
    (Web IDE)
    Swagger Editor
    (API validation &
    documentation)
    Kubernetes
    Pact Testing
    (Test microservice
    contracts)
    Sysdig
    (View metrics
    and alerts)
    LogDNA
    (View logs)
    Argo CD
    (CD Release)
    NPS
    Jaeger
    (Container Images)
    Knative
    Tekton
    (Build pipeline)
    (Helpdesk)
    PagerDuty
    IBM Hyper Protect
    Services
    (Code signing, Keep your own
    key - KYOK)
    Deploy to Clusters or Serverless
    Github
    (Source code mgmt)
    IBM Key Protect
    (Certificate APIs for
    code signing)
    8
    IBM Cloud / © 2020 IBM Corporation

    View Slide

  9. Lab

    View Slide

  10. • Open source governed by Continuous Delivery Foundation
    • Contributors from IBM, Google, Red Hat, and more
    • Cloud-native built upon Kubernetes
    • Pipelines, Tasks, PipelineRuns, etc. are CRDs
    • Formerly known as “Knative Build” and “Knative build-
    pipelines”
    • Parallel workflows, triggers, every step isolated in a container, etc.
    • Pipeline-as-code (yaml)
    • Pipeline portability across clouds and vendors
    • Trigger on Git commits, pull (merge) requests, webhook, manually,
    or specific times.
    • Fostering ecosystem of common pipelines and tasks, e.g. tool
    integrations, compliance process
    https://tekton.dev
    Tekton
    10
    IBM Cloud / © 2020 IBM Corporation

    View Slide

  11. Tekton Concept: Step
    • The smallest building block
    • Specify images, commands, arguments
    • Is a container
    steps:
    - name: echo
    image: ubuntu
    command:
    - echo
    args:
    - "hello world"

    View Slide

  12. Tekton CRD: Task
    • New CRD
    • Sequence of Steps
    • Run in sequential order
    • Reusable
    • Perform a specific task
    • Runs on the same k8s node
    apiVersion: tekton.dev/v1alpha1
    kind: Task
    metadata:
    name: echo-hello-world
    spec:
    steps:
    - name: echo
    image: ubuntu
    command:
    - echo
    args:
    - "hello world"

    View Slide

  13. Tekton CRD: Pipeline
    • Expresses Tasks
    • Sequentially
    • Concurrently
    • Links input and output
    • Execute Tasks on different nodes
    apiVersion: tekton.dev/v1alpha1
    kind: Pipeline
    metadata:
    name: tutorial-pipeline
    spec:
    - name: build-app
    taskRef:
    name: build-push
    resources:
    outputs:
    - name: image
    resource: my-image
    - name: deploy-app
    taskRef:
    name: deploy-kubectl
    resources:
    inputs:
    - name: image
    resource: my-image
    from:
    - build-app

    View Slide

  14. Tekton Runtime CRDs
    • Instances of Pipelines and Tasks:
    • PipelineRun
    • TaskRun
    • Runtime info such as registry information and git repo
    apiVersion: tekton.dev/v1alpha1
    kind: PipelineRun
    metadata:
    name: tutorial-pipeline-run-1
    spec:
    serviceAccountName: tutorial-service
    pipelineRef:
    name: tutorial-pipeline
    resources:
    - name: source-repo
    resourceRef:
    name: skaffold-git
    - name: web-image
    resourceRef:
    name: skaffold-image-leeroy-web

    View Slide

  15. Putting it all together
    Linting
    Unit tests
    Setup test
    environment
    Build images
    Run integration
    tests
    Run end to end
    tests
    Publish images Deploy
    Pipeline
    Task
    Task
    Task
    Task
    Task
    Task
    Task
    Step
    Step
    Step
    Step
    Step
    Step
    Step
    Step
    Step

    View Slide

  16. Getting Started with OpenShift Pipelines
    https://learn.openshift.com/middleware/pipelines/

    View Slide

  17. https://learn.openshift.com/middleware/pipelines/

    View Slide

  18. • Cloud-Native Toolkit Guide
    • Cloud Native Bootcamp
    • All new Building Cloud Native and Multicloud Applications course now
    available
    • Microservices for beginners
    • Red Hat OpenShift on IBM Cloud
    • Getting Started with Containers
    Resources

    View Slide

  19. Check out IBM Developer
    https://developer.ibm.com/components/redhat-openshift-ibm-cloud/

    View Slide

  20. FREE IBM Cloud Essentials course with BADGE
    https://cognitiveclass.ai/courses/ibm-cloud-essentials

    View Slide

  21. Subscribe to our Crowdcast.io
    https://www.crowdcast.io/ibmdeveloper

    View Slide

  22. 22

    View Slide