-
Notifications
You must be signed in to change notification settings - Fork 351
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Streamline app schema creation process #548
Comments
This would be really nice actually; currently when you deploy with Horizon cloud it pushes |
This needs a different name than "app schema", but this seems really useful for easy and predictable deployment. |
👍 Now that I finally understand the consequences of this design decision, I think that one should be able to provide a Would it be feasible (as you've suggested) to create |
It's not a super great idea since we can't just modify a toml file and write it back without clobbering comments. If we do #543 this would be an option |
So, Chris and I just ran through the "embedding Horizon" flow on the website. It's extremely non-obvious what to do. What happened was Horizon connected to RethinkDB and started spamming"error: Connection to RethinkDB terminated: Error: The databases horizon and horizon_internal do not exist.Run This flow is really bad. I'm not sure what the best way to fix it is, but it would be nice if Horizon set an empty schema automatically, or if not having a schema was a warning or something instead. |
There's a couple items out of this I propose:
Renaming is important as |
+1 for the change to I also think that by default |
this looks good, I think we all intuitively want the same thing |
What would be the correct way for |
I think only in dev mode. It seems like we should either
|
Right now you need to run set-schema before running
hz serve
without--dev
, or else you need to runhz serve --auto-create-collection
and query each table you want to set up the database. This isn't great, and makes non-dev mode really annoying.I was talking with @Tryneus and there are a couple options we thought of:
Proposal A
Have
hz init
take a connection option, and set up the database with the default users groups and rules that it does now at the time it sets up the app directoryProposal B
hz init
create aschema.toml
file somewhere in the directory (maybe inside.hz/
) with some simple default groups (and the admin group carte blanche rule).hz serve
to read and load this schema when it starts up, before starting to serve (this option would probably be part of--dev
)ping @mlucy @danielmewes @coffeemug @dalanmiller @encryptio
The text was updated successfully, but these errors were encountered: