It looks like it works, and I can see the monitoring indicating that the application is up and running, but I cannot connect to my Redis instance from my machine, and I always get this error message:
$ redis-cli -u 'redis://pr-pullrequest-redis.fly.dev'
Could not connect to Redis at pr-pullrequest-redis.fly.dev:6379: nodename nor servname provided, or not known
not connected>
Could you help me with an idea about what I am doing wrong?
Note that this way, your Redis instance will be exposed to the internet.
Have you considered using Upstash for Redis instead? Using the default pay-as-you-go plan, you should incur a lower cost, less operational overhead, and keep the database private.
Creating and destroying Upstash databases is easy using fly redis create and fly redis destroy.
Also, check out this Github action which doesn’t support Upstash Redis, but could be modified to do so. Since you need RedisJSON, you could follow the Redis example in the README.
I used the action to install a Redis image, and it works too. However, I’m encountering the same issue: the server is not reachable from my machine or any other machines. I can only access the Redis instance if I SSH into the machine.
By the way, Upstash does support JSON so I’d recommend using that over a Redis instance. In both cases, you’d have to access it using the private IPv6 IP address. It would be great if you added Upstash support to the PR review app repo