How can I install Directus extension to my project?
Hi! I'm using this template: https://railway.app/template/2fy758 and I would like to add an extension to my directus project. I have to use
npm i directus-extension-sync
in order to install it. How can I achieve this? Thank you so much!Solution:Jump to solution
add that dockerfile to a gh repo, remove the image from your railway service, then add the repo to the service instead
27 Replies
Project ID:
N/A
N/A
@Medim - what would be the best way to do this?
Extensions are a bad spot for this template atm (next week Directus Leap Week may change this), unfortunately you will need to create your own dockerfile/repo with directus and the extensions you want
I've already created it
How I can use it?
add the extension to your package.json and place the files on the extensions folder at the root of your project
oh no I mean I have the dockerfile
It is working on local
then deploy that
Idk how to do it, I kind of new in docker and railway
Solution
add that dockerfile to a gh repo, remove the image from your railway service, then add the repo to the service instead
Does it need the docker-compose file?
nope, railway does not support docker-compose
Ok thank you, I'm gonna try
railway will use your Dockerfile that you have shown
I have replaced the source of my Directus Service with my repo but nothing changed, it is still using the directus image from Dockerhub
screenshot of the source settings please
interesting, did you hit the deploy button?
Yes
Multiple times
multiple times?
I have redeploy multiple times I mean ahah
the 3 dot menu's redeploy button is not what im talking about
Oh it seems to work now that I have added a root directory
Oh I don t know what you are talking about then
you would have been shown this
Oh yes
I did
you are right, it doesnt auto deploy the repo after you change it
thats not ideal
Thank you so much it is working right now