Skip to content

Make the provisioner interface support more container runtimes #10883

Open
@afbjorklund

Description

@afbjorklund

Currently the libmachine interface is quite targetted towards Docker:

        // Do the actual provisioning piece:
        //     1. Set the hostname on the instance.
        //     2. Install Docker if it is not present.
        //     3. Configure the daemon to accept connections over TLS.
        //     4. Copy the needed certificates to the server and local config dir.
        //     5. Configure / activate swarm if applicable.
        Provision(swarmOptions swarm.Options, authOptions auth.Options, engineOptions engine.Options) error

It needs to at least know which runtime to install, during provisioning ?

And the swarmOptions and engineOptions need a generic replacement...


Currently the provisioner in minikube is broken, in that it doesn't provision.

It just assumes that all container runtimes are always present on the node.

The original provisioner would install Docker, if it was not already available:

const (
	DefaultEngineInstallURL = "https://get.docker.com"
)
func installDockerGeneric(p Provisioner, baseURL string) error {
        // install docker - until cloudinit we use ubuntu everywhere so we
        // just install it using the docker repos
        if output, err := p.SSHCommand(fmt.Sprintf("if ! type docker; then curl -sSL %s | sh -; fi", baseURL)); err != nil {
                return fmt.Errorf("error installing docker: %s", output)
        }

        return nil
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    co/generic-driverco/none-driverco/runtime/crioCRIO related issuesco/runtime/dockerIssues specific to a docker runtimehelp wantedDenotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.kind/featureCategorizes issue or PR as related to a new feature.lifecycle/frozenIndicates that an issue or PR should not be auto-closed due to staleness.priority/backlogHigher priority than priority/awaiting-more-evidence.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions