Skip to content

Commit

Permalink
Refine application processing
Browse files Browse the repository at this point in the history
- add application arguments to protobuffer
- add automatic nix to JSON conversion for application definition
- add argument processing to agent:
- parsing application manifest
- validate extra arguments
- add extra (optional) arguments to givc-cli
- add admin server args forwarding
- remove obsolete application start function from go implementation
- update nixpkgs
- update go + deps

Signed-off-by: Manuel Bluhm <[email protected]>
  • Loading branch information
mbssrc committed Sep 17, 2024
1 parent 6a85012 commit 626df89
Show file tree
Hide file tree
Showing 31 changed files with 1,397 additions and 304 deletions.
15 changes: 9 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@ This project was started to support the development of system modules across a v

### Systemd Management Agent

The systemd management agent runs in the host and VMs, and connects to the systemd manager of the system. It provides functionality to control services in host, system VMs, and application VMs. The agent can connect to the system manager to control system units, or
to the user manager to control applications running as transient systemd services.
The systemd management agent runs in the host and VMs, and connects to the systemd manager of the system. It provides functionality to control services in host, system VMs, and application VMs. The agent can connect to the system manager to control system units, or to the user manager to control applications running as transient systemd services.

### Admin Service (System Manager)

Expand Down Expand Up @@ -137,10 +136,14 @@ To use the agent as application controller, include the `appvm` module as follow
addr = "192.168.1.123";
port = "9000";
# Specify applications with "name":"command" (JSON)
applications = ''{
"appflowy": "run-waypipe appflowy"
}'';
# Specify applications by name, command, and argument types accepted
applications = [
{
name = "foot";
command = "${pkgs.foot}/bin/foot";
args = [ "flag" ];
}
];
# Provide TLS configuration files
tls = {
Expand Down
479 changes: 407 additions & 72 deletions api/admin/admin.pb.go

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion api/admin/admin.proto
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ message RegistryResponse {
message ApplicationRequest {
string AppName = 1;
optional string VmName = 2;
repeated string Args = 3;
}

message ApplicationResponse {
Expand Down Expand Up @@ -74,5 +75,5 @@ service AdminService {
rpc Reboot(Empty) returns (Empty) {}

rpc QueryList(Empty) returns (QueryListResponse) {}
rpc Watch(Empty) returns (stream WatchItem) {}
rpc Watch(Empty) returns (stream WatchItem) {}
}
106 changes: 104 additions & 2 deletions api/admin/admin_grpc.pb.go

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

10 changes: 5 additions & 5 deletions api/hwid/hwid.pb.go

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

2 changes: 1 addition & 1 deletion api/hwid/hwid_grpc.pb.go

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

1 change: 1 addition & 0 deletions api/protoc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ gen_protoc() {
"$1"/"$2"
}

gen_protoc api/admin admin.proto
gen_protoc api/systemd systemd.proto
gen_protoc api/wifi wifi.proto
gen_protoc api/hwid hwid.proto
Loading

0 comments on commit 626df89

Please sign in to comment.