|
|
|
### Accessing shared app results in "Internal Server Error"
|
|
|
|
|
|
|
|
Make sure that you didn't place the `config/initializers/secret_token.rb` file in gitignore. The production logs might display an error like this if the secret_token was missing:
|
|
|
|
|
|
|
|
```
|
|
|
|
[ 2015-10-28 16:07:26.8184 6621/2ab4cfd81940 Pool2/Implementation.cpp:1274 ]: [App 23119 stderr] [ 2015-10-28 16:07:26.8183 23222/0x002b8963c826a8(Worker 1) utils.rb:74 ]: *** Exception RuntimeError in Rack application object (You must set config.secret_key_base in your app's config.) (process 23222, thread 0x002b8963c826a8(Worker 1)):
|
|
|
|
```
|
|
|
|
|
|
|
|
_There are many other reasons why "Internal Server Error" could occur when trying to launch the app. We'll continue to add solutions here as developers face them._
|
|
|
|
|
|
|
|
### Problem with app sharing results in error when accessing: Exception: AweSim::App::SetupScriptFailed
|
|
|
|
|
|
|
|
This means an exception was thrown when running `bin/setup-production` as the
|
|
|
|
user. This script is auto-generated when you share the app, unless you have
|
|
|
|
provided your own. It is run once each time the user launches the app from the
|
|
|
|
dashboard to setup the database (if it doesn't exist) and dataroot and verify that the user's existing database schema
|
|
|
|
is compatible with the app. It is idempotent which means the first time you run
|
|
|
|
it it setups the database and every time after that it does nothing except run
|
|
|
|
the verication(s).
|
|
|
|
|
|
|
|
There are several solutions for this exception: `Exception:
|
|
|
|
AweSim::App::SetupScriptFailed (Your database differs significantly from the app's schema)`
|
|
|
|
|
|
|
|
* revert the app to the previously shared version, then share the updated app as a new shared app (i.e. if I was sharing fillsim, I would share my updated version as fillsim_2)
|
|
|
|
* run the database migration on your outdated database yourself. cd into the shared app's directory and run `RAILS_ENV=production ruby bin/rake db:setup`. each user would have to manually do this themselves _we might provide a button to do this in the future_
|
|
|
|
* delete your data in the RAILS_DATAROOT for your app; then when you access it again the new database will be created
|
|
|
|
|
|
|
|
|
|
|
|
|