Files
Sammy Kerata Oina c422afe0a6 NOISSUE - Introduce a dedicated attestation service and refactor agent to use its gRPC client (#558)
* feat: introduce a dedicated attestation service and refactor agent to use its gRPC client

Signed-off-by: Sammy Oina <sammyoina@gmail.com>

* feat: Source attestation-service from GitHub, updating its build and installation process.

Signed-off-by: Sammy Oina <sammyoina@gmail.com>

* fix: update protoc version to 33.1 in CI workflow

Signed-off-by: Sammy Oina <sammyoina@gmail.com>

* refactor: Update Go build tag syntax, octal literals, and simplify agent attestation logic.

Signed-off-by: Sammy Oina <sammyoina@gmail.com>

* chore: update igvmmeasure script's subdirectory path to tools/igvmmeasure

Signed-off-by: Sammy Oina <sammyoina@gmail.com>

* refactor: rename AttestationService RPC methods from `Get` to `Fetch` and update corresponding service implementation.

Signed-off-by: Sammy Oina <sammyoina@gmail.com>

* refactor: rename attestation client methods from `GetX` to `FetchX`

Signed-off-by: Sammy Oina <sammyoina@gmail.com>

---------

Signed-off-by: Sammy Oina <sammyoina@gmail.com>
2025-12-17 14:07:11 +01:00

41 lines
1.0 KiB
Bash
Executable File

#!/bin/bash
REPO_URL="https://github.com/coconut-svsm/svsm.git"
BUILD_DIR="$(cd "$(dirname "$0")/../.." && pwd)/build"
mkdir -p "$BUILD_DIR"
# Define the target directory for cloning inside the build directory
TARGET_DIR="$BUILD_DIR/svsm"
SUBDIR="tools/igvmmeasure"
# Clone the repository if it doesn't exist
if [ -d "$TARGET_DIR" ]; then
echo "Repository already exists in $TARGET_DIR. Pulling latest changes..."
cd "$TARGET_DIR" && git pull
else
echo "Cloning repository into $TARGET_DIR..."
git clone --recurse-submodules "$REPO_URL" "$TARGET_DIR"
fi
# Ensure submodules are up to date
cd "$TARGET_DIR"
git submodule update --init --recursive
# Check if the required subdirectory exists
if [ -d "$SUBDIR" ]; then
echo "Successfully cloned repository and found '$SUBDIR' directory."
else
echo "Error: '$SUBDIR' directory not found inside '$TARGET_DIR'."
exit 1
fi
echo "Building the Rust crate..."
RELEASE=1 make bin/igvmmeasure BUILDDIR="$BUILD_DIR"
mv bin/igvmmeasure "$BUILD_DIR/"
echo "Binary stored in: $BUILD_DIR/igvmmeasure"