mirror of
https://github.com/ultravioletrs/cocos.git
synced 2026-06-22 20:00:18 +00:00
5377dd4d7f
* Refactor mock interfaces to use 'any' instead of 'interface{}' for improved type safety and readability across multiple files in the manager and pkg directories.
Signed-off-by: Sammy Oina <sammyoina@gmail.com>
* Update Go version to 1.25.x in CI workflows and remove obsolete Go package files
Signed-off-by: Sammy Oina <sammyoina@gmail.com>
* Add mock implementations for various components in the attestation and SDK packages
- Created mock for MeasurementProvider in pkg/attestation/cmdconfig/mocks/mocks_test.go
- Created mock for Provider in pkg/attestation/mocks/mocks_test.go
- Created mock for Client in pkg/clients/grpc/mocks/mocks_test.go
- Created mock for SDK in pkg/sdk/mocks/mocks_test.go
These mocks are generated using mockery and are intended for unit testing purposes.
Signed-off-by: Sammy Oina <sammyoina@gmail.com>
* Remove autogenerated mock files and update mock usage in tests
- Deleted mocks for gRPC clients in pkg/clients/grpc/mocks/mocks_test.go and pkg/sdk/mocks/mocks_test.go.
- Updated test files in pkg/progressbar/progress_test.go to use the new mock structure without type parameters for gRPC client interfaces.
- Refactored mock generation in pkg/sdk/mocks/sdk.go to streamline the mock creation process and ensure consistency across mock methods.
Signed-off-by: Sammy Oina <sammyoina@gmail.com>
* Update protobuf generated files for events and manager
- Bump protoc-gen-go version from v1.36.5 to v1.36.8 in events.pb.go and manager.pb.go.
- Refactor raw descriptor definitions in events.pb.go and manager.pb.go to use string concatenation for better readability and maintainability.
- Ensure compatibility with the latest protobuf specifications and improve code generation consistency.
Signed-off-by: Sammy Oina <sammyoina@gmail.com>
* Update test commands to use GOTOOLCHAIN for consistent Go version handling
Signed-off-by: Sammy Oina <sammyoina@gmail.com>
* Fix GOTOOLCHAIN usage in test command for consistency
Signed-off-by: Sammy Oina <sammyoina@gmail.com>
---------
Signed-off-by: Sammy Oina <sammyoina@gmail.com>
81 lines
1.9 KiB
YAML
81 lines
1.9 KiB
YAML
name: Build and Release Hal
|
|
|
|
on:
|
|
push:
|
|
tags:
|
|
- "*"
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 120
|
|
steps:
|
|
- name: Free Disk Space
|
|
run: |
|
|
sudo apt-get clean
|
|
sudo rm -rf /usr/share/dotnet
|
|
sudo rm -rf /opt/ghc
|
|
sudo rm -rf "/usr/local/share/boost"
|
|
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
|
|
df -h
|
|
|
|
- name: Update Ubuntu
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get upgrade -y
|
|
sudo apt-get clean
|
|
sudo apt-get autoremove -y
|
|
df -h
|
|
|
|
- name: Maximize build space
|
|
uses: easimon/maximize-build-space@master
|
|
with:
|
|
root-reserve-mb: 35000
|
|
swap-size-mb: 1024
|
|
remove-dotnet: "true"
|
|
remove-android: "true"
|
|
- name: Check free space
|
|
run: |
|
|
echo "Free space:"
|
|
df -h
|
|
|
|
- name: Install Go
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version: 1.25.x
|
|
cache-dependency-path: "go.sum"
|
|
|
|
- name: Checkout cocos
|
|
uses: actions/checkout@v4
|
|
with:
|
|
repository: "ultravioletrs/cocos"
|
|
path: cocos
|
|
|
|
- name: Checkout buildroot
|
|
uses: actions/checkout@v4
|
|
with:
|
|
repository: "buildroot/buildroot"
|
|
path: buildroot
|
|
ref: 2025.08-rc3
|
|
|
|
- name: Build hal
|
|
run: |
|
|
cd buildroot
|
|
make BR2_EXTERNAL=../cocos/hal/linux cocos_defconfig
|
|
make
|
|
|
|
- name: Build cocos
|
|
run: |
|
|
cd cocos
|
|
make
|
|
|
|
- name: Release
|
|
uses: softprops/action-gh-release@v2
|
|
with:
|
|
files: |
|
|
buildroot/output/images/bzImage
|
|
buildroot/output/images/rootfs.cpio.gz
|
|
cocos/build/cocos-agent
|
|
cocos/build/cocos-cli
|
|
cocos/build/cocos-manager
|