Skip to content
This repository was archived by the owner on Feb 27, 2018. It is now read-only.
This repository was archived by the owner on Feb 27, 2018. It is now read-only.

Make boot2docker ip just output IP for easy use in scripts #310

@beorn

Description

@beorn

It's very useful to be able to get the boot2docker VM's IP and use it in scripts (to access docker containers that expose services on the docker host), and though there are two ways to do it now, both are convoluted and fickle:

  1. From $DOCKER_HOST:

% DOCKER_IP=echo $DOCKER_HOST | cut -d: -f2 | cut -c3-

  1. From boot2docker ip

% boot2docker ip
The VM's Host only interface IP address is: 192.168.59.103


This seems like a common use that that could be made much easier:

  1. Add a $DOCKER_IP env variable that contains the IP
  2. Make boot2docker ip just output the IP address

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions