Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .task/checksum/event-processor-proto
Original file line number Diff line number Diff line change
@@ -1 +1 @@
5712d57f2055813c464a6a0ada047faa
f38734f61d520a59249dd4fcf2dd6e10
2 changes: 1 addition & 1 deletion .task/checksum/event-processor-protoc-plugins
Original file line number Diff line number Diff line change
@@ -1 +1 @@
19de25f1037631ee8f5c165df62cd82d
99aa06d3014798d86001c324468d497f
2 changes: 1 addition & 1 deletion auth-center/pkg/tools/tools.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
_ "github.com/google/gops"
_ "github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-grpc-gateway"
_ "github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2"
_ "github.com/knqyf263/go-plugin/cmd/protoc-gen-go-plugin"
_ "github.com/runtime-radar/go-plugin/cmd/protoc-gen-go-plugin"
_ "golang.org/x/vuln/cmd/govulncheck"
_ "google.golang.org/grpc/cmd/protoc-gen-go-grpc"
_ "google.golang.org/protobuf/cmd/protoc-gen-go"
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ services:
- local

tetragon:
image: quay.io/cilium/tetragon:v1.5.0
image: quay.io/cilium/tetragon:v1.7.0
ports:
- "54321:54321"
container_name: tetragon
Expand Down
33 changes: 16 additions & 17 deletions event-processor/Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,19 +65,21 @@ tasks:

proto-detector:
deps: [protoc-plugins]
dir: detector
cmds:
- |
PATH="{{.TOOLS_BIN}}{{if eq OS "windows"}};{{else}}:{{end}}$PATH"
protoc -I api \
--go-plugin_out=api \
--go-plugin_opt=paths=source_relative \
\
--go-plugin_opt=Mtetragon/bpf.proto="{{.MODULE_NAME}}/api/tetragon" \
--go-plugin_opt=Mtetragon/capabilities.proto="{{.MODULE_NAME}}/api/tetragon" \
--go-plugin_opt=Mtetragon/events.proto="{{.MODULE_NAME}}/api/tetragon" \
--go-plugin_opt=Mtetragon/sensors.proto="{{.MODULE_NAME}}/api/tetragon" \
--go-plugin_opt=Mtetragon/stack.proto="{{.MODULE_NAME}}/api/tetragon" \
--go-plugin_opt=Mtetragon/tetragon.proto="{{.MODULE_NAME}}/api/tetragon" \
--go-plugin_opt=Mtetragon/bpf.proto="{{.MODULE_NAME}}/detector/api/tetragon" \
--go-plugin_opt=Mtetragon/capabilities.proto="{{.MODULE_NAME}}/detector/api/tetragon" \
--go-plugin_opt=Mtetragon/eventlogservice.proto="{{.MODULE_NAME}}/detector/api/tetragon" \
--go-plugin_opt=Mtetragon/events.proto="{{.MODULE_NAME}}/detector/api/tetragon" \
--go-plugin_opt=Mtetragon/sensors.proto="{{.MODULE_NAME}}/detector/api/tetragon" \
--go-plugin_opt=Mtetragon/stack.proto="{{.MODULE_NAME}}/detector/api/tetragon" \
--go-plugin_opt=Mtetragon/tetragon.proto="{{.MODULE_NAME}}/detector/api/tetragon" \
\
api/*.proto api/tetragon/*.proto
sources:
Expand All @@ -91,19 +93,16 @@ tasks:
vars:
TINYGO_CURRENT_VERSION:
sh: "tinygo version | cut -d' ' -f3"
TINYGO_REQUIRED_VERSION: "0.39.0"
TINYGO_REQUIRED_VERSION: "0.41.1"
DETECTOR_DIR: detector/wasm
DETECTORS:
sh: find {{.DETECTOR_DIR}} -mindepth 1 -maxdepth 1 -type d -not -name '.*'
DEPLOY_DIR: deploy
preconditions:
- {sh: 'test "{{.TINYGO_CURRENT_VERSION}}" = "{{.TINYGO_REQUIRED_VERSION}}"', msg: "Current tinygo version: {{.TINYGO_CURRENT_VERSION}}, required: {{.TINYGO_REQUIRED_VERSION}}"}
cmds:
- |
{{if ne .TINYGO_CURRENT_VERSION .TINYGO_REQUIRED_VERSION}}
echo "Current tinygo version: {{.TINYGO_CURRENT_VERSION}}, required: {{.TINYGO_REQUIRED_VERSION}}" && exit 1
{{end}}
- |
detectors=`ls {{.DETECTOR_DIR}}`
for detector in $detectors; do
tinygo build -o {{.DEPLOY_DIR}}/${detector}.wasm -scheduler=none -target=wasip1 -buildmode=wasi-legacy --no-debug ./{{.DETECTOR_DIR}}/${detector}
done
- for: {var: DETECTORS}
cmd: tinygo build -o {{.DEPLOY_DIR}}/{{base .ITEM}}.wasm -scheduler=none -target=wasip1 -buildmode=c-shared --no-debug ./{{.ITEM}}
sources:
- "go.mod"
- "{{.DETECTOR_DIR}}/**/*.go"
Expand Down Expand Up @@ -240,7 +239,7 @@ tasks:
- GOBIN={{.TOOLS_BIN}} go install github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2
- GOBIN={{.TOOLS_BIN}} go install google.golang.org/protobuf/cmd/protoc-gen-go
- GOBIN={{.TOOLS_BIN}} go install google.golang.org/grpc/cmd/protoc-gen-go-grpc
- GOBIN={{.TOOLS_BIN}} go install github.com/knqyf263/go-plugin/cmd/protoc-gen-go-plugin
- GOBIN={{.TOOLS_BIN}} go install github.com/runtime-radar/go-plugin/cmd/protoc-gen-go-plugin

deploy:
sources:
Expand Down
2 changes: 1 addition & 1 deletion event-processor/api/config.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading