You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// Copyright (c) 2022 Gitpod GmbH. All rights reserved.
2
+
// Licensed under the GNU Affero General Public License (AGPL).
3
+
// See License.AGPL.txt in the project root for license information.
4
+
5
+
package cmd
6
+
7
+
import (
8
+
"fmt"
9
+
"os"
10
+
11
+
"github.com/gitpod-io/gitpod/common-go/log"
12
+
api "github.com/gitpod-io/gitpod/gitpod-protocol"
13
+
"github.com/sirupsen/logrus"
14
+
"github.com/spf13/cobra"
15
+
)
16
+
17
+
varusersCmd=&cobra.Command{
18
+
Use: "users",
19
+
Short: "Interact with Public API services",
20
+
}
21
+
22
+
varusersCmdOptsstruct {
23
+
addressstring
24
+
insecurebool
25
+
tokenstring
26
+
}
27
+
28
+
funcinit() {
29
+
rootCmd.AddCommand(usersCmd)
30
+
31
+
usersCmd.PersistentFlags().StringVar(&usersCmdOpts.address, "address", "wss://gitpod.io/api/v1", "Address of the API endpoint. Must be in the form <host>:<port>.")
32
+
usersCmd.PersistentFlags().BoolVar(&usersCmdOpts.insecure, "insecure", false, "Disable TLS when making requests against the API. For testing purposes only.")
33
+
usersCmd.PersistentFlags().StringVar(&usersCmdOpts.token, "token", os.Getenv("GPCTL_API_TOKEN"), "Authentication token to interact with the API")
0 commit comments