elementsproject / filebazaar Goto Github PK
View Code? Open in Web Editor NEWSell digital files with Bitcoin & Lightning :zap:
Home Page: https://blockstream.com/2018/03/22/filebazaar-joins-the-lightning-charge-lapps.html
License: MIT License
Sell digital files with Bitcoin & Lightning :zap:
Home Page: https://blockstream.com/2018/03/22/filebazaar-joins-the-lightning-charge-lapps.html
License: MIT License
Currently, BTC amounts are always displayed as millibits. Would be nice to support satoshis, bits and whole bitcoins as well.
When I start filebazaar for the first time after modifying .yaml file I have this error:
`# filebazaar ForSale/_filebazaar.yaml
/usr/local/lib/node_modules/filebazaar/dist/lib/util.js:58
var pngPixel = Buffer.from('iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mNkYAAAAAYAAjCB0C8AAAAASUVORK5CYII=', 'base64');
^
TypeError: base64 is not a function
at Function.from (native)
at Function.from (native)
at Object. (/usr/local/lib/node_modules/filebazaar/dist/lib/util.js:58:23)
at Module._compile (module.js:410:26)
at Object.Module._extensions..js (module.js:417:10)
at Module.load (module.js:344:32)
at Function.Module._load (module.js:301:12)
at Module.require (module.js:354:17)
at require (internal/module.js:12:17)
at Object. (/usr/local/lib/node_modules/filebazaar/dist/app.js:15:13)`
What can I do?
Hello,
I am getting the following error when clicking to pay for the image and requesting an invoice. I had everything working but now this happens.
POST /_invoice 500 47.941 ms - 148
Error: write EPROTO 139995458078528:error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol:../deps/openssl/openssl/ssl/s23_clnt.c:827:
at _errnoException (util.js:1003:13)
at WriteWrap.afterWrite [as oncomplete] (net.js:863:14)
GET /IMG_4349.jpg?preview 200 5.690 ms - 5214134
Hello,
This repository is listed on the Awesome Lightning-Network list, which is a collection of useful lightning-network projects. However, it seems that the 'lightning-network' topic is missing from this repository's topics.
Adding the 'lightning-network' topic will help users discover your project more easily and recognize its relevance to the lightning-network ecosystem. To add the topic, please follow these steps:
Thank you for your attention and for contributing to the lightning-network community!
Everything works fine but when I pay the invoice, the page redirects to the preview page. The token variable in the URL contains "NaN":
GET /_invoice/JNW52x79Wir5KIuZPE4qJ/longpoll.png 200 11409.545 ms - 68 GET /duck.jpg?invoice=JNW52x79Wir5KIuZPE4qJ 302 5.038 ms - 212 GET /duck.jpg?token=JNW52x79Wir5KIuZPE4qJ.NaN.svWchyqGCyv5PnMZXwJ0mDUF9JRKwswsHdCxcJlkcP8 200 149.135 ms - 1937 GET /_themes/yeti/bootstrap.min.css 304 0.607 ms - - GET /_assets/style.css 304 0.390 ms - - GET /duck.jpg?preview 304 1.009 ms - -
I've got filebazaar
installed and running, like so:
$ filebazaar
FileBazaar serving /home/bitcoin/ForSale on port 9678, browse at http://0.0.0.0:9678/
...but when I visit it in my browser, I get a text-only display (rather than a pretty interface as in the readme), and the links don't work. I suppose I have something misconfigured?
_filebazaar.yaml
looks like:
---
### Server settings
env: production
#port: 9678
host: 0.0.0.0
#url: http://my-url.com
### Lightning Charge
charge_url: http://localhost:9112
charge_token: SECRET
### FileBazaar settings
# The directory containing the files for sale
# defaults to the directory containing this file
# directory: /path/to/files
# The default file price, can be overridden for individual files (see below)
#default_price: 0.25 USD
# Expiry times
#invoice_ttl: 3600 # lock-in exchange rate for 1 hour
#download_ttl: 172800 # make download available for 2 days after payment
# Secret for generating HMAC access tokens (required)
token_secret: SECRET
# Directory to keep cached preview files
# defaults to `{directory}/_filebazaar_cache`
#cache_path: /path/to/filebazaar_cache
### Looks & feel
# See available themes on https://bootswatch.com
#theme: yeti
# Add custom CSS
#css: |
# body { background: blue }
# a { color: orange }
# Set custom views directory
#views_dir: /path/to/custom/views
# Set custom static files directory
#static_dir: /path/to/custom/static
### Files settings
files:
Books/:
Mastering-Bitcoin.pdf:
price: 5 USD
button: Buy this book
Thanks for your help :)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.