mirror of
https://github.com/crowdsecurity/crowdsec.git
synced 2025-05-11 20:36:12 +02:00
* fix #842 and move preflight checks tgth * handle new container name Co-authored-by: AlteredCoder <AlteredCoder>
This commit is contained in:
parent
1b39893fcf
commit
033c8e17e8
3 changed files with 42 additions and 21 deletions
|
@ -27,7 +27,7 @@ type Container struct {
|
|||
DockerGroupID string
|
||||
}
|
||||
|
||||
func NewContainer(listenAddr string, listenPort string, sharedFolder string, name string, image string, mbDBURI string, dockerGroupID string) (*Container, error) {
|
||||
func NewContainer(listenAddr string, listenPort string, sharedFolder string, containerName string, image string, mbDBURI string, dockerGroupID string) (*Container, error) {
|
||||
cli, err := client.NewClientWithOpts(client.FromEnv, client.WithAPIVersionNegotiation())
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to create docker client : %s", err)
|
||||
|
@ -37,7 +37,7 @@ func NewContainer(listenAddr string, listenPort string, sharedFolder string, nam
|
|||
ListenPort: listenPort,
|
||||
SharedFolder: sharedFolder,
|
||||
Image: image,
|
||||
Name: name,
|
||||
Name: containerName,
|
||||
CLI: cli,
|
||||
MBDBUri: mbDBURI,
|
||||
DockerGroupID: dockerGroupID,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue