-
Notifications
You must be signed in to change notification settings - Fork 2
DeployingToHeroku
Naohide Sano edited this page May 8, 2020
·
1 revision
- Dashboard (https://dashboard.heroku.com/apps/your-heroku-app) >> Heroku Postgres
- Heroku Postgres >> Settings >> View Credentials...
- Dashboard (https://dashboard.heroku.com/apps/your-heroku-app) >> Settings >> Reveal Config Vars
ONEDRIVE_CLIENT_ID=...
ONEDRIVE_CLIENT_SECRET=...
ONEDRIVE_REDIRECT_URL=https://your-heroku-app/redirect/microsoft
DROPBOX_CLIENT_ID=...
DROPBOX_CLIENT_SECRET=...
DROPBOX_REDIRECT_URL=https://your-heroku-app/redirect/dropbox
BOX_CLIENT_ID=...
BOX_CLIENT_SECRET=...
BOX_REDIRECT_URL=https://your-heroku-app/redirect/box
GOOGLEDRIVE_CLIENT_SECRET={"web":{"client_id":...,"redirect_uris":["https://your-heroku-app/redirect/google"]}}
WEBDAV_ADMIN_PASSWORD=...
WEBDAV_USER_PASSWORD=...
JDBC_DATABASE_URL=jdbc:postgresql:your-postgresql-server-address:port/your-postgresql-database
JDBC_USER_NAME=postgresql-account
JDBC_PASSWORD=postgresql-password
SPRING_PROFILES_ACTIVE=production
Make sure you have the Heroku CLI installed. Also, install the psql.
$ heroku pg:psql postgresql-flexible-99999 --app your-heroku-app
your-heroku-app::DATABASE=> CREATE TABLE IF NOT EXISTS credential (id VARCHAR(512) UNIQUE, token VARCHAR(2048));
your-heroku-app::DATABASE=> CREATE TABLE IF NOT EXISTS google (id VARCHAR(512) UNIQUE, credentials BYTEA);
your-heroku-app::DATABASE=> INSERT INTO google VALUES ('StoredCredential', NULL);
your-heroku-app::DATABASE=> INSERT INTO credential VALUES ('onedrive:your_account@hotmail.com', NULL);
your-heroku-app::DATABASE=> INSERT INTO credential VALUES ('googledrive:your_account@gmail.com', NULL);
your-heroku-app::DATABASE=> INSERT INTO credential VALUES ('box:your_account@box.com', NULL);
your-heroku-app::DATABASE=> INSERT INTO credential VALUES ('dropbox:your_account@dropbox.com', NULL);
:
$ heroku create
$ git push heroku master
$ heroku open