Skip to content

github-workflows-dojo360-scala-ci

Build, test, and scan Scala (SBT) apps using the recommended UHG reusable CI workflow, with optional publish and container builds

active
IDE:
claude
codex
vscode
Version:
1.0.0
Owner:pcorazao
github-actions
workflow
dojo360

Scala CI Workflow Skill

Overview

This skill covers Scala + SBT CI patterns for build/test/scans, optional publish, and optional container builds.

The Dojo360 workflow (scala-sbt-ci.yml) exists, but for new implementations the recommended approach is to use the UHG CI Workflows reusable workflow from uhg-pipelines/ci-workflows.

Workflow Reference

Recommended (Use This)

Repository: uhg-pipelines/ci-workflows
Workflow: .github/workflows/scala-sbt-ci.yml@v2

Legacy (Dojo360)

Repository: dojo360/pipelines-workflows
Workflow: .github/workflows/scala-sbt-ci.yml
Docs: https://github.com/dojo360/pipelines-workflows/tree/main/web/scala-sbt-ci/index.md

Key Features

  • Runs SBT build + unit tests
  • Artifactory integration via jfrog-project-key
  • Optional SBT publish (workflow/input dependent)
  • Optional Docker build/publish if you pass Docker inputs

Prerequisites

  • Scala/SBT project in the repo (for example: build.sbt and project/)
  • Artifactory project/repositories provisioned
  • If building containers:
    • Dockerfile must use Optum golden images (no public base images)
    • Runner must have Docker available

Common Inputs (UHG reusable workflow)

InputTypeDescription
jfrog-project-keystringJFrog project key (routes to correct SaaS Artifactory repos)
working-directorystringWhere your SBT project lives (default: .)
java-versionstringJava version for the build (example: 11 or 17)
java-distributionstringJava distribution (example: temurin)
sbt-build-jvm-argsstringJVM args for SBT build (example: -Xmx2g -XX:+UseG1GC)
sbt-build-commandstringSBT build command (example: clean test or clean test stage)
sbt-publish-commandstringSBT publish command (example: publish)
publish-versionstringVersion used for publishing artifacts (if publish is enabled)
docker-tagsstringImage tag(s) to publish when doing Docker builds
docker-contextstringDocker build context
docker-dockerfilestringDockerfile path

Secrets

UHG reusable workflows typically handle Artifactory auth via OIDC + EPL actions, but you may still need:

  • Repo/org secrets required by your org’s scanning configuration
  • Any publish- or deploy-time secrets required by your platform

Templates

See ready-to-copy examples in .github/skills/github-workflows-dojo360-scala-ci/templates/:

  • basic-scala-sbt-ci.yml
  • scala-sbt-ci-with-version-tag.yml
  • scala-sbt-ci-with-docker-build.yml

Notes / Gotchas

  • Use a pinned Java version and distribution for reproducibility.
  • If you build container images, ensure your Dockerfile uses Optum golden images (see .github/instructions/docker.instructions.md).

Related Assets