Skip to content

just frontend/init fails with cryptic error if plausible service isn't ready for requests #2489

Closed

Description

Description

$ just frontend/up
...
$ just frontend/init
env COMPOSE_PROFILES="frontend" just ../up 
env COMPOSE_PROFILES="frontend" docker-compose -f docker-compose.yml up -d
[+] Running 3/0
 ✔ Container openverse-plausible_db-1  Running                                                      0.0s 
 ✔ Container openverse-plausible_ch-1  Running                                                      0.0s 
 ✔ Container openverse-plausible-1     Running                                                      0.0s 

================================================================================
                                 Service Ports                                  
================================================================================
plausible (plausible/analytics):
-  http://0.0.0.0:50288 (→ 8000)
================================================================================
echo "🚧 TODO"
🚧 TODO
cd .. && ./setup_plausible.sh
--rpc-eval : RPC failed with reason :nodedown
error: Recipe `init` failed on line 66 with exit code 1

Reproduction

  1. `just down`
  2. `just frontend/up` and right after `just frontend/init`
  3. See the error above.

Fix

Add a "wait for" recipe that waits for Plausible to be available before running setup_plausible.sh similar to the docker/es/wait-for-index recipe.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Labels

Type

No type

Projects

  • Status

    ✅ Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions