-
Notifications
You must be signed in to change notification settings - Fork 2k
Proposed: save public and private IP of ec2 instances in config.json #629
Comments
Also, this could address #581 by making the IPAddress field be the private address if there was no public one. I propose that we augment config.json to look like this:
|
+1 |
is it ok if only ec2 machines have this added structure or would that cause angst/confusion? |
it's probably ok. |
It just depends on how we make it visible. |
so this is where i'm at right now:
i think it's fine that PrivateIP is at the same level as IPAddress because it's EC2 specific but so is AccessKey! |
SGTM Ultimately this is something I'd like to enforce for all drivers (assuming they have private IPs available). |
Should probably be part of #554 |
Fix #629 by adding PrivateIPAddress to config.json
I dectect this after restart my aws instance with docker-machine 0.0.1:
ip and env use the runtime amazon ip, but ssh the older one from config.json! It works at master branch... Nice, but now I need PR #770 right, to regenerate the cert?
Why machine doesn't update the config.json? |
@rossbachp this has been fixed as part of #770. thanks! |
Rethinking this, I'm not sure we should store IPs for hosts. We should find a way to query them from the hypervisor. |
@sthulb +1 -- that's exactly what |
@sthulb although some providers allocate a dedicated IP for the life cycle of the instance (i.e. digitalocean). |
Even still, I think we should query for them. |
This thread seems to have veered a bit from the original issue, but I wanted to chime in and say that my understanding / perspective is that one of the goals of this round of refactors is to make this the case. That way, the drivers don't have to poll for the IP address in |
@nathanleclaire +1 -- I think we are good with this as the follow-up comment has been addressed. |
to make it possible to use "machine inspect" to get the private IP it would be helpful if it was saved in config.json. Some systems like consul need to be configured to advertise the private IP and join gossip pools on the private IP space so this would make it easier to script the creation of a consul cluster created with machine.
The text was updated successfully, but these errors were encountered: