Skip to content
This repository was archived by the owner on Aug 30, 2024. It is now read-only.

Add retries to coder agent start cmd #316

Merged
merged 2 commits into from
Apr 16, 2021
Merged

Add retries to coder agent start cmd #316

merged 2 commits into from
Apr 16, 2021

Conversation

f0ssel
Copy link
Contributor

@f0ssel f0ssel commented Apr 15, 2021

This organizes the code to into a new agent pkg, in hopes we can share some code with the coder repo as well when the time comes.

I wrap the main server in a retry loop to make sure the agent is always running (if it get's passed the input parsing in the command)

@@ -60,7 +50,7 @@ coder agent start --coder-url https://my-coder.com --token xxxx-xxxx

if coderURL == "" {
var ok bool
token, ok = os.LookupEnv("CODER_URL")
coderURL, ok = os.LookupEnv("CODER_URL")
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was a bug

@f0ssel f0ssel merged commit 2b0af5a into master Apr 16, 2021
@f0ssel f0ssel deleted the p2p-retry branch April 16, 2021 19:40
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants