Skip to content

Merge pull request #18 from warpdotdev/lili/add-uv-to-base #17

Merge pull request #18 from warpdotdev/lili/add-uv-to-base

Merge pull request #18 from warpdotdev/lili/add-uv-to-base #17

Workflow file for this run

name: Build and Push Dev Images
on:
push:
branches:
- main
workflow_dispatch:
inputs:
image:
description: 'Image to build (leave empty for all)'
required: false
type: choice
options:
- ''
- base
- bun
- node
- go
- rust
- java
- dotnet
- ruby
- web
- full
version:
description: 'Version override (only used when single image selected)'
required: false
type: string
tag:
description: 'Tag override (only used when single image selected)'
required: false
type: string
env:
REGISTRY: docker.io
jobs:
build-matrix:
name: ${{ matrix.repo }}:${{ inputs.image == matrix.key && inputs.tag || matrix.tag }}
runs-on: namespace-profile-ubuntu-small
strategy:
fail-fast: false
matrix:
include:
# Base image (Node + Python only)
- repo: dev-base
key: base
tag: "latest"
platforms: "linux/amd64,linux/arm64"
languages: "python,javascript"
# Bun
- repo: dev-bun
key: bun
tag: "1.3"
bun: "true"
bun_version: "1.3.9"
languages: ""
# Node (Node + Python)
- repo: dev-node
key: node
tag: "22"
node_version: "22.0.0"
platforms: "linux/amd64,linux/arm64"
languages: "javascript,python"
# Go
- repo: dev-go
key: go
tag: "1.23"
go: "true"
go_version: "1.23.4"
platforms: "linux/amd64,linux/arm64"
languages: "go,golang"
# Rust
- repo: dev-rust
key: rust
tag: "1.83"
rust: "true"
rust_version: "1.83.0"
platforms: "linux/amd64,linux/arm64"
languages: "rust"
- repo: dev-rust
key: rust
tag: "1.85"
rust: "true"
rust_version: "1.85.0"
platforms: "linux/amd64,linux/arm64"
languages: "rust"
# Java
- repo: dev-java
key: java
tag: "21"
java: "true"
java_version: "21"
platforms: "linux/amd64,linux/arm64"
languages: "java"
# .NET
- repo: dev-dotnet
key: dotnet
tag: "8.0"
dotnet: "true"
dotnet_version: "8.0"
platforms: "linux/amd64,linux/arm64"
languages: "dotnet,csharp,fsharp,visualbasic"
# Ruby
- repo: dev-ruby
key: ruby
tag: "3.3"
ruby: "true"
ruby_version: "3.3"
platforms: "linux/amd64,linux/arm64"
languages: "ruby"
# Web (browsers - amd64 only, Chrome/Firefox packages are x86_64)
- repo: dev-web
key: web
tag: "latest"
browsers: "true"
platforms: "linux/amd64"
languages: "html,css,javascript"
# Full image with all languages
- repo: dev-full
key: full
tag: "latest"
bun: "true"
bun_version: "1.3.9"
go: "true"
go_version: "1.23.4"
rust: "true"
rust_version: "1.85.0"
java: "true"
java_version: "21"
dotnet: "true"
dotnet_version: "8.0"
ruby: "true"
ruby_version: "3.3"
platforms: "linux/amd64,linux/arm64"
languages: "go,golang,rust,java,dotnet,csharp,fsharp,visualbasic,ruby,python,javascript"
steps:
- uses: actions/checkout@v4
if: ${{ inputs.image == '' || inputs.image == matrix.key }}
- name: Login to DockerHub
if: ${{ inputs.image == '' || inputs.image == matrix.key }}
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
if: ${{ inputs.image == '' || inputs.image == matrix.key }}
uses: docker/build-push-action@v6
with:
context: .
file: ./Dockerfile
sbom: true
provenance: mode=max
push: true
platforms: ${{ matrix.platforms }}
tags: warpdotdev/${{ matrix.repo }}:${{ inputs.tag || matrix.tag }}
build-args: |
INSTALL_BUN=${{ matrix.bun || 'false' }}
INSTALL_RUST=${{ matrix.rust || 'false' }}
INSTALL_GO=${{ matrix.go || 'false' }}
INSTALL_JAVA=${{ matrix.java || 'false' }}
INSTALL_DOTNET=${{ matrix.dotnet || 'false' }}
INSTALL_RUBY=${{ matrix.ruby || 'false' }}
INSTALL_BROWSERS=${{ matrix.browsers || 'false' }}
INSTALL_CODING_AGENTS=false
BUN_VERSION=${{ matrix.key == 'bun' && inputs.version || matrix.bun_version || '1.3.9' }}
NODE_VERSION=${{ matrix.key == 'node' && inputs.version || matrix.node_version || '24.0.0' }}
GO_VERSION=${{ matrix.key == 'go' && inputs.version || matrix.go_version || '1.23.4' }}
RUST_VERSION=${{ matrix.key == 'rust' && inputs.version || matrix.rust_version || '1.85.0' }}
JAVA_VERSION=${{ matrix.key == 'java' && inputs.version || matrix.java_version || '21' }}
DOTNET_VERSION=${{ matrix.key == 'dotnet' && inputs.version || matrix.dotnet_version || '8.0' }}
RUBY_VERSION=${{ matrix.key == 'ruby' && inputs.version || matrix.ruby_version || '3.3' }}
LANGUAGES=${{ matrix.languages || '' }}
- name: Build and push (agents variant)
if: ${{ inputs.image == '' || inputs.image == matrix.key }}
uses: docker/build-push-action@v6
with:
context: .
file: ./Dockerfile
sbom: true
provenance: mode=max
push: true
platforms: ${{ matrix.platforms }}
tags: warpdotdev/${{ matrix.repo }}:${{ inputs.tag || matrix.tag }}-agents
build-args: |
INSTALL_BUN=${{ matrix.bun || 'false' }}
INSTALL_RUST=${{ matrix.rust || 'false' }}
INSTALL_GO=${{ matrix.go || 'false' }}
INSTALL_JAVA=${{ matrix.java || 'false' }}
INSTALL_DOTNET=${{ matrix.dotnet || 'false' }}
INSTALL_RUBY=${{ matrix.ruby || 'false' }}
INSTALL_BROWSERS=${{ matrix.browsers || 'false' }}
INSTALL_CODING_AGENTS=true
BUN_VERSION=${{ matrix.key == 'bun' && inputs.version || matrix.bun_version || '1.3.9' }}
NODE_VERSION=${{ matrix.key == 'node' && inputs.version || matrix.node_version || '24.0.0' }}
GO_VERSION=${{ matrix.key == 'go' && inputs.version || matrix.go_version || '1.23.4' }}
RUST_VERSION=${{ matrix.key == 'rust' && inputs.version || matrix.rust_version || '1.85.0' }}
JAVA_VERSION=${{ matrix.key == 'java' && inputs.version || matrix.java_version || '21' }}
DOTNET_VERSION=${{ matrix.key == 'dotnet' && inputs.version || matrix.dotnet_version || '8.0' }}
RUBY_VERSION=${{ matrix.key == 'ruby' && inputs.version || matrix.ruby_version || '3.3' }}
LANGUAGES=${{ matrix.languages || '' }}