Skip to content

Simple and lightweight web service for shortening URLs

License

Notifications You must be signed in to change notification settings

shibijm/slimlink

Repository files navigation

Slimlink

Slimlink is a simple and lightweight web service for shortening URLs.

Latest Release Build Status Deployment Status

Usage

A public demo instance is hosted at l.shjm.in.

To host your own instance, you can use Docker or download a build from the releases page.

Configuration - Environment Variables

  • BIND_ADDRESS (default: 0.0.0.0)
  • BIND_PORT (default: 44558)
  • LINK_ID_LENGTH (default: 5, min: 1, max: 64) - Length of each random Base62 string which gets generated for use in shortened URLs. 916 million (625) possibilities when set to 5.
  • REDIS_CONNECTION_STRING (format: redis://USERNAME:PASSWORD@HOST:PORT)
  • MYSQL_CONNECTION_STRING (format: USERNAME:PASSWORD@tcp(HOST:PORT)/DATABASE_NAME)
  • PAGE_FOOTER_TEXT (optional) - Text to be displayed at the bottom-left corner of the main page.

Environment variables will be automatically loaded from a .env file if one exists in the program's working directory.

Only one of the database connection strings must be set.