Skip to content

Commit a63aff4

Browse files
[breaking] Remove ip flag from daemon command (#2045)
* Remove `ip` flag from daemon command * Update UPGRADING.md
1 parent 1962996 commit a63aff4

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

Diff for: docs/UPGRADING.md

+5
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,11 @@ Here you can find a list of migration guides to handle breaking changes between
44

55
## 0.30.0
66

7+
### `daemon` CLI command's `--ip` flag removal
8+
9+
The `daemon` CLI command no longer allows to set a custom ip for the gRPC communication. Currently there is not enough
10+
bandwith to support this feature. For this reason, the `--ip` flag has been removed.
11+
712
### `board attach` CLI command changed behaviour
813

914
The `board attach` CLI command has changed behaviour: now it just pick whatever port and FQBN is passed as parameter and

Diff for: internal/cli/daemon/daemon.go

+1-2
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ import (
3939

4040
var (
4141
tr = i18n.Tr
42-
ip string
4342
daemonize bool
4443
debug bool
4544
debugFile string
@@ -56,7 +55,6 @@ func NewCommand() *cobra.Command {
5655
Args: cobra.NoArgs,
5756
Run: runDaemonCommand,
5857
}
59-
daemonCommand.PersistentFlags().StringVar(&ip, "ip", "127.0.0.1", tr("The IP address the daemon will listen to"))
6058
daemonCommand.PersistentFlags().String("port", "", tr("The TCP port the daemon will listen to"))
6159
configuration.Settings.BindPFlag("daemon.port", daemonCommand.PersistentFlags().Lookup("port"))
6260
daemonCommand.Flags().BoolVar(&daemonize, "daemonize", false, tr("Do not terminate daemon process if the parent process dies"))
@@ -120,6 +118,7 @@ func runDaemonCommand(cmd *cobra.Command, args []string) {
120118
go feedback.ExitWhenParentProcessEnds()
121119
}
122120

121+
ip := "127.0.0.1"
123122
lis, err := net.Listen("tcp", fmt.Sprintf("%s:%s", ip, port))
124123
if err != nil {
125124
// Invalid port, such as "Foo"

0 commit comments

Comments
 (0)