MCPcopy Index your code
hub / github.com/coder/coder / syncCommand

Method syncCommand

cli/sync.go:7–35  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

5)
6
7func (r *RootCmd) syncCommand() *serpent.Command {
8 var socketPath string
9
10 cmd := &serpent.Command{
11 Use: "sync",
12 Short: "Manage unit dependencies for coordinated startup",
13 Long: "Commands for orchestrating unit startup order in workspaces. Units are most commonly coder scripts. Use these commands to declare dependencies between units, coordinate their startup sequence, and ensure units start only after their dependencies are ready. This helps prevent race conditions and startup failures.",
14 Handler: func(i *serpent.Invocation) error {
15 return i.Command.HelpHandler(i)
16 },
17 Children: []*serpent.Command{
18 r.syncPing(&socketPath),
19 r.syncStart(&socketPath),
20 r.syncWant(&socketPath),
21 r.syncComplete(&socketPath),
22 r.syncStatus(&socketPath),
23 },
24 Options: serpent.OptionSet{
25 {
26 Flag: "socket-path",
27 Env: "CODER_AGENT_SOCKET_PATH",
28 Description: "Specify the path for the agent socket.",
29 Value: serpent.StringOf(&socketPath),
30 },
31 },
32 }
33
34 return cmd
35}

Callers 1

AGPLExperimentalMethod · 0.95

Calls 5

syncPingMethod · 0.95
syncStartMethod · 0.95
syncWantMethod · 0.95
syncCompleteMethod · 0.95
syncStatusMethod · 0.95

Tested by

no test coverage detected