A nice pastebin based on hastebin.
245
A dev oriented pastebin like container for sharing code and text. A lot more usefull though, thanking John Crepezzi Paste your stuff however :)
docker run --name pastebin -p 80:80 jasonc/docker-pastebin
pastebin:
image: jasonc/docker-pastebin
For easy use the details are almost equal to the originals. You can find original configuration documentation at John's github page
Attempts to generate phonetic keys, similar to pwgen
{
"type": "phonetic"
}
Generates a random key
{
"type": "random",
"keyspace": "abcdef"
}
The optional keySpace argument is a string of acceptable characters for the key.
To use file storage (the default) change the storage section in config.js to something like:
{
"path": "./data",
"type": "file"
}
Where path represents where you want the files stored
To use redis storage you must install the redis package in npm
npm install redis
Once you've done that, your config section should look like:
{
"type": "redis",
"host": "localhost",
"port": 6379,
"db": 2
}
You can also set an expire option to the number of seconds to expire keys in. This is off by default, but will constantly kick back expirations on each view or post.
All of which are optional except type with very logical default values.
To use memcached storage you must install the memcache package via npm
npm install memcache
Once you've done that, your config section should look like:
{
"type": "memcached",
"host": "127.0.0.1",
"port": 11211
}
You can also set an expire option to the number of seconds to expire keys in. This behaves just like the redis expirations, but does not push expirations forward on GETs.
All of which are optional except type with very logical default values.
After starting the container you can navigate to 'targethost:targetport' and start using the bin via your browser.
Usually ruby is provided by OSX basic installation.
If your Linux Distro doesn't have ruby, you may want to install it. You should include the dev variant, as several games depend on them e.g.
apt-get install ruby-dev
yum install ruby-dev
After you ensure to have ruby installed use the following instruction.
gem install haste
cat file | haste
haste file
For those who don't like great ruby stuff - you may use following script as an alternative.
haste() { a=$(cat); curl -X POST -s -d "$a" http://hastebin.com/documents | awk -F '"' '{print "http://hastebin.com/"$4}'; }
Content type
Image
Digest
Size
258.3 MB
Last updated
over 7 years ago
docker pull jasonc/docker-pastebin