Config.json in my repo. How to edit before deployment ends?
hx4u
FREEOP

9 months ago

My config.json file in my repo contains placeholders for the user to put in their tokens. I don't know how to edit the config.json during the deployment phase. I don't want my tokens on my public repo because people would steal them. Please help me.

$10 Bounty

6 Replies

9 months ago

What's the goal here? Other people can use this JSON file to host their own copy of your GitHub repository?


hx4u
FREEOP

9 months ago

Yeah pretty much.


9 months ago

I believe templates are what you're looking for: https://docs.railway.com/reference/templates

You can create a template for your app and just share that.


hx4u
FREEOP

9 months ago

Well it's actually specifically more... This python program that hosts a connection (API) between c.ai (CharacterAI) and Discord.
If I want to host the connection for more than one AI "character" (which is a GPT3.5 AI that is pre-scripted to be unique) to Discord, where if added to any Discord server it will be responsive there, then I would run second instance of the program, with the tokens for the hosts CharacterAI account and specified AI, along with a history ID for memory redundancy, and a name for a voice pack.


hx4u
FREEOP

9 months ago

Why I need the config.json editable, and not shared with the configuration tokens in it, is because a different user could rip those tokens and control my bot...
So I'm just wondering, how would I edit the config.json file AFTER the program is downloaded during deployment, and BEFORE it is initiated during runtime.


9 months ago

Would variables fit the bill?


Loading...