Skip to content
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.

Support deployment to remote Docker Hosts #627

Closed
tomwillfixit opened this issue Oct 19, 2020 · 2 comments · Fixed by #631
Closed

Support deployment to remote Docker Hosts #627

tomwillfixit opened this issue Oct 19, 2020 · 2 comments · Fixed by #631
Labels
enhancement New feature or request plugin/docker

Comments

@tomwillfixit
Copy link

Is your feature request related to a problem? Please describe.

I would like to deploy my containerized app to a remote Docker Host or Docker Swarm cluster.

Describe the solution you'd like

Something like this in waypoint.hcl to allow the deploy to happen to a remote host :

deploy { 
    use "docker" {
        remote_host=ssh://docker@your_server_ip
    }
  }

Support for Docker Swarm may be more complicated and out of scope of this request since Waypoint would need to support service creation, resource allocation etc.

Describe alternatives you've considered

Setting the DOCKER_HOST environment variable may work as is but I need to try it out.

Explain any additional use-cases

Docker Compose is very popular amongst developers for starting local and remote stacks, supporting remote docker hosts may make that easier using Waypoint.

Additional context

@nicholasjackson nicholasjackson linked a pull request Oct 19, 2020 that will close this issue
@nicholasjackson
Copy link
Contributor

nicholasjackson commented Oct 19, 2020

@tomwillfixit I have added this functionality in the following PR:

#631

I think for a more comprehensive Docker Swarm integration we should probably create a specific plugin.

@josephlim75
Copy link

For a workaround, can we execute the following ?, Of course docker environment need to be set beforehand, DOCKER_HOST, DOCKER_CERT_PATH, and DOCKER_TLS_VERIFY

deploy {
  use "exec" {
    command = ["docker", "stack", "deploy", "-c", "<TPL>", "stackname"]

  template {
    path = "./template/docker-compose.yaml"
  }
 }
}

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request plugin/docker
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants