Parameterize Jenkinsfile

This commit is contained in:
2026-06-01 21:30:35 -04:00
parent 56598542a5
commit 5c7e87289e
2 changed files with 10 additions and 8 deletions

View File

@@ -1,3 +1,2 @@
FROM vllm/vllm-openai:cu129-nightly
RUN sed -i 's/cute.arch.fmin/cutlass.min/g' /usr/local/lib/python3.12/dist-packages/vllm/models/deepseek_v4/nvidia/ops/sparse_attn_compress_cutedsl.py
ARG BASE_IMAGE=vllm/vllm-openai:nightly
FROM ${BASE_IMAGE}

13
Jenkinsfile vendored
View File

@@ -3,12 +3,13 @@ pipeline {
environment {
REGISTRY = 'atl.vultrcr.com/vllm'
IMAGE_NAME = 'vllm'
PLATFORMS = 'linux/amd64,linux/arm64'
}
parameters {
string(name: 'IMAGE_TAG', defaultValue: 'custom', description: 'Docker image tag')
string(name: 'BASE_IMAGE', defaultValue: '', description: 'Base image to build from')
string(name: 'NAME', defaultValue: 'vllm', description: 'Docker image name')
string(name: 'TAG', defaultValue: 'latest', description: 'Docker image tag')
string(name: 'PLATFORMS', defaultValue: 'linux/amd64,linux/arm64', description: 'Target platforms to build image for')
string(name: 'GIT_REPO', defaultValue: '', description: 'Git repository URL (optional, uses workspace if empty)')
string(name: 'GIT_BRANCH', defaultValue: 'master', description: 'Git branch to build')
}
@@ -27,12 +28,14 @@ pipeline {
stage('Build & Push') {
steps {
script {
def buildArg = params.BASE_IMAGE ? "--build-arg BASE_IMAGE=${params.BASE_IMAGE}" : ''
docker.withRegistry("https://${REGISTRY}", 'ATL_VCR_VLLM') {
sh """
docker buildx create --use --name vllm-builder || docker buildx use vllm-builder
docker buildx build \
--platform ${PLATFORMS} \
-t ${REGISTRY}/${IMAGE_NAME}:${params.IMAGE_TAG} \
--platform ${params.PLATFORMS} \
${buildArg} \
-t ${REGISTRY}/${params.NAME}:${params.TAG} \
--push \
.
"""