Skip to content
This repository has been archived by the owner on Aug 27, 2022. It is now read-only.
/ shortener-web-v Public archive

A link shortening and plaintext store using the vweb framework, redis and vite!

License

Notifications You must be signed in to change notification settings

l1mey112/shortener-web-v

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

shortener-web-v

Backend for a simple url shortener and plaintext + temporary binary store using vweb and Redis. Frontend is created using typescript and built using vite.

Shortener website here! (s.l-m.dev)

API docs here! (blog.l-m.dev)

Requires

  • V install
  • NPM
  • Redis with default configuration

Compiling and running your own instance

Inside the main directory...

Running the project for development

fuser -k 8080/tcp # kill process on 8080 port
v watch --add "templates/" run .

Build simple binary

v up
sudo systemctl enable redis

cd public
npm install
cd ..
  # correct setup of all deps
  # npm deps for build
  # v updates
  # enable redis

./build/build-all.sh
  # this will build the vite project
  # then build the v binary after moving the correct files
./shortener-web-app

Build tar.gz package

# install deps ....

./build/package.sh
  # creates shortener-all.tar.gz