mirror of
https://github.com/kemko/nomad.git
synced 2026-01-06 18:35:44 +03:00
drivers: Create drivers/shared/structs
This creates a drivers/shared/structs package and moves the buffer size checks into it.
This commit is contained in:
@@ -23,8 +23,8 @@ import (
|
||||
shelpers "github.com/hashicorp/nomad/helper/stats"
|
||||
|
||||
"github.com/hashicorp/consul-template/signals"
|
||||
dstructs "github.com/hashicorp/nomad/client/driver/structs"
|
||||
cstructs "github.com/hashicorp/nomad/client/structs"
|
||||
dstructs "github.com/hashicorp/nomad/drivers/shared/structs"
|
||||
)
|
||||
|
||||
const (
|
||||
@@ -310,7 +310,7 @@ func (e *UniversalExecutor) Exec(deadline time.Time, name string, args []string)
|
||||
}
|
||||
|
||||
// ExecScript executes cmd with args and returns the output, exit code, and
|
||||
// error. Output is truncated to client/driver/structs.CheckBufSize
|
||||
// error. Output is truncated to drivers/shared/structs.CheckBufSize
|
||||
func ExecScript(ctx context.Context, dir string, env []string, attrs *syscall.SysProcAttr,
|
||||
name string, args []string) ([]byte, int, error) {
|
||||
cmd := exec.CommandContext(ctx, name, args...)
|
||||
|
||||
@@ -17,9 +17,9 @@ import (
|
||||
"github.com/hashicorp/consul-template/signals"
|
||||
hclog "github.com/hashicorp/go-hclog"
|
||||
multierror "github.com/hashicorp/go-multierror"
|
||||
dstructs "github.com/hashicorp/nomad/client/driver/structs"
|
||||
"github.com/hashicorp/nomad/client/stats"
|
||||
cstructs "github.com/hashicorp/nomad/client/structs"
|
||||
dstructs "github.com/hashicorp/nomad/drivers/shared/structs"
|
||||
"github.com/hashicorp/nomad/helper/discover"
|
||||
shelpers "github.com/hashicorp/nomad/helper/stats"
|
||||
"github.com/hashicorp/nomad/helper/uuid"
|
||||
|
||||
Reference in New Issue
Block a user