diff options
| author | Pitu <[email protected]> | 2020-07-18 02:21:31 +0900 |
|---|---|---|
| committer | Pitu <[email protected]> | 2020-07-18 02:21:31 +0900 |
| commit | 2d06d918a154c15196ca92fb8f7873ca3c797f00 (patch) | |
| tree | 085c8998b86a0cb00ed3030124bfdf463d9ea4ef /docs | |
| parent | Updated TODO (diff) | |
| download | host.fuwn.me-2d06d918a154c15196ca92fb8f7873ca3c797f00.tar.xz host.fuwn.me-2d06d918a154c15196ca92fb8f7873ca3c797f00.zip | |
Timeout, package and docs cleanup
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/migrating.md | 14 | ||||
| -rw-r--r-- | docs/pm2.md | 11 |
2 files changed, 14 insertions, 11 deletions
diff --git a/docs/migrating.md b/docs/migrating.md new file mode 100644 index 0000000..a7d9eb7 --- /dev/null +++ b/docs/migrating.md @@ -0,0 +1,14 @@ +### Migrate from v3 to v4 +This version introduces a few breaking changes and updating requires some manual work. +For starters we recommend cloning the new version somewhere else instead of `git pull` on your v3 version. + +- After cloning move your `uploads` folder from the v3 folder to the new v4 folder. +- Then copy your `database/db` file from your v3 folder to the root of your v4 folder. +- You then need to run `yarn setup` or `npm start setup` from the v4 folder and finish the setup process. +- Once that's done you need to manually run `node src/api/databaseMigration.js` from the root folder of v4 +- After the migration finishes, the last step is to update your nginx config with the [newly provided script](./nginx.md) +- Restart nginx with `sudo nginx -s reload` +- And lastly start your lolisafe instance with `pm2 start pm2.json` + +### Known issues of migrating +- The thumbnails in the album view don't show up. That's because they don't exist, this will get solved as you upload new stuff so the newly uploaded files get the proper thumbnail created. diff --git a/docs/pm2.md b/docs/pm2.md deleted file mode 100644 index ac942fc..0000000 --- a/docs/pm2.md +++ /dev/null @@ -1,11 +0,0 @@ -## Setting up PM2 to run lolisafe - -The best way to keep the service running in case of crashes or unexpected issues is to attach the process to PM2 and forget about it. This also gives you the ability to dettach the process from your terminal and run it in the background, which is a must since lolisafe now comes in 2 separate processes. -The recommended way to set it up is to run the commands below, one for the API and the other for the site. - -``` -pm2 start npm --name "lolisafe-api" -- run api -pm2 start npm --name "lolisafe-site" -- run site -``` - -All set, if you want to check the logs you can `pm2 logs lolisafe-api` or similar. |