From bf0a7ebee72404eb7bce918f41162126bca24bf0 Mon Sep 17 00:00:00 2001 From: David Mehren Date: Sat, 6 Mar 2021 10:34:22 +0100 Subject: Remove .sequelizerc After https://github.com/hedgedoc/hedgedoc/pull/969 was merged, a separate configuration file for the sequelize-cli is no longer required. Signed-off-by: David Mehren --- .sequelizerc.example | 8 -------- bin/heroku | 12 ------------ bin/setup | 5 ----- docs/content/setup/manual-setup.md | 8 ++------ 4 files changed, 2 insertions(+), 31 deletions(-) delete mode 100644 .sequelizerc.example diff --git a/.sequelizerc.example b/.sequelizerc.example deleted file mode 100644 index 29a0d145..00000000 --- a/.sequelizerc.example +++ /dev/null @@ -1,8 +0,0 @@ -var path = require('path'); - -module.exports = { - 'config': path.resolve('config.json'), - 'migrations-path': path.resolve('lib', 'migrations'), - 'models-path': path.resolve('lib', 'models'), - 'url': 'change this' -} \ No newline at end of file diff --git a/bin/heroku b/bin/heroku index c5ca1f8a..908ea4eb 100755 --- a/bin/heroku +++ b/bin/heroku @@ -2,18 +2,6 @@ set -e -cat << EOF > .sequelizerc -var path = require('path'); - -module.exports = { - 'config': path.resolve('config.json'), - 'migrations-path': path.resolve('lib', 'migrations'), - 'models-path': path.resolve('lib', 'models'), - 'url': process.env.DATABASE_URL -} - -EOF - cat << EOF > config.json { diff --git a/bin/setup b/bin/setup index 0f1edca0..9b673f71 100755 --- a/bin/setup +++ b/bin/setup @@ -46,10 +46,6 @@ if [ ! -f config.json ]; then cp config.json.example config.json fi -if [ ! -f .sequelizerc ]; then - cp .sequelizerc.example .sequelizerc -fi - echo "Installing packages..." yarn install --pure-lockfile yarn install --production=false --pure-lockfile @@ -61,7 +57,6 @@ Edit the following config file to setup HedgeDoc server and client. Read more info at https://github.com/hedgedoc/hedgedoc#configuration-files * config.json -- HedgeDoc config -* .sequelizerc -- db config EOF # change directory back diff --git a/docs/content/setup/manual-setup.md b/docs/content/setup/manual-setup.md index d09eadc8..4d03b752 100644 --- a/docs/content/setup/manual-setup.md +++ b/docs/content/setup/manual-setup.md @@ -24,12 +24,8 @@ 4. Modify the file named `config.json` or configure HedgeDoc through environment variables which will overwrite the configs, see docs [here](../configuration.md). 5. **If using the release tarball for 1.7.0 or newer, this step can be skipped.** Build the frontend bundle by `yarn run build` (use `yarn run dev` if you are in development) -6. Modify the file named `.sequelizerc`, change the value of the variable `url` to your db connection string. For example: - - `postgres://username:password@localhost:5432/hedgedoc` - - `mysql://username:password@localhost:3306/hedgedoc` - - `sqlite:///opt/hedgedoc/hedgedoc.sqlite` (note that you need to use an absolute path to the SQLite file) -7. It is recommended to start your server manually once: `NODE_ENV=production yarn start`, this way it's easier to see warnings or errors that might occur (leave out `NODE_ENV=production` for development). -8. Run the server as you like (node, forever, pm2, SystemD, Init-Scripts) +6. It is recommended to start your server manually once: `NODE_ENV=production yarn start`, this way it's easier to see warnings or errors that might occur (leave out `NODE_ENV=production` for development). +7. Run the server as you like (node, forever, pm2, SystemD, Init-Scripts) ## How to upgrade your installation -- cgit v1.2.3 From 73a83f3ed6adbe172831d550805842072674085a Mon Sep 17 00:00:00 2001 From: David Mehren Date: Sat, 6 Mar 2021 10:35:34 +0100 Subject: Add release notes entry for #969 Signed-off-by: David Mehren --- public/docs/release-notes.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/public/docs/release-notes.md b/public/docs/release-notes.md index a58018c2..b12644a2 100644 --- a/public/docs/release-notes.md +++ b/public/docs/release-notes.md @@ -1,4 +1,9 @@ # Release Notes +## 1.8.0 UNRELEASED +### Features +- Database migrations are now automatically applied on application startup. + The separate `.sequelizerc` configuration file is no longer necessary and can be safely deleted. + ## 1.7.2 2021-01-15 This release fixes a security issue. We recommend upgrading as soon as possible. ### Security Fixes -- cgit v1.2.3 From 4e5ff6f075b631e35b879c136279d0bafeacfa5b Mon Sep 17 00:00:00 2001 From: David Mehren Date: Sat, 6 Mar 2021 10:36:24 +0100 Subject: Update link to config docs in setup script Signed-off-by: David Mehren --- bin/setup | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/setup b/bin/setup index 9b673f71..43df07ff 100755 --- a/bin/setup +++ b/bin/setup @@ -54,7 +54,7 @@ cat << EOF Edit the following config file to setup HedgeDoc server and client. -Read more info at https://github.com/hedgedoc/hedgedoc#configuration-files +Read more info at https://docs.hedgedoc.org/configuration/ * config.json -- HedgeDoc config EOF -- cgit v1.2.3