A free short link service. Site : http://sl.ayang818.top
- TypeScript
- node
- MySQL
- Redis
- Docker
Install typescript
npm install -g typescript
Install necessary dependencies
npm install
Before running, make sure you have already started a MySQL Server(and created a database for this project) and a Redis Server.
Execute db.sql
in your MySQL.
Run with node
npm run serve
Run with docker
Build a docker image
docker build -t imageName:version .
Run a docker container
docker run -d --name myapp -p 3000:3000 -e REDIS_HOST=xxx -e REDIS_PASS=xxx -e REDIS_PORT=xxx -e MYSQL_HOST=xxx -e MYSQL_PORT=xxx -e MYSQL_USER=xxx -e MYSQL_PASSWORD=xxx -e MYSQL_DB=xxx imageName:version