Skip to content

Community Edition 8.12.40-rc2 Release Candidate 2 #111

Community Edition 8.12.40-rc2 Release Candidate 2

Community Edition 8.12.40-rc2 Release Candidate 2 #111

Workflow file for this run

name: Build Assets
env:
VCPKG_BINARY_SOURCES: "clear;nuget,GitHub,read"
VCPKG_NUGET_REPOSITORY: "https://github.com/hpcc-systems/vcpkg"
on:
push:
tags:
- "*"
- "community_*"
- "!community_8.10.*"
- "!community_8.8.*"
- "!community_8.6.*"
- "!community_8.4.*"
- "!community_8.2.*"
- "!community_8.0.*"
- "!community_7.*"
jobs:
preamble:
name: Publish Release
runs-on: ubuntu-22.04
permissions:
contents: write
outputs:
folder_platform: ${{ steps.vars.outputs.folder_platform }}
mount_platform: ${{ steps.vars.outputs.mount_platform }}
folder_ln: ${{ steps.vars.outputs.folder_ln }}
mount_ln: ${{ steps.vars.outputs.mount_ln }}
folder_build: ${{ steps.vars.outputs.folder_build }}
mount_build: ${{ steps.vars.outputs.mount_build }}
community_ref: ${{ steps.vars.outputs.community_ref }}
internal_ref: ${{ steps.vars.outputs.internal_ref }}
community_tag: ${{ steps.vars.outputs.community_tag }}
internal_tag: ${{ steps.vars.outputs.internal_tag }}
community_branch: ${{ steps.vars.outputs.community_branch }}
cmake_docker_config: ${{ steps.vars.outputs.cmake_docker_config }}
gpg_import: ${{ steps.vars.outputs.gpg_import }}
steps:
- name: Calculate vars
id: vars
run: |
echo "folder_platform=${{ github.workspace }}/HPCC-Platform" >> $GITHUB_OUTPUT
echo 'mount_platform=source="${{ github.workspace }}/HPCC-Platform",target=/hpcc-dev/HPCC-Platform,type=bind,consistency=cached' >> $GITHUB_OUTPUT
echo "folder_ln=${{ github.workspace }}/LN" >> $GITHUB_OUTPUT
echo 'mount_ln=source="${{ github.workspace }}/LN",target=/hpcc-dev/LN,type=bind,consistency=cached' >> $GITHUB_OUTPUT
echo "folder_build=${{ github.workspace }}/build" >> $GITHUB_OUTPUT
echo 'mount_build=source="${{ github.workspace }}/build",target=/hpcc-dev/build,type=bind,consistency=cached' >> $GITHUB_OUTPUT
community_ref=${{ github.ref }}
echo "community_ref=$community_ref" >> $GITHUB_OUTPUT
echo "internal_ref=$(echo $community_ref | sed 's/community/internal/')" >> $GITHUB_OUTPUT
community_tag=$(echo $community_ref | cut -d'/' -f3)
echo "community_tag=$community_tag" >> $GITHUB_OUTPUT
echo "internal_tag=$(echo $community_tag | sed 's/community/internal/')" >> $GITHUB_OUTPUT
community_base_ref=${{ github.event.base_ref || github.ref }}
echo "community_branch=$(echo $community_base_ref | cut -d'/' -f3)" >> $GITHUB_OUTPUT
echo "cmake_docker_config=-DCMAKE_BUILD_TYPE=RelWithDebInfo -DVCPKG_FILES_DIR=/hpcc-dev -DCPACK_THREADS=0 -DUSE_OPTIONAL=OFF -DSIGN_MODULES=ON" >> $GITHUB_OUTPUT
echo 'gpg_import=gpg --batch --import /hpcc-dev/build/private.key' >> $GITHUB_OUTPUT
- name: Print vars
run: |
echo "${{ toJSON(steps.vars.outputs) }})"
- name: Release HPCC-Platform
uses: ncipollo/[email protected]
with:
allowUpdates: true
generateReleaseNotes: false
prerelease: ${{ contains(github.ref, '-rc') }}
- name: Release LN
uses: ncipollo/[email protected]
with:
allowUpdates: true
generateReleaseNotes: false
prerelease: ${{ contains(github.ref, '-rc') }}
owner: ${{ secrets.LNB_ACTOR }}
repo: LN
token: ${{ secrets.LNB_TOKEN }}
tag: ${{ steps.vars.outputs.internal_tag }}
build-docker:
name: Build Docker
# if: github.repository == 'hpcc-systems/HPCC-Platform'
needs: preamble
runs-on: ubuntu-22.04
strategy:
matrix:
include:
- os: ubuntu-22.10
- os: ubuntu-22.04
container: true
- os: ubuntu-22.04
- os: ubuntu-20.04
- os: ubuntu-18.04
- os: centos-8
- os: centos-7
- os: amazonlinux
- os: centos-7
ln: true
fail-fast: false
steps:
- name: Free additional disk space (remove Android SDK + Tools)
run: |
sudo rm -rf /usr/local/lib/android
- name: Checkout HPCC-Platform
uses: actions/checkout@v3
with:
ref: ${{ needs.preamble.outputs.community_ref }}
submodules: recursive
path: ${{ needs.preamble.outputs.folder_platform }}
- name: Checkout LN
if: ${{ matrix.ln }}
uses: actions/checkout@v3
with:
repository: ${{ github.repository_owner }}/LN
token: ${{ secrets.LNB_TOKEN }}
ref: ${{ needs.preamble.outputs.internal_ref }}
submodules: recursive
path: ${{ needs.preamble.outputs.folder_ln }}
- name: Calculate vars
id: vars
working-directory: ${{ needs.preamble.outputs.folder_platform }}/vcpkg
run: |
echo "vcpkg_sha_short=$(git rev-parse --short=8 HEAD)" >> $GITHUB_OUTPUT
- name: Print vars
run: |
echo "${{ toJSON(needs.preamble.outputs) }})"
echo "${{ toJSON(steps.vars.outputs) }})"
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v2
- name: Login to DockerHub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Create Build Image
uses: docker/build-push-action@v3
with:
builder: ${{ steps.buildx.outputs.name }}
file: ${{ needs.preamble.outputs.folder_platform }}/dockerfiles/vcpkg/${{ matrix.os }}.dockerfile
context: ${{ needs.preamble.outputs.folder_platform }}/dockerfiles/vcpkg
load: true
build-args: |
VCPKG_REF=${{ steps.vars.outputs.vcpkg_sha_short }}
tags: |
build-${{ matrix.os }}:latest
- name: CMake Packages
if: ${{ !matrix.container && !matrix.ln }}
run: |
mkdir -p ${{ needs.preamble.outputs.folder_build }}
echo "${{ secrets.SIGNING_SECRET }}" > ${{ needs.preamble.outputs.folder_build }}/private.key
plugins=("CASSANDRAEMBED" "COUCHBASEEMBED" "ECLBLAS" "H3" "JAVAEMBED" "KAFKA" "MEMCACHED" "MYSQLEMBED" "NLP" "REDIS" "SQLITE3EMBED" "SQS" "PLATFORM")
for plugin in "${plugins[@]}"; do
sudo rm -f ${{ needs.preamble.outputs.folder_build }}/CMakeCache.txt
sudo rm -rf ${{ needs.preamble.outputs.folder_build }}/CMakeFiles
docker_label=build-${{ matrix.os }}:latest
docker run --rm --mount ${{ needs.preamble.outputs.mount_platform }} --mount ${{ needs.preamble.outputs.mount_build }} $docker_label "${{ needs.preamble.outputs.gpg_import }} && cmake -S /hpcc-dev/HPCC-Platform -B /hpcc-dev/build ${{ needs.preamble.outputs.cmake_docker_config }} -DSIGN_MODULES_PASSPHRASE=${{ secrets.SIGN_MODULES_PASSPHRASE }} -DSIGN_MODULES_KEYID=${{ secrets.SIGN_MODULES_KEYID }} -D$plugin=ON -DCONTAINERIZED=OFF -DCPACK_STRIP_FILES=OFF"
docker run --rm --mount ${{ needs.preamble.outputs.mount_platform }} --mount ${{ needs.preamble.outputs.mount_build }} $docker_label "${{ needs.preamble.outputs.gpg_import }} && cmake --build /hpcc-dev/build --parallel $(nproc) --target package"
# Disabled as not currently needed ---
# docker run --rm --mount ${{ needs.preamble.outputs.mount_platform }} --mount ${{ needs.preamble.outputs.mount_build }} $docker_label "cmake -S /hpcc-dev/HPCC-Platform -B /hpcc-dev/build ${{ needs.preamble.outputs.cmake_docker_config }} -D$plugin=ON -DCONTAINERIZED=OFF -DCPACK_STRIP_FILES=ON"
# docker run --rm --mount ${{ needs.preamble.outputs.mount_platform }} --mount ${{ needs.preamble.outputs.mount_build }} $docker_label "cmake --build /hpcc-dev/build --parallel $(nproc) --target package"
done
- name: CMake Containerized Packages
if: ${{ matrix.container }}
run: |
mkdir -p ${{ needs.preamble.outputs.folder_build }}
echo "${{ secrets.SIGNING_SECRET }}" > ${{ needs.preamble.outputs.folder_build }}/private.key
sudo rm -f ${{ needs.preamble.outputs.folder_build }}/CMakeCache.txt
sudo rm -rf ${{ needs.preamble.outputs.folder_build }}/CMakeFiles
docker_label=build-${{ matrix.os }}:latest
docker run --rm --mount ${{ needs.preamble.outputs.mount_platform }} --mount ${{ needs.preamble.outputs.mount_build }} $docker_label "${{ needs.preamble.outputs.gpg_import }} && cmake -S /hpcc-dev/HPCC-Platform -B /hpcc-dev/build ${{ needs.preamble.outputs.cmake_docker_config }} -DSIGN_MODULES_PASSPHRASE=${{ secrets.SIGN_MODULES_PASSPHRASE }} -DSIGN_MODULES_KEYID=${{ secrets.SIGN_MODULES_KEYID }} -DINCLUDE_PLUGINS=ON -DCONTAINERIZED=ON -DSUPPRESS_REMBED=ON -DSUPPRESS_V8EMBED=ON -DSUPPRESS_SPARK=ON -DCPACK_STRIP_FILES=OFF"
docker run --rm --mount ${{ needs.preamble.outputs.mount_platform }} --mount ${{ needs.preamble.outputs.mount_build }} $docker_label "${{ needs.preamble.outputs.gpg_import }} && cmake --build /hpcc-dev/build --parallel $(nproc) --target package"
docker run --rm --mount ${{ needs.preamble.outputs.mount_platform }} --mount ${{ needs.preamble.outputs.mount_build }} $docker_label "${{ needs.preamble.outputs.gpg_import }} && cmake -S /hpcc-dev/HPCC-Platform -B /hpcc-dev/build ${{ needs.preamble.outputs.cmake_docker_config }} -DSIGN_MODULES_PASSPHRASE=${{ secrets.SIGN_MODULES_PASSPHRASE }} -DSIGN_MODULES_KEYID=${{ secrets.SIGN_MODULES_KEYID }} -DINCLUDE_PLUGINS=ON -DCONTAINERIZED=ON -DSUPPRESS_REMBED=ON -DSUPPRESS_V8EMBED=ON -DSUPPRESS_SPARK=ON -DCPACK_STRIP_FILES=ON"
docker run --rm --mount ${{ needs.preamble.outputs.mount_platform }} --mount ${{ needs.preamble.outputs.mount_build }} $docker_label "${{ needs.preamble.outputs.gpg_import }} && cmake --build /hpcc-dev/build --parallel $(nproc) --target package"
- name: Upload Assets
uses: ncipollo/[email protected]
if: ${{ !matrix.ln }}
with:
allowUpdates: true
generateReleaseNotes: false
prerelease: ${{ contains(github.ref, '-rc') }}
artifacts: "${{ needs.preamble.outputs.folder_build }}/*.deb,${{ needs.preamble.outputs.folder_build }}/*.rpm"
- name: CMake LN Packages
if: ${{ matrix.ln }}
run: |
mkdir -p ${{ needs.preamble.outputs.folder_build }}
echo "${{ secrets.SIGNING_SECRET }}" > ${{ needs.preamble.outputs.folder_build }}/private.key
sudo rm -f ${{ needs.preamble.outputs.folder_build }}/CMakeCache.txt
sudo rm -rf ${{ needs.preamble.outputs.folder_build }}/CMakeFiles
docker_label=build-${{ matrix.os }}:latest
docker run --rm --mount ${{ needs.preamble.outputs.mount_platform }} --mount ${{ needs.preamble.outputs.mount_ln }} --mount ${{ needs.preamble.outputs.mount_build }} $docker_label "${{ needs.preamble.outputs.gpg_import }} && cmake -S /hpcc-dev/LN -B /hpcc-dev/build -DHPCC_SOURCE_DIR=/hpcc-dev/HPCC-Platform ${{ needs.preamble.outputs.cmake_docker_config }} -DSIGN_MODULES_PASSPHRASE=${{ secrets.SIGN_MODULES_PASSPHRASE }} -DSIGN_MODULES_KEYID=${{ secrets.SIGN_MODULES_KEYID }} -DINCLUDE_PLUGINS=ON -DCONTAINERIZED=OFF -DSUPPRESS_REMBED=ON -DSUPPRESS_V8EMBED=ON -DSUPPRESS_SPARK=ON -DCPACK_STRIP_FILES=OFF"
docker run --rm --mount ${{ needs.preamble.outputs.mount_platform }} --mount ${{ needs.preamble.outputs.mount_ln }} --mount ${{ needs.preamble.outputs.mount_build }} $docker_label "${{ needs.preamble.outputs.gpg_import }} && cmake --build /hpcc-dev/build --parallel $(nproc) --target package"
# docker run --rm --mount ${{ needs.preamble.outputs.mount_platform }} --mount ${{ needs.preamble.outputs.mount_ln }} --mount ${{ needs.preamble.outputs.mount_build }} $docker_label "cmake -S /hpcc-dev/LN -B /hpcc-dev/build -DHPCC_SOURCE_DIR=/hpcc-dev/HPCC-Platform ${{ needs.preamble.outputs.cmake_docker_config }} -DINCLUDE_PLUGINS=ON -DCONTAINERIZED=OFF -DSUPPRESS_REMBED=ON -DSUPPRESS_V8EMBED=ON -DSUPPRESS_SPARK=ON -DCPACK_STRIP_FILES=ON"
# docker run --rm --mount ${{ needs.preamble.outputs.mount_platform }} --mount ${{ needs.preamble.outputs.mount_ln }} --mount ${{ needs.preamble.outputs.mount_build }} $docker_label "cmake --build /hpcc-dev/build --parallel $(nproc) --target package"
- name: Upload LN Assets
if: ${{ matrix.ln }}
uses: ncipollo/[email protected]
with:
allowUpdates: true
generateReleaseNotes: false
prerelease: ${{ contains(github.ref, '-rc') }}
owner: ${{ secrets.LNB_ACTOR }}
repo: LN
token: ${{ secrets.LNB_TOKEN }}
tag: ${{ needs.preamble.outputs.internal_tag }}
artifacts: "${{ needs.preamble.outputs.folder_build }}/hpccsystems-platform-internal*.deb,${{ needs.preamble.outputs.folder_build }}/hpccsystems-platform-internal*.rpm"
- name: Cleanup Environment
if: always()
run: rm -f ${{ needs.preamble.outputs.folder_build }}/private.key
- name: Upload error logs
if: ${{ failure() || cancelled() }}
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.os }}-${{ matrix.package }}-logs
path: ${{ needs.preamble.outputs.folder_build }}/**/*.log
build-bare-metal:
name: Build Bare Metal
# if: github.repository == 'hpcc-systems/HPCC-Platform'
needs: preamble
strategy:
matrix:
include:
- os: "windows-2022"
mono: ""
sudo: ""
cmake_config_options: '-T host=x64 -A x64 -DUSE_OPTIONAL=OFF -DCLIENTTOOLS_ONLY=ON -DUSE_AZURE=OFF -DUSE_CASSANDRA=OFF -DUSE_JAVA=OFF -DUSE_OPENLDAP=OFF'
cmake_build_options: "--config Release --parallel $NUMBER_OF_PROCESSORS"
- os: "macos-12"
mono: "mono"
sudo: "sudo"
cmake_config_options: "-DCMAKE_BUILD_TYPE=Release -DUSE_OPTIONAL=OFF -DCLIENTTOOLS_ONLY=ON -DUSE_AZURE=OFF -DUSE_CASSANDRA=OFF -DUSE_JAVA=OFF -DUSE_OPENLDAP=OFF"
cmake_build_options: "--parallel $(nproc)"
fail-fast: false
runs-on: ${{ matrix.os }}
steps:
- name: Print vars
shell: "bash"
run: |
echo ${{ matrix.os }}
echo "${{ toJSON(needs.preamble.outputs) }})"
- name: OSX Dependencies
if: ${{ contains(matrix.os, 'macos') }}
shell: "bash"
run: |
brew install bison flex pkg-config autoconf autoconf-archive automake libtool cmake openjdk@11
- name: "Remove builtin vcpkg (old)"
working-directory: .
shell: "bash"
run: |
${{ matrix.sudo }} rm -rf "$VCPKG_INSTALLATION_ROOT"
- name: Checkout HPCC-Platform
uses: actions/checkout@v3
with:
ref: ${{ needs.preamble.outputs.community_ref }}
submodules: recursive
path: ./HPCC-Platform
- name: Checkout LN
uses: actions/checkout@v3
with:
repository: ${{ github.repository_owner }}/LN
token: ${{ secrets.LNB_TOKEN }}
ref: ${{ needs.preamble.outputs.internal_ref }}
submodules: recursive
path: ./LN
- name: "vcpkg Bootstrap"
shell: "bash"
run: |
./HPCC-Platform/vcpkg/bootstrap-vcpkg.sh
- name: "Setup NuGet credentials"
shell: "bash"
run: |
${{ matrix.mono }} `./HPCC-Platform/vcpkg/vcpkg fetch nuget | tail -n 1` \
sources add \
-name "GitHub" \
-source "https://nuget.pkg.github.com/hpcc-systems/index.json" \
-storepasswordincleartext \
-username "${{ github.repository_owner }}" \
-password "${{ secrets.GITHUB_TOKEN }}"
- name: CMake Packages
shell: "bash"
run: |
mkdir -p ./build
cmake -S ./HPCC-Platform -B ./build ${{ matrix.cmake_config_options }}
cmake --build ./build ${{ matrix.cmake_build_options }} --target package
- name: Upload Assets
uses: ncipollo/[email protected]
with:
allowUpdates: true
generateReleaseNotes: false
prerelease: ${{ contains(github.ref, '-rc') }}
artifacts: "./build/*.exe,./build/*.msi,./build/*.dmg,./build/*.pkg,./build/*.tar.gz"
- name: CMake LN Packages
shell: "bash"
run: |
${{ matrix.sudo }} rm -f ./build/CMakeCache.txt
${{ matrix.sudo }} rm -rf ./build/CMakeFiles
cmake -S ./LN -B ./build ${{ matrix.cmake_config_options }}
cmake --build ./build ${{ matrix.cmake_build_options }} --target package
- name: Upload LN Assets
uses: ncipollo/[email protected]
with:
allowUpdates: true
generateReleaseNotes: false
prerelease: ${{ contains(github.ref, '-rc') }}
owner: ${{ secrets.LNB_ACTOR }}
repo: LN
token: ${{ secrets.LNB_TOKEN }}
tag: ${{ needs.preamble.outputs.internal_tag }}
artifacts: "./build/hpccsystems-clienttools-internal*.exe,./build/hpccsystems-clienttools-internal*.msi,./build/hpccsystems-clienttools-internal*.dmg,./build/hpccsystems-clienttools-internal*.pkg,./build/hpccsystems-clienttools-internal*.tar.gz"
- name: Upload error logs
if: ${{ failure() || cancelled() }}
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.os }}-${{ matrix.package }}-logs
path: ./build/**/*.log