Compare commits
5 Commits
Author | SHA1 | Date | |
---|---|---|---|
e320d8fbd5 | |||
2d28ce7415 | |||
fd64c77aed | |||
aeaf755d08 | |||
667f52f33b |
54
.github/workflows/release.yaml
vendored
54
.github/workflows/release.yaml
vendored
@@ -23,7 +23,11 @@ jobs:
|
|||||||
|
|
||||||
- name: Git Version
|
- name: Git Version
|
||||||
id: version
|
id: version
|
||||||
uses: codacy/git-version@2.7.1
|
uses: paulhatch/semantic-version@v5.3.0
|
||||||
|
with:
|
||||||
|
tag_prefix: ''
|
||||||
|
major_pattern: 'breaking:'
|
||||||
|
minor_pattern: 'feature:'
|
||||||
|
|
||||||
build-nuget:
|
build-nuget:
|
||||||
name: Build and Publish Nuget
|
name: Build and Publish Nuget
|
||||||
@@ -38,6 +42,19 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
dotnet-version: '8.0.x'
|
dotnet-version: '8.0.x'
|
||||||
|
|
||||||
|
- name: Intall mono
|
||||||
|
run: |
|
||||||
|
curl -fsSL https://download.mono-project.com/repo/xamarin.gpg | gpg --dearmor -o /usr/share/keyrings/mono-official-stable.gpg
|
||||||
|
echo "deb [signed-by=/usr/share/keyrings/mono-official-stable.gpg] https://download.mono-project.com/repo/ubuntu stable-focal main" > /etc/apt/sources.list.d/mono-official-stable.list
|
||||||
|
apt-get update
|
||||||
|
apt-get install -y --no-install-recommends apt-transport-https mono-complete
|
||||||
|
|
||||||
|
|
||||||
|
- uses: nuget/setup-nuget@v1
|
||||||
|
name: Setup nuget cli
|
||||||
|
with:
|
||||||
|
nuget-version: '5.x'
|
||||||
|
|
||||||
- name: Restore dependencies
|
- name: Restore dependencies
|
||||||
run: dotnet restore Torch.Server/Torch.Server.csproj --locked-mode
|
run: dotnet restore Torch.Server/Torch.Server.csproj --locked-mode
|
||||||
|
|
||||||
@@ -59,11 +76,11 @@ jobs:
|
|||||||
SLEET_FEED_SERVICEURL: https://storage.yandexcloud.net
|
SLEET_FEED_SERVICEURL: https://storage.yandexcloud.net
|
||||||
SLEET_FEED_ACCESSKEYID: ${{ secrets.S3_KEY_ID }}
|
SLEET_FEED_ACCESSKEYID: ${{ secrets.S3_KEY_ID }}
|
||||||
SLEET_FEED_SECRETACCESSKEY: ${{ secrets.S3_KEY }}
|
SLEET_FEED_SECRETACCESSKEY: ${{ secrets.S3_KEY }}
|
||||||
run: sleet push ./pack
|
run: /root/.dotnet/tools/sleet push ./pack
|
||||||
|
|
||||||
build:
|
build:
|
||||||
name: Build and Publish Package
|
name: Build and Publish Package
|
||||||
runs-on: windows-latest
|
runs-on: ubuntu-latest
|
||||||
needs: [get-version]
|
needs: [get-version]
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@master
|
- uses: actions/checkout@master
|
||||||
@@ -84,32 +101,15 @@ jobs:
|
|||||||
name: Zip Release
|
name: Zip Release
|
||||||
with:
|
with:
|
||||||
files: publish/
|
files: publish/
|
||||||
dest: release.zip
|
dest: torch-server.zip
|
||||||
|
|
||||||
- name: Create release
|
- name: Create Release
|
||||||
id: create_release
|
uses: akkuman/gitea-release-action@v1
|
||||||
uses: actions/create-release@v1
|
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
NODE_OPTIONS: '--experimental-fetch' # if nodejs < 18
|
||||||
with:
|
with:
|
||||||
tag_name: ${{ needs.get-version.outputs.version }}
|
tag_name: ${{ needs.get-version.outputs.version }}
|
||||||
release_name: Release v${{ needs.get-version.outputs.version }}
|
name: Release v${{ needs.get-version.outputs.version }}
|
||||||
body: ${{ steps.github_release.outputs.changelog }}
|
body: ${{ steps.github_release.outputs.changelog }}
|
||||||
draft: true
|
files: |-
|
||||||
prerelease: false
|
./torch-server.zip
|
||||||
|
|
||||||
- name: Upload release asset
|
|
||||||
uses: actions/upload-release-asset@v1
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
with:
|
|
||||||
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
|
||||||
asset_path: release.zip
|
|
||||||
asset_name: torch-server.zip
|
|
||||||
asset_content_type: application/zip
|
|
||||||
|
|
||||||
- uses: eregon/publish-release@v1
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
with:
|
|
||||||
release_id: ${{ steps.create_release.outputs.id }}
|
|
Reference in New Issue
Block a user