mirror of
https://github.com/k3s-io/kubernetes.git
synced 2026-01-06 07:57:35 +00:00
Add messages to indicate that opening an external firewall may be necessary.
This commit is contained in:
@@ -201,5 +201,15 @@ func RunExpose(f *cmdutil.Factory, out io.Writer, cmd *cobra.Command, args []str
|
||||
}
|
||||
}
|
||||
|
||||
if cmdutil.GetFlagBool(cmd, "create-external-load-balancer") {
|
||||
msg := fmt.Sprintf(`
|
||||
An external load-balanced service was created. On many platforms (e.g. Google Compute Engine),
|
||||
you will also need to explicitly open a firewall rule for the service port (%d) to serve traffic.
|
||||
|
||||
See https://github.com/GoogleCloudPlatform/kubernetes/tree/master/docs/services-firewall.md for more details.
|
||||
`, cmdutil.GetFlagInt(cmd, "port"))
|
||||
out.Write([]byte(msg))
|
||||
}
|
||||
|
||||
return f.PrintObject(cmd, object, out)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user