GithubHelp home page GithubHelp logo

cloud-ca / docker-machine-driver-cloudca Goto Github PK

View Code? Open in Web Editor NEW
1.0 7.0 2.0 4.24 MB

Docker machine driver for cloud.ca

License: MIT License

Makefile 7.96% Go 89.96% Shell 2.08%
docker-machine docker-machine-driver cloud cloud-ca

docker-machine-driver-cloudca's People

Contributors

franzpgarcia avatar pdion891 avatar pdube avatar prollynomial avatar simongodard avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

docker-machine-driver-cloudca's Issues

Use SNAT instead of PortForwading for adding hosts

Currently, we cannot provision hosts from public IPs on Rancher. The default flow is to have public IPs and because some of the port forwarding rules are missing, Rancher fails to provision the host correctly. You would have to check the Private IP flag and change the settings for the provision host which is not straight-forward.

One solution is to use static NAT instead of port-forwarding so that any port that is open, gets exposed correctly.

CoreOS docker daemon not restarted after reboot

When CoreOS is deployed using docker-machine-driver-cloudca, after an automatic upgrade of CoreOS, docker daemon is not restarted by default, default behavior of CoreOS.

Maybe we should push the command via cloud-init

echo "docker ps" >> /etc/rc.local

as describe in rancher/rancher#5069

Specifying network by VPC name and network name

The only UUID in the list of parameters is --cloudca-network-id ($CLOUDCA_NETWORK_ID).

It could be more user friendly to split this into 2 options that have names. This would allow us to provide default values for 4 different options, and would help customers getting started in a trial environment, as all of the names are standardized (i.e. compute-on / test_area / default-vpc / Frontend).

bad user-data to configure data-drive.

The user-data pushed by the driver as cloud-init config is not good.

user-data sent is

#!/bin/sh
mkfs -t ext4 /dev/xvdb
mkdir -p /var/lib/docker
mount -t ext4 /dev/xvdb /var/lib/docker

The data volume is not remounted automatically after a reboot, and on CoreOS, the volume is formated at each reboot, which is dangerous because coreos will reboot automatically after a channel upgrade.

Good cloud-init configuration for coreos, ubuntu and centos:
Tested on ubuntu16.04 and coreos:

#cloud-config
fs_setup:
   - label:  data
     filesystem: 'ext4'
     device: '/dev/xvdb'
mounts:
 - [ xvdb, /var/lib/docker, "ext4", "defaults", "0", "0" ]
coreos:
  units:
    - name: format-datavolume.service
      command: start
      content: |
        [Unit]
        Description=Formats the data volume
        After=dev-xvdb.device
        Requires=dev-xvdb.device
        ConditionPathExists=!/var/lib/docker.btrfs
        [Service]
        Type=oneshot
        RemainAfterExit=yes
        ExecStart=/usr/sbin/mkfs.btrfs /dev/xvdb
        ExecStart=/usr/bin/mkdir /var/lib/docker.btrfs
    - name: var-lib-docker.mount
      command: start
      content: |
        [Unit]
        Description=Mount data volume to /var/lib/docker
        Requires=format-datavolume.service
        After=format-datavolume.service
        [Mount]
        What=/dev/xvdb
        Where=/var/lib/docker
        Type=btrfs
    - name: docker.service
      drop-ins:
        - name: 10-wait-docker.conf
          content: |
            [Unit]
            After=var-lib-docker.mount
            Requires=var-lib-docker.mount

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.