This repository has been archived by the owner on Jan 12, 2025. It is now read-only.
Build #44
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: Build | |
on: | |
push: | |
workflow_dispatch: | |
schedule: | |
- cron: '0 0 * * 1' | |
jobs: | |
build: | |
runs-on: ubuntu-24.04 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Login | |
run: echo "${{ secrets.GITHUB_TOKEN }}" | podman login ghcr.io -u "${{ github.actor }}" --password-stdin | |
- name: Build Alpine container | |
run: podman build -t ghcr.io/charles8191/hardened_malloc/artifact:alpine -f Containerfile.alpine | |
- name: Build Debian container | |
run: podman build -t ghcr.io/charles8191/hardened_malloc/artifact:debian -f Containerfile.debian | |
- name: Build RHEL container | |
run: podman build -t ghcr.io/charles8191/hardened_malloc/artifact:rhel -f Containerfile.rhel | |
- name: Build binary using Alpine | |
run: | | |
set -ex | |
mkdir out-alpine | |
podman run -v ./out-alpine:/out ghcr.io/charles8191/hardened_malloc/artifact:alpine | |
- name: Build binary using Debian | |
run: | | |
set -ex | |
mkdir out-debian | |
podman run -v ./out-debian:/out ghcr.io/charles8191/hardened_malloc/artifact:debian | |
- name: Build binary using RHEL | |
run: | | |
set -ex | |
mkdir out-rhel | |
podman run -v ./out-rhel:/out ghcr.io/charles8191/hardened_malloc/artifact:debian | |
- name: Configure Git | |
run: | | |
set -ex | |
git config user.name "github-actions[bot]" | |
git config user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
- name: Push Alpine binary | |
run: | | |
set -ex | |
cp -vf out-alpine/libhardened_malloc.so libhardened_malloc-alpine.so | |
git add libhardened_malloc-alpine.so | |
git commit --allow-empty -m "[AUTOMATED] Upload Alpine binary" | |
git push | |
- name: Push Debian binary | |
run: | | |
set -ex | |
cp -vf out-debian/libhardened_malloc.so libhardened_malloc-debian.so | |
git add libhardened_malloc-debian.so | |
git commit --allow-empty -m "[AUTOMATED] Upload Debian binary" | |
git push | |
- name: Push RHEL binary | |
run: | | |
set -ex | |
cp -vf out-rhel/libhardened_malloc.so libhardened_malloc-rhel.so | |
git add libhardened_malloc-rhel.so | |
git commit --allow-empty -m "[AUTOMATED] Upload RHEL binary" | |
git push | |
- name: Push Alpine container | |
run: podman push ghcr.io/charles8191/hardened_malloc/artifact:alpine | |
- name: Push Debian container | |
run: podman push ghcr.io/charles8191/hardened_malloc/artifact:debian | |
- name: Push RHEL container | |
run: podman push ghcr.io/charles8191/hardened_malloc/artifact:rhel |