Accelerate Your Development and CI/CD Pipelines with Dagger

Márk Sági-Kazár


2025-05-05 @ Cloud Native Days Romania

whoami

Márk Sági-Kazár

Cloud Native Ambassador

Dagger Commander


YAML engineer for life 😭



@sagikazarmark

https://sagikazarmark.com

hello@sagikazarmark.com

Agenda

  • Introduction
  • Module 1: Getting to know Dagger
  • Module 2: Let’s Daggerize
  • Module 3: Working with modules
  • Module 4: Integrating with GitHub Actions
  • Module 5: Publishing artifacts
  • Q&A

CI/CD today

…aka the pain we all know

Day 1…

…how it starts 😃

name: CI

on:
  push:
    branches: [main]

jobs:
  build:
    name: build the software
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - run: |
          build
          test
          lint

Day 101…

…760 lines of YAML & Bash 😟

# Foobar pipeline
# Include the Common CI pipeline parameters.
include:
  - project: 'foo/bar/foobarproject/cicdtemplate'
    file: '/Common.gitlab-ci.yml'
  #- /force-app/ui-tests/pipeline.yml

stages:
  - build-metadata-package
  - run-js-tests
  - validate-package
  - deploy-package
  - run-unit-tests
  - run-api-tests
  - run-ui-tests
  - integration

####################################################
# Builds the Metadata Package, builds the Package
# files and Destructive changes
####################################################
build-metadata-package:
  stage: build-metadata-package
  except:
    ...

Push and pray 🙏

Developer environment

brew install go
brew install golangci-lint

make build
make test
make lint
  • brew vs nix vs golang.org
  • versions?
  • BSD vs GNU (make, sed, etc)

CI/CD environment

- uses: actions/setup-go@v5
  with:
    go-version: "1.24.0"

- run: go build .
- run: go test -race -v ./…

- uses: golangci/golangci-lint-action@v7
  with:
    version: "v2.0.0"- uses: actions/setup-go@v5
  with:
    go-version: "1.24.0"

- run: go build .
- run: go test -race -v ./…

- uses: golangci/golangci-lint-action@v7
  with:
    version: "v2.0.0"

We are still dealing with drift in 2025?!

  • custom, vendor-specific format

All is well until you need to make changes

  • Upgrades (eg. new version of Go)
  • New tooling (eg. new security scanner)
  • Moving to a new platform
  • company gets acquired and needs to move to the new parent company’s platform

Lessons learned

YAML…

  • is not reusable 1
  • is not composable
  • provides poor flow control
  • is not portable

YAML is a poor choice of “language” for software development workflows.

  1. Anchors don’t count

CI/CD is just an interface

  • Developer and CI environments overlap
  • Drift between them is annoying
  • Time wasted due to “push and pray”
  • CI/CD is no longer a dev or platform only domain

Dev + CI = Software development workflows

  • even if they don’t overlap, they should -> run locally

No more YAML

  • Use a general-purpose programming language
  • One that developers/platform engineers already know
  • Reusable components

Workflows that run anywhere

  • Run CI locally
  • No more push and pray
  • No more drift between dev and CI
  • Bridge between developers and platform engineers
  • maximize reuse between dev and CI

Workshop

Let’s get our hands dirty!

Workshop environment

  • Use your own machine
  • Use the online playground
Scan me!

skm.li/cndro25/play

Prerequisites

  • Make sure Docker is installed and running.
  • Make sure Go is installed.
  • Install the latest Dagger CLI.
  • Make sure you have a GitHub account set up with SSH keys.
  • Last, but not least: you’ll need your favorite text editor or IDE.

Workshop materials

https://github.com/sagikazarmark/workshop-cnd-romania-2025

skm.li/cndro25

Real world exampes

github.com/openmeterio/openmeter

github.com/twirphp/twirp

Feedback

Scan me!

https://forms.gle/ffDQhySWwfUByZAWA

skm.li/cndro25/feedback

Thank you

Any questions?



@sagikazarmark

https://sagikazarmark.com

hello@sagikazarmark.com

Accelerate Your Development and CI/CD Pipelines with Dagger Márk Sági-Kazár 2025-05-05 @ Cloud Native Days Romania

  1. Slides

  2. Tools

  3. Close
  • Accelerate Your Development and CI/CD Pipelines with Dagger
  • whoami
  • Agenda
  • CI/CD today
  • Day 1…
  • Day 101…
  • Push and pray 🙏...
  • Developer environment
  • CI/CD environment
  • All is well until you need to make changes
  • Lessons learned
  • YAML…
  • CI/CD is just an interface
  • Slide 14
  • No more YAML
  • Workflows that run anywhere
  • Workshop
  • Workshop environment
  • Prerequisites
  • Workshop materials
  • Real world exampes
  • Feedback
  • Thank you
  • f Fullscreen
  • s Speaker View
  • o Slide Overview
  • e PDF Export Mode
  • ? Keyboard Help