Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master' into buffer-0.14
Browse files Browse the repository at this point in the history
  • Loading branch information
Hiroshiba committed Oct 7, 2023
2 parents 8778b13 + 429ecec commit 0b99927
Show file tree
Hide file tree
Showing 41 changed files with 1,933 additions and 1,326 deletions.
30 changes: 24 additions & 6 deletions .github/workflows/build-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ env:
VOICEVOX_RESOURCE_VERSION: "0.14.4"
VOICEVOX_CORE_VERSION: "0.14.5"

defaults:
run:
shell: bash

jobs:
config: # 全 jobs で利用する定数の定義. `env` が利用できないコンテキストでも利用できる.
runs-on: ubuntu-latest
Expand All @@ -26,7 +30,6 @@ jobs:
steps:
- name: declare variables
id: vars
shell: bash
run: |
: # releaseタグ名か、workflow_dispatchでのバージョン名か、latestが入る
echo "version_or_latest=${{ github.event.release.tag_name || github.event.inputs.version || 'latest' }}" >> $GITHUB_OUTPUT
Expand Down Expand Up @@ -67,13 +70,13 @@ jobs:
- tag: nvidia
target: runtime-nvidia-env
base_image: ubuntu:20.04
base_runtime_image: nvidia/cuda:11.6.2-cudnn8-runtime-ubuntu20.04
base_runtime_image: nvidia/cuda:11.8.0-cudnn8-runtime-ubuntu20.04
onnxruntime_version: 1.13.1
platforms: linux/amd64
- tag: nvidia-ubuntu20.04
target: runtime-nvidia-env
base_image: ubuntu:20.04
base_runtime_image: nvidia/cuda:11.6.2-cudnn8-runtime-ubuntu20.04
base_runtime_image: nvidia/cuda:11.8.0-cudnn8-runtime-ubuntu20.04
onnxruntime_version: 1.13.1
platforms: linux/amd64

Expand Down Expand Up @@ -111,7 +114,6 @@ jobs:

# Merge VOICEVOX RESOURCE
- name: Merge VOICEVOX RESOURCE
shell: bash
env:
DOWNLOAD_RESOURCE_PATH: download/resource
run: bash build_util/process_voicevox_resource.bash
Expand All @@ -126,6 +128,22 @@ jobs:
format('{0}:{1}-{2}', env.IMAGE_NAME, matrix.tag, needs.config.outputs.version_or_latest)
) || format('{0}:{1}', env.IMAGE_NAME, needs.config.outputs.version_or_latest)
) }}
IMAGE_CACHE_FROM:
|- # Always use the `latest` buildcache. :latest-buildcache or :{tag}-latest-buildcache
${{ (
matrix.tag != '' && (
format('type=registry,ref={0}:{1}-latest-buildcache', env.IMAGE_NAME, matrix.tag)
) || format('type=registry,ref={0}:latest-buildcache', env.IMAGE_NAME)
) }}
IMAGE_CACHE_TO:
|- # If it's a release, do not create buildcache, otherwise create the `latest` buildcache. :latest-buildcache or :{tag}-latest-buildcache
${{ (
needs.config.outputs.version_or_latest == 'latest' && (
matrix.tag != '' && (
format('type=registry,ref={0}:{1}-latest-buildcache,mode=max', env.IMAGE_NAME, matrix.tag)
) || format('type=registry,ref={0}:latest-buildcache,mode=max', env.IMAGE_NAME)
) || ''
) }}
with:
context: .
builder: ${{ steps.buildx.outputs.name }}
Expand All @@ -142,8 +160,8 @@ jobs:
target: ${{ matrix.target }}
push: true
tags: ${{ env.IMAGE_TAG }}
cache-from: type=registry,ref=${{ env.IMAGE_TAG }}-buildcache
cache-to: type=registry,ref=${{ env.IMAGE_TAG }}-buildcache,mode=max
cache-from: ${{ env.IMAGE_CACHE_FROM }}
cache-to: ${{ env.IMAGE_CACHE_TO }}
platforms: ${{ matrix.platforms }}

run-release-test-workflow:
Expand Down
Loading

0 comments on commit 0b99927

Please sign in to comment.