azurelinux-sysinfo: package to deploy systemd service that writes system info to log #1161
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
# Copyright (c) Microsoft Corporation. | |
# Licensed under the MIT License. | |
name: Signature files check | |
on: | |
push: | |
branches: [main, dev, 1.0*, 2.0*, 3.0*, fasttrack/*] | |
pull_request: | |
branches: [main, dev, 1.0*, 2.0*, 3.0*, fasttrack/*] | |
jobs: | |
spec-check: | |
name: Signature files check | |
runs-on: ubuntu-latest | |
steps: | |
# Checkout the branch of our repo that triggered this action | |
- name: Workflow trigger checkout | |
uses: actions/checkout@v4 | |
# For consistency, we use the same major/minor version of Python that CBL-Mariner ships | |
- name: Setup Python 3.12 | |
uses: actions/setup-python@v5 | |
with: | |
python-version: 3.12 | |
- name: Get Python dependencies | |
run: python3 -m pip install -r toolkit/scripts/requirements.txt | |
- name: Get base commit for PRs | |
if: ${{ github.event_name == 'pull_request' }} | |
run: | | |
git fetch origin ${{ github.base_ref }} | |
echo "base_sha=$(git rev-parse origin/${{ github.base_ref }})" >> $GITHUB_ENV | |
echo "Merging ${{ github.sha }} into ${{ github.base_ref }}" | |
- name: Get base commit for Pushes | |
if: ${{ github.event_name == 'push' }} | |
run: | | |
git fetch origin ${{ github.event.before }} | |
echo "base_sha=${{ github.event.before }}" >> $GITHUB_ENV | |
echo "Merging ${{ github.sha }} into ${{ github.event.before }}" | |
- name: Check the signatures | |
run: | | |
echo "Files changed: '$(git diff-tree --no-commit-id --name-only -r ${{ env.base_sha }} ${{ github.sha }})'" | |
changed_folders=$(dirname $(git diff-tree --diff-filter=d --no-commit-id --name-only -r ${{ env.base_sha }} ${{ github.sha }}) | sort --unique) | |
echo "Folders to validate: '${changed_folders}'" | |
python3 toolkit/scripts/check_signatures.py ${changed_folders} |