mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-09-22 06:00:56 +02:00
🐳 hotfix: Tag Images Workflow Update (#2272)
This commit is contained in:
parent
8b3f80fe24
commit
1605ef3793
3 changed files with 7 additions and 92 deletions
88
.github/workflows/latest-images-main.yml
vendored
88
.github/workflows/latest-images-main.yml
vendored
|
@ -1,88 +0,0 @@
|
||||||
name: Docker Compose Build Latest Tag (Manual Dispatch)
|
|
||||||
|
|
||||||
# The workflow is manually triggered
|
|
||||||
on:
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
|
|
||||||
steps:
|
|
||||||
# Check out the repository
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
# Fetch all tags and set the latest tag
|
|
||||||
- name: Fetch tags and set the latest tag
|
|
||||||
run: |
|
|
||||||
git fetch --tags
|
|
||||||
echo "LATEST_TAG=$(git describe --tags `git rev-list --tags --max-count=1`)" >> $GITHUB_ENV
|
|
||||||
|
|
||||||
# Set up Docker
|
|
||||||
- name: Set up Docker
|
|
||||||
uses: docker/setup-buildx-action@v3
|
|
||||||
|
|
||||||
# Set up QEMU
|
|
||||||
- name: Set up QEMU
|
|
||||||
uses: docker/setup-qemu-action@v3
|
|
||||||
|
|
||||||
# Log in to GitHub Container Registry
|
|
||||||
- name: Log in to GitHub Container Registry
|
|
||||||
uses: docker/login-action@v2
|
|
||||||
with:
|
|
||||||
registry: ghcr.io
|
|
||||||
username: ${{ github.actor }}
|
|
||||||
password: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
|
|
||||||
# Prepare Docker Build
|
|
||||||
- name: Build Docker images
|
|
||||||
run: cp .env.example .env
|
|
||||||
|
|
||||||
# Docker metadata for librechat-api
|
|
||||||
- name: Docker metadata for librechat-api
|
|
||||||
id: meta-librechat-api
|
|
||||||
uses: docker/metadata-action@v5
|
|
||||||
with:
|
|
||||||
images: ghcr.io/${{ github.repository_owner }}/librechat-api
|
|
||||||
tags: |
|
|
||||||
type=raw,value=${{ env.LATEST_TAG }},enable=true
|
|
||||||
type=raw,value=latest,enable=true
|
|
||||||
type=semver,pattern={{version}}
|
|
||||||
type=semver,pattern={{major}}
|
|
||||||
type=semver,pattern={{major}}.{{minor}}
|
|
||||||
|
|
||||||
# Build and push librechat-api
|
|
||||||
- name: Build and push librechat-api
|
|
||||||
uses: docker/build-push-action@v5
|
|
||||||
with:
|
|
||||||
file: Dockerfile.multi
|
|
||||||
context: .
|
|
||||||
push: true
|
|
||||||
tags: ${{ steps.meta-librechat-api.outputs.tags }}
|
|
||||||
platforms: linux/amd64,linux/arm64
|
|
||||||
target: api-build
|
|
||||||
|
|
||||||
# Docker metadata for librechat
|
|
||||||
- name: Docker metadata for librechat
|
|
||||||
id: meta-librechat
|
|
||||||
uses: docker/metadata-action@v5
|
|
||||||
with:
|
|
||||||
images: ghcr.io/${{ github.repository_owner }}/librechat
|
|
||||||
tags: |
|
|
||||||
type=raw,value=${{ env.LATEST_TAG }},enable=true
|
|
||||||
type=raw,value=latest,enable=true
|
|
||||||
type=semver,pattern={{version}}
|
|
||||||
type=semver,pattern={{major}}
|
|
||||||
type=semver,pattern={{major}}.{{minor}}
|
|
||||||
|
|
||||||
# Build and push librechat
|
|
||||||
- name: Build and push librechat
|
|
||||||
uses: docker/build-push-action@v5
|
|
||||||
with:
|
|
||||||
file: Dockerfile
|
|
||||||
context: .
|
|
||||||
push: true
|
|
||||||
tags: ${{ steps.meta-librechat.outputs.tags }}
|
|
||||||
platforms: linux/amd64,linux/arm64
|
|
||||||
target: node
|
|
9
.github/workflows/main-image-workflow.yml
vendored
9
.github/workflows/main-image-workflow.yml
vendored
|
@ -25,12 +25,15 @@ jobs:
|
||||||
git fetch --tags
|
git fetch --tags
|
||||||
echo "LATEST_TAG=$(git describe --tags `git rev-list --tags --max-count=1`)" >> $GITHUB_ENV
|
echo "LATEST_TAG=$(git describe --tags `git rev-list --tags --max-count=1`)" >> $GITHUB_ENV
|
||||||
|
|
||||||
- name: Set up Docker
|
# Set up QEMU
|
||||||
uses: docker/setup-buildx-action@v3
|
|
||||||
|
|
||||||
- name: Set up QEMU
|
- name: Set up QEMU
|
||||||
uses: docker/setup-qemu-action@v3
|
uses: docker/setup-qemu-action@v3
|
||||||
|
|
||||||
|
# Set up Docker Buildx
|
||||||
|
- name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v3
|
||||||
|
|
||||||
|
# Log in to GitHub Container Registry
|
||||||
- name: Log in to GitHub Container Registry
|
- name: Log in to GitHub Container Registry
|
||||||
uses: docker/login-action@v2
|
uses: docker/login-action@v2
|
||||||
with:
|
with:
|
||||||
|
|
|
@ -3,7 +3,7 @@ name: Docker Images Build on Tag
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
tags:
|
tags:
|
||||||
- 'v*'
|
- '*'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
Loading…
Add table
Add a link
Reference in a new issue