![]() | Name | Last modified | Size | Description |
---|---|---|---|---|
![]() | Parent Directory | - | ||
![]() | uploads/ | 2 years ago | - | |
![]() | README.md | 2 years ago | 2.9K | 0fb859dc fixed mobile overflwo options [كارل مبارك] |
![]() | data-2.db.bak | 2 years ago | 460K | 0fb859dc fixed mobile overflwo options [كارل مبارك] |
![]() | data-3.db.bak | 2 years ago | 524K | 0fb859dc fixed mobile overflwo options [كارل مبارك] |
![]() | data-4.db.bak | 2 years ago | 524K | 0fb859dc fixed mobile overflwo options [كارل مبارك] |
![]() | data-5.db.bak | 2 years ago | 524K | 0fb859dc fixed mobile overflwo options [كارل مبارك] |
![]() | data.db.bak | 2 years ago | 304K | 0fb859dc fixed mobile overflwo options [كارل مبارك] |
After last year, we never know what can happen. This directory contains the necessary database files and instructions to restore Pia's room.
Pia's room, its front-end, backend, and database are all contained in the parent directory. The directory has been compressed into piacw.zip on February 1, 2021 at 11:31.
This directory contains backups of Pia's room's database in the following structure:
data.db
file that describes the contents of the API as Pia had put them in. The original file was generated and is updated by the current running instance of Strapi. It can be found here. To back up this file, I just occasionally make a copy of the original and move it to this folder. The most recent back-up of data.db
is data-X.db.bak
, with the highest 'X'. Currently this is data-5.db.bak
.uploads
folder that contains the files that Pia uploaded to Strapi, including all images and their auto-generated size alternates. This folder was created by Strapi and is updated regularly. Its contents are always referenced by data.db
. The original uploads folder is here. I back up this folder by making a copy manually here: uploads
.Follow these instructions on the server that will host Pia's Room.
First, download and unpack the compressed project folder, piacw.zip, then:
cd piacw
Copy the most recent data-X.db.bak
file to Strapi's .tmp
directory:
cp backups/data-4.ddb.bak dev/pias-backend-2/.tmp/data.db
Copy the uploads
folder to Strapi's public directory:
cp -r backups/uploads dev/pias-backend-2/public/uploads
Start the back-end server (Strapi)
cd dev/pias-backend-2/
npm install
npm run develop
If everything looks ok, build and start Strapi.
NODE_ENV=production npm run build
NODE_ENV=production npm run start
Start the front-end server (Vue)
cd dev/final/
npm install
npm run serve
If everything looks ok, build the front-end.
npm run build
This generates a dist
directory containing the build files that can be served statically. At this point you need to configure two apache/nginx sites on the server. The first is api.piacw.com
, and needs to reverse proxy to the running Strapi server, most likely at localhost:1337
. The second is piacw.com
, and needs to point to the build files of the front-end by changing the web root to dev/final/dist
.
Finally, generate self-signed certificates for both sites and restart your server.
Pia's Room should be online at piacw.com and her CMS accessible at api.piacw.com.