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

Configure files with MAC address at boot #18

Open
brghena opened this issue Jan 20, 2017 · 1 comment
Open

Configure files with MAC address at boot #18

brghena opened this issue Jan 20, 2017 · 1 comment

Comments

@brghena
Copy link
Member

brghena commented Jan 20, 2017

Based on a discussion today, hostnames need to be unique on Berkeley's networks, which would require us to edit /etc/hostname on each gateway to include its MAC address.

It would be better if we could have the gateway automatically configure /etc/hostnames/ and /etc/sensu/conf.d/client.json on boot based on the MAC address. This would mean that the only personalization needed for each gateway would be /etc/network/interfaces to set the MAC address.

I think this can be done with a script that runs on boot after the filesystem has been initialized. The very first time, it would probably not affect the hostname early enough in the boot process to fix it, but the second boot (and thereafter) everything should work fine.
http://askubuntu.com/questions/500916/setting-hostname-on-startup

@bradjc
Copy link
Member

bradjc commented May 26, 2017

I want to add an optional script call to the end of first-install.sh, something like /opt/edison/first-install-umich.sh that would do things specific to a given version of the device. I need that for connecting to MWireless at least once so that NetworkManager will reconnect automatically in the future.

A future --berkeley flag could then enable first-install-berkeley.sh and do this at first boot.

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

2 participants