Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: build vllm-rocm #1

Open
wants to merge 1 commit into
base: cohere
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 42 additions & 0 deletions .github/workflows/build-and-push.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: build-and-push

on:
push:
tags:
- 'v*.*.*.*'

jobs:
build-and-push:
permissions:
contents: read
id-token: write
runs-on: xlarge
steps:
- uses: actions/checkout@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: gcp auth
id: auth
uses: google-github-actions/auth@v1
with:
token_format: access_token
workload_identity_provider: projects/751739702614/locations/global/workloadIdentityPools/githubdocker/providers/githubactions
service_account: [email protected]

- name: 'Set up Cloud SDK'
uses: 'google-github-actions/setup-gcloud@v2'
with:
version: '>= 363.0.0'

- name: 🔒 authenticate docker
run: gcloud auth configure-docker us-central1-docker.pkg.dev

- name: set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV

- name: build image
shell: bash
run: |
IMAGE_TAG=${{ env.RELEASE_VERSION }} make push
3 changes: 1 addition & 2 deletions Dockerfile.rocm
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# default base image
ARG BASE_IMAGE="rocm/pytorch:rocm6.2_ubuntu20.04_py3.9_pytorch_release_2.3.0"
ARG BASE_IMAGE="rocm/pytorch:rocm6.2_ubuntu22.04_py3.9_pytorch_release_2.2.1"

ARG COMMON_WORKDIR=/app

Expand Down Expand Up @@ -272,4 +272,3 @@ ENV TOKENIZERS_PARALLELISM=false
ENV HIP_FORCE_DEV_KERNARG=1

CMD ["/bin/bash"]

11 changes: 11 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
IMAGE_NAME ?= us-central1-docker.pkg.dev/cohere-artifacts/cohere/vllm-rocm
IMAGE_TAG ?= $(shell git rev-parse HEAD)

build:
@DOCKER_BUILDKIT=1 docker build \
-t ${IMAGE_NAME}:${IMAGE_TAG} \
-f Dockerfile.rocm \
.

push: build
@docker push ${IMAGE_NAME}:${IMAGE_TAG}
Loading