-
Notifications
You must be signed in to change notification settings - Fork 38
Self hosted frontend still try to connect api.bullet-train.io/api/v1/flags/ #18
Comments
Hey, glad you like the project! I think the reason for this is quite straight forward. Although you are calling your API in order for the frontend to function, this project also uses the Bullet Train SDK in order to control what features are visible to the frontend (See bulletTrain in project.js, this is an environment key straight from bullet-train.io). These calls you are seeing are those to bullet train from the js client in order to see what features to show. https://github.com/BulletTrainHQ/bullet-train-frontend/blob/master/common/stores/config-store.js Is where this is managed. |
You can switch this to use your stack entirely by creating a project in your infrastructure and replicate the flags mentioned in the readme (https://gist.github.com/kyle-ssg/4c65b4185d0fe3ae35f73244de5e2fef), then update the bulletTrain key in project.js and update bulletTrain.init in the project to use your api
Edit: Pinning issue, think that documentation could be improved here to clear up confusion. |
Thanks @kyle-ssg, I don't know which part going wrong, I have tried set the API_URL env variable, update the Is there any js files I need to re-build? |
I got it sorted, thank you for pointing me the file: https://github.com/BulletTrainHQ/bullet-train-frontend/blob/master/common/stores/config-store.js, I specify |
Hi bullet-train developers, it is a great project.
I am try to run bullet-train-api and bullet-train-frontend locally, and I edited the file
env/project_dev.js
api
to my local server in bullet-train-frontend and run it usingnpm run dev
.Most of the functions seem working fine, except I found it keep calling https://api.bullet-train.io/api/v1/flags/ to retrieve feature flags. May I know which part of the config I am missing, so that it can get the flags from my local server?
The text was updated successfully, but these errors were encountered: