diff --git a/README.md b/README.md index 282f58e..003009b 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,7 @@ $ curl -sL https://github.com/Uptimedog/Agent/releases/download/x.x.x/agent_x.x. Start the agent and it will auto register itself using your API key ```zsh -$ ./agent run --api_server uptimedog.io --api_key xxxxxxxx > agent.log +$ ./agent run --api_server https://uptimedog.io --api_key xxxxxxxx > agent.log ``` diff --git a/cmd/root.go b/cmd/root.go index 4d64e0f..a19584c 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -34,6 +34,13 @@ func init() { "", "Your Uptimedog API Key", ) + rootCmd.PersistentFlags().StringVarP( + &APIKey, + "api_server", + "a", + "https://uptimedog.io", + "Uptimedog remote server", + ) } // Execute runs cmd tool