Host OpenFGA | No Template Available
deoxy
PROOP

5 months ago

Docs: https://openfga.dev/
https://openfga.dev/docs/getting-started/setup-openfga/docker

It requires some commands to be ran after the container starts, not sure how to do it in railway.

Solved$40 Bounty

16 Replies

deoxy
PROOP

5 months ago

N/A


noahd
EMPLOYEE

5 months ago

Based on which commands there is a post build command that can be executed in container


deoxy
PROOP

5 months ago

`/bin/sh -ecx \"exec openfga run --datastore-engine postgres --datastore-uri $OPENFGA_DATASTORE_URI\"`
I tried this as custom startup command but it fails to start
did this based on https://docs.railway.com/guides/start-command

Attachments


turborx
FREE

5 months ago

hi, you can’t run extra commands after startup on railway directly, but you can stitch them into your start command or use a postdeploy script in railway.json. for example:

{

"start": "/bin/sh -ecx \"openfga migrate --datastore-engine postgres --datastore-uri $OPENFGA_DATASTORE_URI && exec openfga run --datastore-engine postgres --datastore-uri $OPENFGA_DATASTORE_URI\""

}

then redeploy and it’ll migrate first, then start the server.


aaguiarz
HOBBY

5 months ago

I just created one here https://railway.com/deploy/openfga, let me know if that works for you


aaguiarz
HOBBY

5 months ago

I configured with:

pre-deploy command: ./openfga migrate

custom start command: ./openfga run


aaguiarz

I just created one here https://railway.com/deploy/openfga, let me know if that works for you

brody
EMPLOYEE

5 months ago

Hey,

Do you think you could take a look at our best practices page and update your template accordingly?

https://docs.railway.com/guides/templates-best-practices


brody

Hey,Do you think you could take a look at our best practices page and update your template accordingly?https://docs.railway.com/guides/templates-best-practices

aaguiarz
HOBBY

5 months ago

Sure! Looking at the list, it seems I missed describing the input variable for authentication. Is there anything else I missed?


aaguiarz

Sure! Looking at the list, it seems I missed describing the input variable for authentication. Is there anything else I missed?

brody
EMPLOYEE

5 months ago

  • Template and Service Icons

  • Naming Conventions

  • Health Checks


brody

Template and Service IconsNaming ConventionsHealth Checks

aaguiarz
HOBBY

5 months ago


brody
EMPLOYEE

5 months ago

The OpenFGA service does not have an icon at this time.


aaguiarz

I just created one here https://railway.com/deploy/openfga, let me know if that works for you

deoxy
PROOP

5 months ago

That Worked, Thank you


brody

The OpenFGA service does not have an icon at this time.

aaguiarz
HOBBY

5 months ago

Thanks, I found how to change it (not super obvious :)). Let me know if if looks good


brody
EMPLOYEE

5 months ago

Looks like it is missing a health check?


Status changed to Awaiting User Response Railway 5 months ago


brody

Looks like it is missing a health check?

aaguiarz
HOBBY

5 months ago

Should be ready now


Status changed to Awaiting Railway Response Railway 5 months ago


brody
EMPLOYEE

5 months ago

Awsome.

Thank you for the template, and thank you for putting up with all my nits!

The $40 bounty has been awarded to you.


Status changed to Awaiting User Response Railway 5 months ago


Status changed to Solved brody 5 months ago


Loading...