@ -39,7 +39,6 @@ import (
// TranslateNodeToContainer translates a k3d node specification to a docker container representation
// TranslateNodeToContainer translates a k3d node specification to a docker container representation
func TranslateNodeToContainer ( node * k3d . Node ) ( * NodeInDocker , error ) {
func TranslateNodeToContainer ( node * k3d . Node ) ( * NodeInDocker , error ) {
/* initialize everything that we need */
/* initialize everything that we need */
containerConfig := docker . Config { }
containerConfig := docker . Config { }
hostConfig := docker . HostConfig {
hostConfig := docker . HostConfig {
@ -134,7 +133,6 @@ func TranslateContainerToNode(cont *types.Container) (*k3d.Node, error) {
// TranslateContainerDetailsToNode translates a docker containerJSON object into a k3d node representation
// TranslateContainerDetailsToNode translates a docker containerJSON object into a k3d node representation
func TranslateContainerDetailsToNode ( containerDetails types . ContainerJSON ) ( * k3d . Node , error ) {
func TranslateContainerDetailsToNode ( containerDetails types . ContainerJSON ) ( * k3d . Node , error ) {
// translate portMap to string representation
// translate portMap to string representation
ports := [ ] string { }
ports := [ ] string { }
for containerPort , portBindingList := range containerDetails . HostConfig . PortBindings {
for containerPort , portBindingList := range containerDetails . HostConfig . PortBindings {
@ -201,6 +199,7 @@ func TranslateContainerDetailsToNode(containerDetails types.ContainerJSON) (*k3d
Args : [ ] string { } , // empty, since Cmd already contains flags
Args : [ ] string { } , // empty, since Cmd already contains flags
Ports : ports ,
Ports : ports ,
Restart : restart ,
Restart : restart ,
Created : containerDetails . Created ,
Labels : labels ,
Labels : labels ,
Network : clusterNetwork ,
Network : clusterNetwork ,
ServerOpts : serverOpts ,
ServerOpts : serverOpts ,