Enable TES server with each boot as well #45
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Ubuntu 22.04 - Build static deb packages and zip files | |
on: | |
push: | |
branches: | |
- main | |
workflow_dispatch: | |
pull_request: | |
jobs: | |
build: | |
runs-on: ubuntu-22.04-arm | |
strategy: | |
fail-fast: false | |
matrix: | |
build_type: [RelWithDebInfo, MinSizeRel] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Podman | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y podman | |
- name: Cache Podman image | |
uses: actions/cache@v4 | |
with: | |
path: ~/podman-image.tar | |
key: | |
${{ runner.os }}-podman-${{ | |
hashFiles('misc/staticbuildtestcontainer/*') }} | |
- name: Build and save container for aarch64-linux-gnu | |
run: | | |
if [ ! -f ~/podman-image.tar ]; then | |
podman build --from=docker.io/arm64v8/ubuntu:22.04 --arch=arm64 misc/staticbuildtestcontainer -t container | |
podman save container:latest > ~/podman-image.tar | |
else | |
podman load < ~/podman-image.tar | |
fi | |
- name: Run build in container | |
shell: bash | |
run: | | |
podman run -v $PWD/.:/aws-greengrass-lite --replace --name ggl container:latest bash -c "\ | |
cd /aws-greengrass-lite && \ | |
rm -rf build/ && \ | |
cmake -B build \ | |
-DGGL_LOG_LEVEL=DEBUG \ | |
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \ | |
-DCMAKE_FIND_DEBUG_MODE=ON \ | |
-DGGL_SYSTEMD_SYSTEM_USER=ggcore \ | |
-DGGL_SYSTEMD_SYSTEM_GROUP=ggcore \ | |
-DGGL_SYSTEMD_SYSTEM_DIR=/lib/systemd/system \ | |
-DCMAKE_INSTALL_PREFIX=/usr && \ | |
make -C build -j$(nproc) && \ | |
cd build && cpack -v -G DEB && cd - \ | |
" | |
- name: Save package | |
run: | | |
mkdir ${{ github.workspace }}/zipfile/ | |
cp ${{ github.workspace }}/build/*.deb ${{ github.workspace }}/zipfile/ | |
- name: Generate readme / install file | |
run: | | |
cat ${{ github.workspace }}/.github/workflows/static-packaging/readme.template.txt >> ${{ github.workspace }}/zipfile/readme.txt | |
cp ${{ github.workspace }}/.github/workflows/packaging/install-greengrass-lite.sh ${{ github.workspace }}/zipfile/ | |
sed -i 's|{{ VERSION_LINK }}|${{ github.server_url }}/${{ github.repository }}/commit/${{ github.sha }}|g' ${{ github.workspace }}/zipfile/readme.txt | |
sed -i 's|{{ UBUNTU_VERSION }}|22.04|g' ${{ github.workspace }}/zipfile/install-greengrass-lite.sh | |
cat ${{ github.workspace }}/LICENSE >> ${{ github.workspace }}/zipfile/readme.txt | |
- name: md5sums | |
run: | | |
md5sum ${{ github.workspace }}/zipfile/* | |
- name: Save package | |
uses: actions/upload-artifact@v4 | |
with: | |
name: | |
aws-greengrass-lite-ubuntu-aarch64-linux-gnu_${{ matrix.build_type | |
}}-static | |
path: | | |
${{ github.workspace }}/zipfile/* | |
retention-days: 1 | |
- name: | |
Save arm64 package without build type - default package to download | |
if: matrix.build_type == 'MinSizeRel' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: aws-greengrass-lite-ubuntu-arm64-static | |
path: | | |
${{ github.workspace }}/zipfile/* | |
retention-days: 1 |