[PR #789] [MERGED] feat: add support for custom device hostname #13002

Closed
opened 2026-08-05 02:07:13 -04:00 by saavagebueno · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/netbirdio/netbird/pull/789
Author: @Thunderbottom
Created: 4/6/2023
Status: Merged
Merged: 4/20/2023
Merged by: @mlsmaycon

Base: mainHead: hostname-support


📝 Commits (4)

  • 9aae396 feat: add support for custom device hostname
  • 694d4db test: remove wrongly added cyclic dependency
  • d84ac15 chore: add hostname support to netbird login
  • 73f6582 lint: skip linting context value key with nolint

📊 Changes

10 files changed (+41 additions, -13 deletions)

View changed files

📝 client/cmd/login.go (+6 -0)
📝 client/cmd/root.go (+2 -0)
📝 client/cmd/up.go (+6 -0)
📝 client/system/info.go (+9 -0)
📝 client/system/info_android.go (+1 -9)
📝 client/system/info_darwin.go (+2 -1)
📝 client/system/info_freebsd.go (+2 -1)
📝 client/system/info_linux.go (+2 -1)
📝 client/system/info_test.go (+9 -0)
📝 client/system/info_windows.go (+2 -1)

📄 Description

Describe your changes

Adds support for --hostname (or -n) flag to be passed during netbird up, allowing users to set up a custom hostname for devices. Particularly helpful in cases where the device automatically logs into netbird on spawn, or in other cases for orchestration.

fixes https://github.com/netbirdio/netbird/issues/623

Checklist

  • Is it a bug fix
  • Is a typo/documentation fix
  • Is a feature enhancement
  • It is a refactor
  • Created tests that fail without the change (if possible)
  • Extended the README / documentation, if necessary

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/netbirdio/netbird/pull/789 **Author:** [@Thunderbottom](https://github.com/Thunderbottom) **Created:** 4/6/2023 **Status:** ✅ Merged **Merged:** 4/20/2023 **Merged by:** [@mlsmaycon](https://github.com/mlsmaycon) **Base:** `main` ← **Head:** `hostname-support` --- ### 📝 Commits (4) - [`9aae396`](https://github.com/netbirdio/netbird/commit/9aae396fb704c8623c3bbafe288f1a95d766f20b) feat: add support for custom device hostname - [`694d4db`](https://github.com/netbirdio/netbird/commit/694d4dbdd6e711e9d5d0fa184d4e19a5d865af3c) test: remove wrongly added cyclic dependency - [`d84ac15`](https://github.com/netbirdio/netbird/commit/d84ac15adab50710fee0208a29aa533819318a46) chore: add hostname support to netbird login - [`73f6582`](https://github.com/netbirdio/netbird/commit/73f65822e878ee9b9740afde87d7a06d350374ec) lint: skip linting context value key with nolint ### 📊 Changes **10 files changed** (+41 additions, -13 deletions) <details> <summary>View changed files</summary> 📝 `client/cmd/login.go` (+6 -0) 📝 `client/cmd/root.go` (+2 -0) 📝 `client/cmd/up.go` (+6 -0) 📝 `client/system/info.go` (+9 -0) 📝 `client/system/info_android.go` (+1 -9) 📝 `client/system/info_darwin.go` (+2 -1) 📝 `client/system/info_freebsd.go` (+2 -1) 📝 `client/system/info_linux.go` (+2 -1) 📝 `client/system/info_test.go` (+9 -0) 📝 `client/system/info_windows.go` (+2 -1) </details> ### 📄 Description ## Describe your changes Adds support for `--hostname` (or `-n`) flag to be passed during `netbird up`, allowing users to set up a custom hostname for devices. Particularly helpful in cases where the device automatically logs into netbird on spawn, or in other cases for orchestration. fixes https://github.com/netbirdio/netbird/issues/623 ## Issue ticket number and link ### Checklist - [ ] Is it a bug fix - [ ] Is a typo/documentation fix - [ ] Is a feature enhancement - [ ] It is a refactor - [ ] Created tests that fail without the change (if possible) - [ ] Extended the README / documentation, if necessary --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
saavagebueno added the pull-request label 2026-08-05 02:07:13 -04:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: DYNR/netbird#13002