mirror of
https://github.com/huggingface/text-generation-inference.git
synced 2025-04-24 08:22:07 +00:00
Publish nix docker image.
This commit is contained in:
parent
a35fbdb925
commit
c9b267faa5
50
.github/workflows/nix_build.yaml
vendored
Normal file
50
.github/workflows/nix_build.yaml
vendored
Normal file
@ -0,0 +1,50 @@
|
|||||||
|
name: "Nix Tests"
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
paths:
|
||||||
|
- ".github/workflows/nix_build.yaml"
|
||||||
|
- "server/**"
|
||||||
|
- "proto/**"
|
||||||
|
- "router/**"
|
||||||
|
- "launcher/**"
|
||||||
|
- "nix/**"
|
||||||
|
- "Cargo.lock"
|
||||||
|
- "rust-toolchain.toml"
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
tests:
|
||||||
|
runs-on:
|
||||||
|
group: aws-highmemory-32-plus-priv
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- uses: cachix/install-nix-action@v27
|
||||||
|
with:
|
||||||
|
nix_path: nixpkgs=channel:nixos-unstable
|
||||||
|
- uses: cachix/cachix-action@v14
|
||||||
|
with:
|
||||||
|
name: text-generation-inference
|
||||||
|
# If you chose signing key for write access
|
||||||
|
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
|
||||||
|
env:
|
||||||
|
USER: github_runner
|
||||||
|
- name: Build
|
||||||
|
run: nix build .#dockerImage
|
||||||
|
- name: Initialize Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v3
|
||||||
|
with:
|
||||||
|
install: true
|
||||||
|
buildkitd-config: /tmp/buildkitd.toml
|
||||||
|
- name: Login to internal Container Registry
|
||||||
|
# if: github.event_name != 'pull_request'
|
||||||
|
uses: docker/login-action@v3
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.REGISTRY_USERNAME }}
|
||||||
|
password: ${{ secrets.REGISTRY_PASSWORD }}
|
||||||
|
registry: registry.internal.huggingface.tech
|
||||||
|
- name: Push to docker
|
||||||
|
run: |
|
||||||
|
docker load < ./result
|
||||||
|
docker tag tgi-docker registry.internal.huggingface.tech/api-inference/community/text-generation-inference:nix-test
|
Loading…
Reference in New Issue
Block a user