Short{Paste} logo

Short{Paste}

  •  0 ratings
In category: URL Shorteners

About Short{Paste}

A Go based URL shortener, pastebin and file uploader.

  •   492  
  •   0  
  •   0  
  •   0  
Github stats:
  •  Commits: N/A  
  •   N/A  
  •   N/A  
  •  Latest commit: N/A  

Deploy this app to RackNerd for $0.99/mo only!

Languages/Platforms/Technologies:
Lincenses:

More about Short{Paste}

Short{Paste}

Drone Build Status Docker pulls Docker Compose Go Report Demo on Heroku

Short{Paste} is open-source software written in Go and VueJS. It is a minimalistic shortener that combines three things that need shortening: links, files, and text. It is a self-hosted alternative to many popular services like paste bin and using dropbox to send a file to someone quickly.

The Go backend handles saving files, links, and text in DB and filesystem as needed, while the Vue UI provides a pretty view for you to add and review content. Added bonus, it tracks hit counts too!

Deployment

The whole backend packages to a single binary, and I bundled the app as a docker container based on alpine favored for its tiny size. To run this yourself, execute the command below.

docker run -d \
    -p 8080:8080 \
    -v ${PWD}/shortpaste/:/root/.shortpaste \
    adyanth/shortpaste:latest

The command will publish the application on port 8080, making it available on http://localhost:8080/ and use the bind-mounted folder called shortpaste in your current working directory to save the SQLite DB, the files, and texts published.

If you prefer docker-compose, here is an example deployment.

Build it yourself

With docker, you can build this yourself. A Dockerfile is provided at the root of this repository.

It uses a multi-stage build consisting of three stages:

  • Go Build : Builds a statically linked Go binary containing the backend API server and the static server.
  • Vue Build : Builds the VueJS UI to generate a dist folder with resources.
  • Container : Alpine container where the binary and dist are copied and served.

Environment Variables

You can customize the behavior using environment variables. Here is a list of configurable parameters.

Environment Variable Default Value Behaviour
SP_BIND_ADDR ":8080" Sets the bind-address inside the container.
PORT If set, it overrides the SP_BIND_ADDR to use the given port on all interfaces (support for Heroku deployment)
SP_STORAGE_PATH "~/.shortpaste" Sets the location for saving data inside the container.
SP_307_REDIRECT Setting this to anything causes a 307 redirect to be sent instead of showing the landing page for shortened links.
SP_USERNAME admin Sets the username to login to the UI (only applies to creating resources, links will still work fine)
SP_PASSWORD admin Sets the password to login to the UI (only applies to creating resources, links will still work fine)
SP_NOAUTH Setting this to anything bypasses authentication for creating resources.

Screenshots

Here are some screenshots to get a taste of it, see the demo for more :)

Type Create View
Links Link Upload Link View
Text Text Upload Text View
Files File Upload File View

Comments (0)

Please login to join the discussion on this project.

Short{Paste} Reviews (0)

Overall Rating

None

based on 0 ratings

Please login to review this project.

No reviews for this project yet.

↑ back to top

pCloud Lifetime

Popular Projects

FluxBB

in Social Networks and Forums
 37k    0    0    0  

Nextcloud

in File Transfer & Synchronization
 26k    1    1    0  

Dashboard

in Personal Dashboards
 9k    0    0    0  

Libreddit

in Social Networks and Forums
 8k    0    1    0  

Audiobookshelf

in Audio Streaming
 7k    0    1    0  

CasaOS

in Self-hosting Solutions
 6k    0    0    0  

Mediagoblin

in Photo and Video Galleries
 6k    0    0    0  

Most Discussed

Nextcloud

in File Transfer & Synchronization
 26k    1    1    0  

Tube Archivist

in Automation
 4k    0    1    0  

OneDev

in Project Management
 3k    0    0    0  

iodine

in Proxy
 2k    0    0    0  

Alf.io

in Booking and Scheduling
 3k    0    0    0  

sysPass

in Password Managers
 1k    0    0    0  

Misskey

in Social Networks and Forums
 3k    0    0    0  
Linux VPS from $11/yr.
RackNerd VPS for $11.38/mo

Top Rated Projects

Gitea

 1 rating
in Project Management

Bagisto

 1 rating
in E-commerce

LinkAce

 1 rating
in Bookmarks and Link Sharing

Pydio

 1 rating
in File Transfer & Synchronization

Audiobookshelf

 1 rating
in Audio Streaming

Nextcloud

 1 rating
in File Transfer & Synchronization

Seafile

 1 rating
in File Transfer & Synchronization

Categories

You May Also Be Interested In

Lstu logo
Lstu cover

Lstu

Lightweight URL shortener.

Shlink logo
Shlink cover

Shlink

URL shortener with REST API and command line interface. Inc…

Blink logo
Blink cover

Blink

Easy-to-host, SSO-integrated, CDN-powered link shortener (+…