client/lxd_containers.go
func (r *ProtocolLXD) CreateContainer(container api.ContainersPost) (Operation, error) {
	if container.Source.ContainerOnly {
		if !r.HasExtension("container_only_migration") {
			return nil, fmt.Errorf("The server is missing the required \"container_only_migration\" API extension")
		}
	}

	// Send the request
	op, _, err := r.queryOperation("POST", "/containers", container, "")
	if err != nil {
		return nil, err
	}

	return op, nil
}
func (r *ProtocolLXD) CreateContainer(container api.ContainersPost) (Operation, error) {
	if container.Source.ContainerOnly {
		if !r.HasExtension("container_only_migration") {
			return nil, fmt.Errorf("The server is missing the required \"container_only_migration\" API extension")
		}
	}

	// Send the request
	op, _, err := r.queryOperation("POST", "/containers", container, "")
	if err != nil {
		return nil, err
	}

	return op, nil
}
func ( r * ProtocolLXD ) CreateContainer ( container api . ContainersPost ) ( Operation , error ) { if container . Source . ContainerOnly { if ! r . HasExtension ( " " ) { return nil , fmt . Errorf ( " \" \" " ) } } // Send the request op , _ , err := r . queryOperation ( " " , " " , container , " " ) if err != nil { return nil , err } return op , nil }
// CreateContainer requests that LXD creates a new container
CreateContainer requests that LXD creates a new container