Skip to content

Commit

Permalink
simplify github actions workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
seriousben committed Dec 18, 2024
1 parent 9730d83 commit a59f6e9
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 163 deletions.
55 changes: 0 additions & 55 deletions .github/workflows/generate.yml

This file was deleted.

99 changes: 3 additions & 96 deletions .github/workflows/publish_indexify_server.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,97 +27,8 @@ defaults:
working-directory: ./server

jobs:
build-linux-amd64-package:
name: Build x86_64 Linux Package
runs-on: ubuntu-latest-xlarge
steps:
- uses: actions/checkout@v4
- run: rustup toolchain install nightly --component rustfmt
- run: cargo +nightly fmt --check
- run: cargo install cargo-deb
- run: make build-release
- run: cargo deb --no-build --no-strip --target x86_64-unknown-linux-gnu
- uses: actions/upload-artifact@v4
with:
name: indexify-server-linux-amd64
path: server/target/x86_64-unknown-linux-gnu/release/indexify-server
if-no-files-found: error
- uses: actions/upload-artifact@v4
with:
name: indexify-server-deb-linux-amd64
path: server/target/x86_64-unknown-linux-gnu/debian/indexify-server_*.deb
if-no-files-found: error

build-linux-arm64-package:
name: Build Aarch64 Linux Package
runs-on: ubuntu-latest-xlarge
steps:
- uses: actions/checkout@v4
- run: rustup toolchain install nightly --component rustfmt
- run: cargo +nightly fmt --check
- run: make build-release-aarch64
- run: cargo install cargo-deb
- run: cargo deb --no-build --no-strip --target aarch64-unknown-linux-gnu
- uses: actions/upload-artifact@v4
with:
name: indexify-server-linux-aarch64
path: server/target/aarch64-unknown-linux-gnu/release/indexify-server
if-no-files-found: error
- uses: actions/upload-artifact@v4
with:
name: indexify-server-deb-linux-aarch64
path: server/target/aarch64-unknown-linux-gnu/debian/indexify-server_*.deb
if-no-files-found: error

build-macos-package:
name: Build macOS Package
runs-on: macos-14-xlarge
steps:
- uses: actions/checkout@v4
- run: rustup update
- run: rustup toolchain install nightly --component rustfmt
- run: rustup target add aarch64-apple-darwin
- run: cargo +nightly fmt --check
- run: make package-ui
- run: cargo build --release
- uses: actions/upload-artifact@v4
with:
name: indexify-server-darwin-arm64
path: server/target/release/indexify-server
if-no-files-found: error

# build-macos-package-x86:
# name: Build macOS Package
# runs-on: macos-12
# steps:
# - uses: actions/checkout@v4
# - run: rustup update
# - run: rustup toolchain install nightly --component rustfmt
# - run: cargo +nightly fmt --check
# - run: make package-ui
# - run: cargo build --release
# - uses: actions/upload-artifact@v4
# with:
# name: indexify-server-darwin-amd64
# path: server/target/release/indexify-server
# if-no-files-found: error

# build-windows-package:
# name: Build Windows Package
# runs-on: windows-latest-large
# steps:
# - uses: actions/checkout@v4
# - uses: ilammy/setup-nasm@v1
# - run: rustup toolchain install nightly --component rustfmt
# - run: cargo +nightly fmt --check
# - run: choco install protoc
# - run: make package-ui
# - run: cargo build --release
# - uses: actions/upload-artifact@v4
# with:
# name: indexify-server-windows-amd64.exe
# path: server/target/release/indexify-server.exe
# if-no-files-found: error
build-release-packages:
uses: ./.github/workflows/wf_build_indexify_server_release_packages.yaml

extract-version:
name: Extract Version Number
Expand All @@ -133,11 +44,7 @@ jobs:
name: Create GitHub Release
runs-on: ubuntu-latest
needs:
- build-linux-amd64-package
- build-linux-arm64-package
# - build-windows-package
- build-macos-package
# - build-macos-package-x86
- build-release-packages
- extract-version
steps:
- uses: actions/checkout@v4
Expand Down
7 changes: 6 additions & 1 deletion .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -288,4 +288,9 @@ jobs:
if pgrep -f indexify; then
echo "Error: Some Indexify processes are still running."
exit 1
fi
fi
build_release_packages:
name: Test Building Release Packages
needs: [acceptance_tests, build_server]
uses: ./.github/workflows/wf_build_indexify_server_release_packages.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,7 @@
name: Test - Build Docker Indexify Server
name: Build Indexify Server Release Packages

on:
push:
branches:
- 'main'
pull_request:
branches:
- 'main'
paths:
- 'server/**'
- '.github/workflows/test_build_docker_indexify_server_workflow.yaml'
workflow_call:

env:
CARGO_TERM_COLOR: always
Expand Down Expand Up @@ -76,4 +68,36 @@ jobs:
with:
name: indexify-server-darwin-arm64
path: server/target/release/indexify-server
if-no-files-found: error
if-no-files-found: error

# build-macos-package-x86:
# name: Build macOS Package
# runs-on: macos-12
# steps:
# - uses: actions/checkout@v4
# - run: rustup update
# - run: rustup toolchain install nightly --component rustfmt
# - run: cargo +nightly fmt --check
# - run: make package-ui
# - run: cargo build --release
# - uses: actions/upload-artifact@v4
# with:
# name: indexify-server-darwin-amd64
# path: server/target/release/indexify-server
# if-no-files-found: error

# build-windows-package:
# name: Build Windows Package
# runs-on: windows-latest-large
# steps:
# - uses: actions/checkout@v4
# - uses: ilammy/setup-nasm@v1
# - run: rustup toolchain install nightly --component rustfmt
# - run: cargo +nightly fmt --check
# - run: make package-ui
# - run: cargo build --release
# - uses: actions/upload-artifact@v4
# with:
# name: indexify-server-windows-amd64.exe
# path: server/target/release/indexify-server.exe
# if-no-files-found: error

0 comments on commit a59f6e9

Please sign in to comment.