Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

local_ip() does not recognize or return a static ip #140

Open
nsmith-globus opened this issue Jul 16, 2024 · 0 comments
Open

local_ip() does not recognize or return a static ip #140

nsmith-globus opened this issue Jul 16, 2024 · 0 comments

Comments

@nsmith-globus
Copy link

I've been using local_ip() to get the ip address of an ubuntu 22 server that has been running with a DHCP assigned ip address (ethernet), which works perfectly. Recently I've assigned a static ip to the server when it is directly connected to a windows device, and when it's in that configuration, calling local_ip() on the server returns the IP broadcast by docker (a 172.x.x.x ip).

All network communication between the two attached devices with static ip set is normal.

NIC dynamic -> router: DHCP ipv4 (as expected)
NIC w/ static -> windows computer: docker0 ipv4 (expecting to receive static ip)

Network configuration:
Configured via NetworkManager, tries for DHCP, and falls back to static ip. Static IP is a link-local address 169.254.x.x.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant