Browse Source

Added a run script, updated the config for generic parameters updated the readme and configured the package.json file.

pull/9/head
jrtechs 5 years ago
parent
commit
a424e0e50e
4 changed files with 45 additions and 22 deletions
  1. +23
    -16
      README.MD
  2. +7
    -4
      conf.json
  3. +5
    -2
      package.json
  4. +10
    -0
      run.sh

+ 23
- 16
README.MD View File

@ -13,34 +13,41 @@ This web system enables users to log into the system and view videos using the b
- Easy to install - Easy to install
- Easily expandable and hackable to fit your needs - Easily expandable and hackable to fit your needs
# Installation
## NPM Dependencies
npm dependencies
```bash ```bash
npm install express --save
npm install fs --save
npm install express-session --save
npm install whiskers --save
npm install
``` ```
Dependencies
## System Dependencies
```bash ```bash
$apt-get install ffmpeg $apt-get install ffmpeg
``` ```
## Running
Codacs which don't work
H.265
MPEG-2 Video AC-3 (ATSC A/52)
To deploy this you will want to run this behind a reverse NGINX proxy to
allow you to encrypt all of the network traffic.
There are plenty of tutorials on how to do this online with let's encrypt.
Video but no audio
H.264 audio:AC-3 (ATSC A/52)
H.264 (Main Profile) AC-3 (ATSC A/52)
To run this program either run `run.sh` or execute `node server.js`. This
by default will run on port 5000 -- you are able to change this in `conf.json`.
To make this easier for you in the long run, I usually run my node applications
as [systemd](https://freedesktop.org/wiki/Software/systemd/) services.
Audio but no video:
H.265 (Main 10 Profile) MPEG-4 AAC
The default config provided in this project has the default username of admin and password
of admin.
You will want create a new admin user and remove the default one once you
get this running.
# Contributing
just work:
H.264 (High Profile), MPEG-4 AAC
This was largely just a weekend hack for me.
This currently fits most of my needs and is *functional*.
If you find any bugs, feel free to open a issue and I will get around to looking at it.
I am always looking for people to contribute to my projects.
If you have an idea for an enhancement for this project feel free to hack away and issue a PR.
Contact me using the form on my [blog](jrtechs.net) or by opening a github issue if you have any questions regarding the code or how to use this project.

+ 7
- 4
conf.json View File

@ -4,11 +4,14 @@
"users": [ "users": [
{ {
"username": "admin", "username": "admin",
"password": "7756626c84c37f25e29f48c10729e6d2947850f4030cb5811b297115bc0bcfe5",
"password": "f7c45eebc3710734d512d44e0fcbc9c075ee984eb0c1a2a4d89cd8dd38f608f7",
"id": 1, "id": 1,
"salt": "62f28310e1f0f2bdabeb6de07bb3943a980f4a9c6332c53c0a2a8eb684adcd4d",
"salt": "9162ff07513960398251d4a797e863b60d64048a6c550343cd56210dcea932ec",
"admin": true, "admin": true,
"api": "8ecf65673b6cb6673555f1213f08a3abf9264294b6d3d98a27f2745f0aaf1cbe"
"api": "e8d4fd1267e14660bde678be259b86af413be4aca234bafa773a7c9fd535e9e2"
} }
]
],
"serverURL": "http://localhost:5000",
"privateDir": "/home/jeff/private/videos",
"publicDir": "/home/jeff/public/videos"
} }

+ 5
- 2
package.json View File

@ -1,6 +1,6 @@
{ {
"name": "HomeBrewPlex",
"version": "0.1.0",
"name": "Home Brew Plex",
"version": "1.0.0",
"description": "Light weight alternative for Plex", "description": "Light weight alternative for Plex",
"main": "server.js", "main": "server.js",
"scripts": { "scripts": {
@ -18,8 +18,11 @@
}, },
"homepage": "https://github.com/jrtechs/HomeBrewPlex#readme", "homepage": "https://github.com/jrtechs/HomeBrewPlex#readme",
"dependencies": { "dependencies": {
"crypto": "^1.0.1",
"download-file": "^0.1.5", "download-file": "^0.1.5",
"express": "^4.16.4",
"express-session": "^1.15.6", "express-session": "^1.15.6",
"filepreview": "^1.0.16",
"fs": "0.0.2", "fs": "0.0.2",
"path": "^0.12.7", "path": "^0.12.7",
"url": "^0.11.0", "url": "^0.11.0",

+ 10
- 0
run.sh View File

@ -0,0 +1,10 @@
#!/bin/bash
# run - this script enters a infinite loop to ensure that the website does not go down if it
# hits any unexpected error that crashes Nodejs
#
# 2/13/18 Jeffery Russell
while true
do node server.js
done

Loading…
Cancel
Save