Skip to content

Commit edc99ee

Browse files
authored
Merge branch 'arm:main' into userspace_enable
2 parents 59f5b58 + 9123f07 commit edc99ee

22 files changed

Lines changed: 149 additions & 53 deletions

File tree

.github/CODEOWNERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
* @arm/edge-dev

.github/workflows/ci.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ jobs:
4141
test:
4242
name: Test
4343
runs-on: ubuntu-latest
44+
env:
45+
PUBLISH_TEST_COVERAGE: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }}
4446
steps:
4547
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
4648

@@ -52,8 +54,26 @@ jobs:
5254
run: go mod download
5355

5456
- name: Run fast tests
57+
if: ${{ env.PUBLISH_TEST_COVERAGE != 'true' }}
5558
run: go test -v -race ./internal/...
5659

60+
- name: Run fast tests and generate coverage
61+
if: ${{ env.PUBLISH_TEST_COVERAGE == 'true' }}
62+
run: go test -v -race ./internal/... -covermode=atomic -coverprofile=coverage.out
63+
64+
- name: Install Qlty Cloud
65+
if: ${{ env.PUBLISH_TEST_COVERAGE == 'true' }}
66+
uses: qltysh/qlty-action/install@a19242102d17e497f437d7466aa01b528537e899 # v2.2.0
67+
68+
- name: Upload coverage to Qlty Cloud
69+
if: ${{ env.PUBLISH_TEST_COVERAGE == 'true' }}
70+
uses: qltysh/qlty-action/coverage@a19242102d17e497f437d7466aa01b528537e899 # v2.2.0
71+
with:
72+
token: ${{ secrets.QLTY_COVERAGE_TOKEN }}
73+
files: coverage.out
74+
strip-prefix: github.com/arm/remoteproc-runtime
75+
skip-errors: false
76+
5777
- name: Download Remoteproc Simulator
5878
uses: robinraju/release-downloader@daf26c55d821e836577a15f77d86ddc078948b05 # v1.12
5979
with:

.gitignore

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,10 @@ dist/
33

44
# make artifacts
55
out/
6+
7+
# coverage files
8+
coverage.out
9+
10+
# binaries
11+
/containerd-shim-remoteproc-v1
12+
/remoteproc-runtime

.goreleaser.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,10 @@ builds:
1717
- linux
1818
goarch:
1919
- arm64
20+
ldflags:
21+
- -s -w
22+
- -X github.com/arm/remoteproc-runtime/internal/version.Version={{.Version}}
23+
- -X github.com/arm/remoteproc-runtime/internal/version.GitCommit={{.Commit}}
2024
- id: remoteproc-runtime
2125
main: ./cmd/remoteproc-runtime
2226
binary: remoteproc-runtime
@@ -26,6 +30,10 @@ builds:
2630
- linux
2731
goarch:
2832
- arm64
33+
ldflags:
34+
- -s -w
35+
- -X github.com/arm/remoteproc-runtime/internal/version.Version={{.Version}}
36+
- -X github.com/arm/remoteproc-runtime/internal/version.GitCommit={{.Commit}}
2937

3038
archives:
3139
- formats: [tar.gz]

.qlty/qlty.toml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
[coverage]
2+
exclude = [
3+
"e2e/**"
4+
]
5+
test_patterns = [
6+
"**/*_test.go"
7+
]

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,8 @@ docker ps
6464

6565
_See [USAGE.md](docs/USAGE.md) for full installation and configuration instructions._
6666

67+
_Try [remoteproc-runtime-example-zephyr](https://github.com/arm/remoteproc-runtime-example-zephyr/) for a minimal Zephyr RTOS application that can be deployed using Remoteproc Runtime._
68+
6769
## Documentation
6870

6971
- [Usage Guide](docs/USAGE.md) - How to use the runtime and shim

cmd/remoteproc-runtime/create.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ var (
1111
)
1212

1313
var createCmd = &cobra.Command{
14-
Use: "create <ID>",
14+
Use: "create <container-id>",
1515
Short: "Create a new container from an OCI bundle",
1616
Args: cobra.ExactArgs(1),
1717
RunE: func(cmd *cobra.Command, args []string) error {

cmd/remoteproc-runtime/delete.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import (
88
var forceDelete bool
99

1010
var deleteCmd = &cobra.Command{
11-
Use: "delete <ID>",
11+
Use: "delete <container-id>",
1212
Short: "Delete a container",
1313
Long: "Delete a container. Use --force to delete a running container.",
1414
Args: cobra.ExactArgs(1),

cmd/remoteproc-runtime/kill.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import (
1010
)
1111

1212
var killCmd = &cobra.Command{
13-
Use: "kill <ID> [SIGNAL]",
13+
Use: "kill <container-id> [SIGNAL]",
1414
Short: "Send a signal to the container process",
1515
Long: "Send a signal to the container process. Supported signals: TERM (15), KILL (9), INT (2). Default is TERM.",
1616
Args: cobra.RangeArgs(1, 2),

cmd/remoteproc-runtime/root.go

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import (
66
"strings"
77

88
"github.com/arm/remoteproc-runtime/internal/log"
9+
"github.com/arm/remoteproc-runtime/internal/version"
910
"github.com/spf13/cobra"
1011
)
1112

@@ -15,8 +16,9 @@ var (
1516
)
1617

1718
var rootCmd = &cobra.Command{
18-
Use: "container-runtime",
19-
Short: "A simple OCI-compliant container runtime using remoteproc",
19+
Use: "remoteproc-runtime",
20+
Short: "An OCI-compliant container runtime using remoteproc",
21+
Version: fmt.Sprintf("%s (commit: %s)", version.Version, version.GitCommit),
2022
PersistentPreRunE: func(cmd *cobra.Command, args []string) error {
2123
level, err := parseLogLevel(logLevel)
2224
if err != nil {

0 commit comments

Comments
 (0)