Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

chore: ensure coder is logged before querying orgs#15618

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
dannykopping merged 1 commit intomainfromdk/dev.sh
Nov 21, 2024

Conversation

dannykopping
Copy link
Contributor

#15603 and#13923 introduced steps intodevelop.sh which use thecoder CLI to execute queries (both for organizations, at it turns out).

However, these commands assume there's a value API token issued and used by the CLI. If not,develop.sh fails to start up with the following error:

/home/coder/coder/build/coder_2.17.2-devel+78f9f43c9_linux_amd64== CMD: /home/coder/coder/scripts/coder-dev.sh server --http-address 0.0.0.0:3000 --swagger-enable --dangerous-allow-cors-requests=true --enable-terraform-debug-mode== Waiting for Coder to become ready[API] Started HTTP listener at http://0.0.0.0:3000/[API] Using built-in PostgreSQL (/home/coder/coder/.coderv2/postgres)[API] Opening tunnel so workspaces can connect to your deployment. For production scenarios, specify an external access URL[API] ╔═══════════════════════════════════════════════╗[API] ║               View the Web UI:                ║[API] ║   https://4be2pat11602q.pit-1.try.coder.app/   ║[API] ╚═══════════════════════════════════════════════╝...Encountered an error running "coder organizations show", see "coder organizations show --help" for more informationerror: You are signed out or your session has expired. Please sign in again to continue.Suggestion: Try logging in using 'coder login'.== FAIL: Script encountered an error[API] Interrupt caught, gracefully exiting. Use ctrl+\ to force quit[API] Shutting down API server...[API] [API] Gracefully shut down API server...

We have"${PROJECT_ROOT}/.coderv2/developsh-did-first-setup" is used as a state file to indicate that the first user has been setup. This change forces this branch to always be followed if auth fails. If the first user already exists, it'll fail gracefully.

A future improvement to this would be to avoid trying to recreate the first (and regular) user.

Signed-off-by: Danny Kopping <danny@coder.com>
@dannykoppingdannykopping merged commitf38f746 intomainNov 21, 2024
28 checks passed
@dannykoppingdannykopping deleted the dk/dev.sh branchNovember 21, 2024 15:04
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@johnstcnjohnstcnjohnstcn approved these changes

Assignees

@dannykoppingdannykopping

Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants
@dannykopping@johnstcn

[8]ページ先頭

©2009-2025 Movatter.jp