e2e: Group log lines

This commit is contained in:
katexochen 2022-09-02 12:44:20 +02:00 committed by Paul Meyer
parent ef8130a918
commit 0c5c11e8b7
8 changed files with 62 additions and 33 deletions

View File

@ -9,6 +9,7 @@ runs:
steps: steps:
- name: Install az CLI - name: Install az CLI
run: | run: |
echo "::group::Install build dependencies"
sudo apt-get update sudo apt-get update
sudo apt-get install ca-certificates curl apt-transport-https lsb-release gnupg -y sudo apt-get install ca-certificates curl apt-transport-https lsb-release gnupg -y
curl -sL https://packages.microsoft.com/keys/microsoft.asc | curl -sL https://packages.microsoft.com/keys/microsoft.asc |
@ -20,6 +21,7 @@ runs:
sudo apt-get update sudo apt-get update
sudo apt-get install azure-cli -y sudo apt-get install azure-cli -y
az help az help
echo "::endgroup::"
shell: bash shell: bash
# As described at: # As described at:
# https://github.com/Azure/login#configure-deployment-credentials # https://github.com/Azure/login#configure-deployment-credentials

View File

@ -15,12 +15,17 @@ runs:
- name: Install Dependencies - name: Install Dependencies
shell: bash shell: bash
run: sudo apt-get update && sudo apt-get -y install cmake make run: |
echo "::group::Install build dependencies"
sudo apt-get update && sudo apt-get -y install cmake make
echo "::endgroup::"
- name: Build the bootstrapper - name: Build the bootstrapper
shell: bash shell: bash
run: | run: |
echo "::group::Build the bootstrapper"
mkdir -p build && cd build mkdir -p build && cd build
cmake .. cmake ..
make bootstrapper make bootstrapper
mv -n bootstrapper "${{ inputs.outputPath }}" mv -n bootstrapper "${{ inputs.outputPath }}"
echo "::endgroup::"

View File

@ -5,34 +5,36 @@ description: |
when run on v* tag. when run on v* tag.
inputs: inputs:
targetOS: targetOS:
description: 'Build CLI for this OS. [linux, darwin]' description: "Build CLI for this OS. [linux, darwin]"
required: true required: true
default: 'linux' default: "linux"
targetArch: targetArch:
description: 'Build CLI for this architecture. [amd64, arm64]' description: "Build CLI for this architecture. [amd64, arm64]"
required: true required: true
default: 'amd64' default: "amd64"
cosignPublicKey: cosignPublicKey:
description: 'Cosign public key' description: "Cosign public key"
required: false required: false
default: '' default: ""
cosignPrivateKey: cosignPrivateKey:
description: 'Cosign private key' description: "Cosign private key"
required: false required: false
default: '' default: ""
cosignPassword: cosignPassword:
description: 'Password for Cosign private key' description: "Password for Cosign private key"
required: false required: false
default: '' default: ""
runs: runs:
using: "composite" using: "composite"
steps: steps:
- name: Install build dependencies - name: Install build dependencies
run: | run: |
echo "::group::Install build dependencies"
sudo apt-get update sudo apt-get update
sudo apt-get install \ sudo apt-get install \
build-essential cmake \ build-essential cmake \
-y -y
echo "::endgroup::"
shell: bash shell: bash
# https://github.blog/2022-04-12-git-security-vulnerability-announced/ # https://github.blog/2022-04-12-git-security-vulnerability-announced/

View File

@ -3,12 +3,12 @@ description: Build the Constellation debugd binary
inputs: inputs:
outputPath: outputPath:
description: 'Output path of the binary' description: "Output path of the binary"
default: './debugd' default: "./debugd"
required: true required: true
runs: runs:
using: 'composite' using: "composite"
steps: steps:
- name: Install Go - name: Install Go
uses: actions/setup-go@84cbf8094393cdc5fe1fe1671ff2647332956b1a uses: actions/setup-go@84cbf8094393cdc5fe1fe1671ff2647332956b1a
@ -17,11 +17,16 @@ runs:
- name: Install Dependencies - name: Install Dependencies
shell: bash shell: bash
run: sudo apt-get update && sudo apt-get -y install cmake make run: |
echo "::group::Install build dependencies"
sudo apt-get update
sudo apt-get -y install cmake make
echo "::endgroup::"
- name: Build debugd - name: Build debugd
shell: bash shell: bash
run: | run: |
echo "::group::Build debugd"
homedir="$(getent passwd $(id -u) | cut -d ":" -f 6)" homedir="$(getent passwd $(id -u) | cut -d ":" -f 6)"
mkdir -p build && cd build mkdir -p build && cd build
cmake .. cmake ..
@ -31,3 +36,4 @@ runs:
export GOMODCACHE=${homedir}/.cache/go-mod export GOMODCACHE=${homedir}/.cache/go-mod
make debugd cdbg make debugd cdbg
mv -n debugd "${{ inputs.outputPath }}" mv -n debugd "${{ inputs.outputPath }}"
echo "::endgroup::"

View File

@ -15,12 +15,17 @@ runs:
- name: Install Dependencies - name: Install Dependencies
shell: bash shell: bash
run: sudo apt-get update && sudo apt-get -y install cmake make run: |
echo "::group::Install build dependencies"
sudo apt-get update && sudo apt-get -y install cmake make
echo "::endgroup::"
- name: Build the disk-mapper - name: Build the disk-mapper
shell: bash shell: bash
run: | run: |
echo "::group::Build the disk-mapper"
mkdir -p build && cd build mkdir -p build && cd build
cmake .. cmake ..
make disk-mapper make disk-mapper
mv -n disk-mapper "${{ inputs.outputPath }}" mv -n disk-mapper "${{ inputs.outputPath }}"
echo "::endgroup::"

View File

@ -45,10 +45,12 @@ runs:
shell: bash shell: bash
- name: Install yq jq - name: Install yq jq
run: | run: |
echo "::group::Install dependencies"
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys CC86BB64 sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys CC86BB64
sudo add-apt-repository ppa:rmescandon/yq sudo add-apt-repository ppa:rmescandon/yq
sudo apt update sudo apt update
sudo apt install yq jq -y sudo apt install yq jq -y
echo "::endgroup::"
shell: bash shell: bash
- name: Constellation config generate - name: Constellation config generate
@ -130,7 +132,9 @@ runs:
- name: Cdbg deploy - name: Cdbg deploy
run: | run: |
echo "::group::cdbg deploy"
cdbg deploy --bootstrapper $GITHUB_WORKSPACE/build/bootstrapper cdbg deploy --bootstrapper $GITHUB_WORKSPACE/build/bootstrapper
echo "::endgroup::"
shell: bash shell: bash
if: ${{ inputs.isDebugImage == 'true' }} if: ${{ inputs.isDebugImage == 'true' }}

View File

@ -7,35 +7,35 @@ inputs:
description: "Either 'gcp' or 'azure'." description: "Either 'gcp' or 'azure'."
required: true required: true
cosignPublicKey: cosignPublicKey:
description: 'Cosign public key' description: "Cosign public key"
required: false required: false
default: '' default: ""
cosignPrivateKey: cosignPrivateKey:
description: 'Cosign private key' description: "Cosign private key"
required: false required: false
default: '' default: ""
cosignPassword: cosignPassword:
description: 'Password for Cosign private key' description: "Password for Cosign private key"
required: false required: false
default: '' default: ""
awsAccessKeyID: awsAccessKeyID:
description: 'AWS access key ID to upload measurements' description: "AWS access key ID to upload measurements"
required: false required: false
default: '' default: ""
awsSecretAccessKey: awsSecretAccessKey:
description: 'AWS secret access key to upload measurements' description: "AWS secret access key to upload measurements"
required: false required: false
default: '' default: ""
awsDefaultRegion: awsDefaultRegion:
description: 'AWS region of S3 bucket to upload measurements' description: "AWS region of S3 bucket to upload measurements"
required: false required: false
default: '' default: ""
awsBucketName: awsBucketName:
description: 'S3 bucket name to upload measurements to' description: "S3 bucket name to upload measurements to"
required: false required: false
default: '' default: ""
runs: runs:
using: 'composite' using: "composite"
steps: steps:
- name: Build hack/pcr-reader - name: Build hack/pcr-reader
run: | run: |
@ -97,7 +97,10 @@ runs:
if: ${{ inputs.cosignPublicKey != '' && inputs.cosignPrivateKey != '' && inputs.cosignPassword != '' }} if: ${{ inputs.cosignPublicKey != '' && inputs.cosignPrivateKey != '' && inputs.cosignPassword != '' }}
- name: Install AWS CLI - name: Install AWS CLI
run: sudo apt-get update && sudo apt-get -y install awscli run: |
echo "::group::Install AWS CLI"
sudo apt-get update && sudo apt-get -y install awscli
echo "::endgroup::"
shell: bash shell: bash
if: ${{ inputs.awsAccessKeyID != '' && inputs.awsSecretAccessKey != '' && inputs.awsDefaultRegion != '' && inputs.awsBucketName != '' }} if: ${{ inputs.awsAccessKeyID != '' && inputs.awsSecretAccessKey != '' && inputs.awsDefaultRegion != '' && inputs.awsBucketName != '' }}
- name: Upload to S3 - name: Upload to S3

View File

@ -12,8 +12,10 @@ runs:
- name: Install curl gpg - name: Install curl gpg
shell: bash shell: bash
run: | run: |
echo "::group::Install dependencies"
sudo apt update sudo apt update
sudo apt install curl gpg -y sudo apt install curl gpg -y
echo "::endgroup::"
- name: Install operator-sdk - name: Install operator-sdk
shell: bash shell: bash