Skip to content

A simple redirect service written using rust with axum

License

Notifications You must be signed in to change notification settings

harmless-tech/simple-redirect-service

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple Redirect Service

Getting Started

Add your redirects into a redirects.json file in the root directory with the format:

{
  "redirects": {
    "ID1": "FULL_URL",
    "ID2": "FULL_URL",
    "ID3": "FULL_URL"
  }
}

Using the docker container

docker run -p 3000:3000 --name "srs" --rm \
--mount type=bind,source="$(pwd)/redirects.json",target=/app/redirects.json \
quay.io/harmless-tech/simple-redirect-service:latest

Running

cargo run (--release)

Will run at http://localhost:3000 by default.

Building

cargo build (--release)