opencode: use serve command for web interface
This commit is contained in:
parent
a184bd2f84
commit
a7d2aca3f0
3 changed files with 5 additions and 5 deletions
|
|
@ -109,7 +109,7 @@ in
|
|||
"DEBUG"
|
||||
];
|
||||
description = ''
|
||||
Extra arguments to pass to the opencode web command.
|
||||
Extra arguments to pass to the opencode serve command.
|
||||
|
||||
These arguments override the "server" options defined in the configuration file.
|
||||
See <https://opencode.ai/docs/web/#config-file> for available options.
|
||||
|
|
@ -498,7 +498,7 @@ in
|
|||
};
|
||||
|
||||
Service = {
|
||||
ExecStart = "${lib.getExe cfg.package} web ${lib.escapeShellArgs webCfg.extraArgs}";
|
||||
ExecStart = "${lib.getExe cfg.package} serve ${lib.escapeShellArgs webCfg.extraArgs}";
|
||||
Restart = "always";
|
||||
RestartSec = 5;
|
||||
};
|
||||
|
|
@ -515,7 +515,7 @@ in
|
|||
config = {
|
||||
ProgramArguments = [
|
||||
(lib.getExe cfg.package)
|
||||
"web"
|
||||
"serve"
|
||||
]
|
||||
++ webCfg.extraArgs;
|
||||
KeepAlive = {
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
<array>
|
||||
<string>/bin/sh</string>
|
||||
<string>-c</string>
|
||||
<string>/bin/wait4path /nix/store && exec @opencode@/bin/opencode web --hostname 0.0.0.0 --port 4096 --mdns --cors https://example.com --cors http://localhost:3000 --print-logs --log-level DEBUG</string>
|
||||
<string>/bin/wait4path /nix/store && exec @opencode@/bin/opencode serve --hostname 0.0.0.0 --port 4096 --mdns --cors https://example.com --cors http://localhost:3000 --print-logs --log-level DEBUG</string>
|
||||
</array>
|
||||
<key>RunAtLoad</key>
|
||||
<true/>
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
WantedBy=default.target
|
||||
|
||||
[Service]
|
||||
ExecStart=@opencode@/bin/opencode web --hostname 0.0.0.0 --port 4096 --mdns --cors https://example.com --cors http://localhost:3000 --print-logs --log-level DEBUG
|
||||
ExecStart=@opencode@/bin/opencode serve --hostname 0.0.0.0 --port 4096 --mdns --cors https://example.com --cors http://localhost:3000 --print-logs --log-level DEBUG
|
||||
Restart=always
|
||||
RestartSec=5
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue