Skip to content
/ minify Public

Simple service to allow minifying links with a backend admin page.

License

Notifications You must be signed in to change notification settings

mahirk/minify

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Link Minifier

A simple application to help minify links for an organization. Simply deploy this to your server and link it to your short url and watch the magic happen.

Simple Installation on server:

Terminal window 1:

You need to have redis-server to run this locally.

redis-server

ensure it's connected and keep this terminal open, or you can also run

redis-server --daemonize yes

if you want to kill the instance running in the background run:

kill $(ps aux | grep redis-server | grep -v grep | awk '{print $2}')

Terminal window 2:

Create your username and password.

redis-cli
select 1
set [username] [password]

You can close this terminal with a Ctrl - C command.

Terminal window 3:

git clone https://github.com/mahirk/minify.git
npm install
node app.minify.js

this will run the application. You want to keep this open. Alternatively, you can dockerize the service and run it or run it using the forever module on npm .

npm install forever
forever start app.minify.js

Endpoints

Public facing Routes

GET / : GOES TO /cp
GET /:mini : GETS THE MINIFIED LINK @ /:mini

Internal App Routes

GET /cp : CONTROL PANEL
GET /cp/all : ALL LINKS (RETURNS AN OBJECT) (requires a callback)
POST /cp/login : LOGIN PAGE
POST /generate: CREATE NEW LINK
DEL /:mini : DELETE LINK

Customization

The pages for the admin side can be modified to include the logo of the organization running the project. These files are available under /views/*.

License

This project follows the MIT License. In simple words, feel free to copy it and make it yours. All we ask is that you give us (Mahir Kothary) recognition for the project.

About

Simple service to allow minifying links with a backend admin page.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published