sam-and-his-friends
v6.0.0
Published
An express application extrac discourse data from renzhen1024.com
Downloads
3
Readme
Sam And His Friends
Set Up In Local Dev
- Requirements: Node V8.0+, Yarn, Redis V5.0+
- Checkout source code:
$ git clone [email protected]:tningjs/sam-and-his-friends.git
- Install dependency:
$ yarn install
- Start server:
$ npm start
- Visit http://localhost:3000
How To Debug
$: npm run debug
- Open Chrome, go to
chrome://inspect/#devices
- Click "Inspect" in the Remote Target section (Notice: Cick the Node debug icon or click "Open dedicated DevTools for Node" not work for some version). This step should pause the process in the first line of source code, click continue in the debug tool.
- Open anther tab, go to
localhost:3000
, this step should pause the programm in thedebugger;
statement which you put in the code.
Deploy To Production
Auto deployment(CI) is configured using travis, the following is manual steps which similar to how CI is configured.
- Requirements: Node V8.0+, Yarn, Redis V5.0+, Process manager
- Checkout source code:
$ git clone [email protected]:tningjs/sam-and-his-friends.git
- Install dependency:
$ yarn install
- Build:
$ npm run build
- Go to repository:
$ cd <repository>
- Start server:
$ NODE_ENV=production pm2 start ./server.js
To check logs, use $ pm2 logs
.
Deploy A New Version To Production
- Find process ID by listing applications currently managed by PM2:
$ pm2 list
- Stop an application:
$ pm2 stop <app_name_or_id>
- Go to repository and build:
$ cd <repository> && git pull && yarn install && npm run build
- Start application again
$ NODE_ENV=production pm2 start ./server.js
Change log
The change log can be found on the Releases page.
Contributing
Everyone is welcome to contribute. Please take a moment to review the Contributing guidelines.
Authors and license
Tao Ning and contributors.
MIT License, see the included MIT-LICENSE.txt file.
Credits
- Layout design: Future Imperfect by Pixelarity
- 404 page: Saleh R. Qureshi. Codepen link
- Error page: @iremlopsum. Codepen link