diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index 7ddd733d..707c3e8e 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -185,39 +185,3 @@ jobs: with: name: windows_x86_server_(debug) path: build/prefab/full/windows_x86_server - - make_sphinx_docs: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: '3.12' - - name: Setup project environment - run: make env - - name: Make the build - run: make docs-sphinx - - name: Upload the build - uses: actions/upload-artifact@v4 - with: - name: sphinx_html_docs - path: build/sphinx - - make_docker_image: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: '3.12' - - name: Setup project environment - run: make env - - name: Make the build - run: make docker-save - - name: Upload the build - uses: actions/upload-artifact@v4 - with: - name: docker_server(release) - path: build/docker/bombsquad_server_docker.tar \ No newline at end of file diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml new file mode 100644 index 00000000..d64062a5 --- /dev/null +++ b/.github/workflows/nightly.yml @@ -0,0 +1,42 @@ +name: Nightly Build +on: + # Run everyday at 5:30 UTC + schedule: + - cron: '30 5 * * *' + +jobs: + make_docker_image: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make docker-save + - name: Upload the build + uses: actions/upload-artifact@v4 + with: + name: docker_server(release) + path: build/docker/bombsquad_server_docker.tar + + make_sphinx_docs: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make docs-sphinx + - name: Upload the build + uses: actions/upload-artifact@v4 + with: + name: sphinx_html_docs + path: build/sphinx \ No newline at end of file diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 00000000..050ce036 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,247 @@ +name: Release + +on: + push: + tags: + - 'v*' + +jobs: + release_linux_x86_64_gui_debug_build: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v4 + - name: Setup Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make prefab-gui-debug-build + - name: Compress the build + run: tar -cf "linux_x86_64_gui_debug.tar" build/prefab/full/linux_x86_64_gui/ + - name: Upload the build + uses: ncipollo/release-action@v1 + with: + allowUpdates: true + artifacts: linux_x86_64_gui_debug.tar + + release_linux_x86_64_server_debug_build: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v4 + - name: Setup Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make prefab-server-debug-build + - name: Compress the build + run: tar -cf "linux_x86_64_server_debug.tar" build/prefab/full/linux_x86_64_server/ + - name: Upload the build + uses: ncipollo/release-action@v1 + with: + allowUpdates: true + artifacts: linux_x86_64_server_debug.tar + + release_linux_arm64_gui_debug_build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make prefab-linux-arm64-gui-debug-build + - name: Compress the build + run: tar -cf "linux_arm64_gui_debug.tar" build/prefab/full/linux_arm64_gui/ + - name: Upload the build + uses: ncipollo/release-action@v1 + with: + allowUpdates: true + artifacts: linux_arm64_gui_debug.tar + + release_linux_arm64_server_debug_build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make prefab-linux-arm64-server-debug-build + - name: Compress the build + run: tar -cf "linux_arm64_server_debug.tar" build/prefab/full/linux_arm64_server/ + - name: Upload the build + uses: ncipollo/release-action@v1 + with: + allowUpdates: true + artifacts: linux_arm64_server_debug.tar + + release_mac_x86_64_gui_debug_build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make prefab-mac-x86-64-gui-debug-build + - name: Compress the build + run: tar -cf "mac_x86_64_gui_debug.tar" build/prefab/full/mac_x86_64_gui/ + - name: Upload the build + uses: ncipollo/release-action@v1 + with: + allowUpdates: true + artifacts: mac_x86_64_gui_debug.tar + + release_mac_x86_64_server_debug_build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make prefab-mac-x86-64-server-debug-build + - name: Compress the build + run: tar -cf "mac_x86_64_server_debug.tar" build/prefab/full/mac_x86_64_server/ + - name: Upload the build + uses: ncipollo/release-action@v1 + with: + allowUpdates: true + artifacts: mac_x86_64_server_debug.tar + + release_mac_arm64_gui_debug_build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make prefab-mac-arm64-gui-debug-build + - name: Compress the build + run: tar -cf "mac_arm64_gui_debug.tar" build/prefab/full/mac_arm64_gui/ + - name: Upload the build + uses: ncipollo/release-action@v1 + with: + allowUpdates: true + artifacts: mac_arm64_gui_debug.tar + + release_mac_arm64_server_debug_build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make prefab-mac-arm64-server-debug-build + - name: Compress the build + run: tar -cf "mac_arm64_server_debug.tar" build/prefab/full/mac_arm64_server/ + - name: Upload the build + uses: ncipollo/release-action@v1 + with: + allowUpdates: true + artifacts: mac_arm64_server_debug.tar + + release_windows_x86_gui_debug_build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make prefab-windows-x86-gui-debug-build + - name: Compress the build + run: tar -cf "windows_x86_gui_debug.tar" build/prefab/full/windows_x86_gui/ + - name: Upload the build + uses: ncipollo/release-action@v1 + with: + allowUpdates: true + artifacts: windows_x86_gui_debug.tar + + release_windows_x86_server_debug_build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make prefab-windows-x86-server-debug-build + - name: Compress the build + run: tar -cf "windows_x86_server_debug.tar" build/prefab/full/windows_x86_server/ + - name: Upload the build + uses: ncipollo/release-action@v1 + with: + allowUpdates: true + artifacts: windows_x86_server_debug.tar + + release_docker_image: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make docker-save + - name: Upload the build + uses: ncipollo/release-action@v1 + with: + allowUpdates: true + artifacts: build/docker/bombsquad_server_docker.tar + + release_sphinx_docs: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Setup project environment + run: make env + - name: Make the build + run: make docs-sphinx + - name: Compress the build + run: tar -cf "sphinx_html_docs.tar" build/sphinx/ + - name: Upload the build + uses: ncipollo/release-action@v1 + with: + allowUpdates: true + artifacts: sphinx_html_docs.tar \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 13260c7e..88c3c78c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -82,6 +82,8 @@ efrocache when anything in the cache-map changed (which is the case for most commits). Please holler if you are still seeing lots more 'Extracting:' lines when running builds after pulling small updates from git. +- Added github workflow for making docker image and sphinx docs nightly +- Added github workflow for making build release on tag creation ### 1.7.34 (build 21823, api 8, 2024-04-26) - Bumped Python version from 3.11 to 3.12 for all builds and project tools. One diff --git a/Makefile b/Makefile index 17f3c708..cfe969d9 100644 --- a/Makefile +++ b/Makefile @@ -1183,16 +1183,20 @@ clion-staging: assets-cmake resources meta # # ################################################################################ +# Build the docker image named bombsquad_server docker-build: assets-cmake $(PCOMMAND) build_docker +# Run the bombsquad_server image docker-run: docker run -it bombsquad_server +# Save the bombsquad_server docker image to build/docker/bombsquad_server_docker.tar docker-save: docker-build mkdir -p build/docker/ docker save bombsquad_server -o build/docker/bombsquad_server_docker.tar +# Cleanup docker files docker-clean: rm build/docker/bombsquad_server_docker.tar docker rmi bombsquad_server --force diff --git a/config/spinoffconfig.py b/config/spinoffconfig.py index 4da1e2ee..51da5f16 100644 --- a/config/spinoffconfig.py +++ b/config/spinoffconfig.py @@ -196,6 +196,8 @@ ctx.filter_file_names = { 'ci.yml', 'cd.yml', 'deploy_docs.yml', + 'nightly.yml', + 'release.yml', 'LICENSE', 'cloudtool', 'bacloud',