https://github.com/bitshares/tapin
Account creation service (faucet) built with python-bitshares
https://github.com/bitshares/tapin
Last synced: 11 months ago
JSON representation
Account creation service (faucet) built with python-bitshares
- Host: GitHub
- URL: https://github.com/bitshares/tapin
- Owner: bitshares
- License: mit
- Created: 2018-07-24T09:27:24.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2018-11-12T11:42:48.000Z (over 7 years ago)
- Last Synced: 2025-06-21T12:35:39.643Z (about 1 year ago)
- Language: Python
- Homepage:
- Size: 41 KB
- Stars: 6
- Watchers: 2
- Forks: 10
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# Tapin
`tapin` is a python-based faucet for Graphene-based blockchains (e.g. BitShares).
## Installation
* edit `config.py` and provide private keys and settings
* `python manage.py install`
## Usage
* `python manage.py runserver`
The faucet is then available at URL `http://localhost:5000`
## Nginx configuration
Run `uwsgi --ini wsgi.ini`
and use a configuration similar tothis
```
user bitshares;
worker_processes 4;
events {
worker_connections 2048;
}
http {
include mime.types;
default_type application/octet-stream;
access_log /www/logs/access.log;
error_log /www/logs/error.log;
log_not_found off;
sendfile on;
keepalive_timeout 65;
gzip on;
upstream websockets {
server localhost:9090;
server localhost:9091;
}
server {
listen 80;
if ($scheme != "https") {
return 301 https://$host$request_uri;
}
listen 443 ssl;
server_name bitshares-wallet.com;
ssl_certificate /etc/nginx/ssl/bitshares-wallet.com.crt;
ssl_certificate_key /etc/nginx/ssl/bitshares-wallet.com.key;
ssl_session_cache shared:SSL:1m;
ssl_session_timeout 5m;
ssl_ciphers HIGH:!aNULL:!MD5;
ssl_prefer_server_ciphers on;
location ~ /ws/? {
access_log on;
proxy_pass http://websockets;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_next_upstream error timeout invalid_header http_500;
proxy_connect_timeout 2;
}
location ~ ^/[\w\d\.-]+\.(js|css|dat|png|json)$ {
root /www/wallet;
try_files $uri /wallet$uri =404;
}
location / {
root /www/wallet;
}
location /api {
include uwsgi_params;
uwsgi_pass unix:/tmp/faucet.sock;
}
}
}
```