Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ProcessComposeCtx ¶
type ProcessComposeCtx struct {
*exec.CmdContext
// contains filtered or unexported fields
}
ProcessComposeCtx represents a `process-compose` context.
func Start ¶
func Start( rootDir string, flakeDir string, devShellAttrPath string, mustBeStarted bool, ) (pc ProcessComposeCtx, err error)
Start starts the process compose from a `devShellAttrPath` (e.g. `custodian.shells.test-dbs` which must be a `devenv` shell) in the flake `flake.nix` located at `flakeDir`. The `rootDir` is the working directory and where the `.devenv/state/pwd` file is for `nonPureEval == false`. Note: You also call StartFromInstallable and directly pass an installable, e.g. a flake output attribute path like `./a/b/c#mynamespace.shells.test-dbs`.
func StartFromInstallable ¶
func StartFromInstallable( rootDir string, devShellInstallable string, mustBeStarted bool, ) (pc ProcessComposeCtx, err error)
Start starts the process compose from a Nix `devShellInstallable` (e.g. `./tools/nix#custodian.shells.test-dbs` which must be a `devenv` shell). The `rootDir` is the working directory and where the `.devenv/state/pwd` file is for `nonPureEval == false`.
func (*ProcessComposeCtx) LogFile ¶ added in v0.24.0
func (pc *ProcessComposeCtx) LogFile() string
LogFile returns the log file used.
func (*ProcessComposeCtx) Socket ¶
func (pc *ProcessComposeCtx) Socket() string
Socket returns the socket used.
func (*ProcessComposeCtx) Stop ¶
func (pc *ProcessComposeCtx) Stop() error
Stop stops the process compose.
func (*ProcessComposeCtx) WaitTillRunning ¶
func (pc *ProcessComposeCtx) WaitTillRunning( ctx context.Context, procs ...string) (isRunning bool, err error)
Check if processes in the process compose is running.