Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add workflow for easy to use servers. #500

Merged
merged 1 commit into from
Dec 14, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
84 changes: 84 additions & 0 deletions .github/workflows/cd-build-upload-artifact.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
# Action to create easy to use servers for players to test things without compiling the entire repo

name: Create server bundle

concurrency:
group: publish

on:
push:
branches: [ master, staging, trying ]

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Install dependencies
run: sudo apt-get install -y python3-paramiko python3-lxml

- uses: actions/checkout@v3.6.0
with:
submodules: 'recursive'
- name: Setup .NET Core
uses: actions/setup-dotnet@v3.2.0
with:
dotnet-version: 8.0.x

- name: Get Engine Tag
run: |
cd RobustToolbox
git fetch --depth=1

- name: Install dependencies
run: dotnet restore

- name: Build Packaging
run: dotnet build Content.Packaging --configuration Release --no-restore /m

- name: Package server
run: dotnet run --project Content.Packaging server --platform win-x64 --platform linux-x64 --platform osx-x64

- name: Package client
run: dotnet run --project Content.Packaging client --no-wipe-release

- name: Bundle client
run: |
pushd release
mkdir linux
mv SS14.Server_linux-x64.zip linux
pushd linux
unzip SS14.Server_linux-x64.zip
rm SS14.Server_linux-x64.zip
cp ../SS14.Client.zip Content.Client.zip
popd
mkdir osx
mv SS14.Server_osx-x64.zip osx
pushd osx
unzip SS14.Server_osx-x64.zip
rm SS14.Server_osx-x64.zip
cp ../SS14.Client.zip Content.Client.zip
popd
mkdir win
mv SS14.Server_win-x64.zip win
pushd win
unzip SS14.Server_win-x64.zip
rm SS14.Server_win-x64.zip
cp ../SS14.Client.zip Content.Client.zip
popd
popd

- uses: actions/upload-artifact@v4
with:
name: Cosmatic.ServerBundle-linux-x64.zip
path: release/linux

- uses: actions/upload-artifact@v4
with:
name: Cosmatic.ServerBundle-osx-x64.zip
path: release/osx

- uses: actions/upload-artifact@v4
with:
name: Cosmatic.ServerBundle-windows-x64.zip
path: release/win
Loading