Skip to content
The server used by Blaise, a wallet for the Pascal cryptocurrency
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

Blaise (Pascal)

What is Blaise and Pascal?

Blaise is a mobile wallet written with Flutter. Pascal is a cryptocurrency.

Link Description Pascal Homepage Blaise Home Page Appditto Homepage


Requires Python 3.6 or Newer

Install requirements on Ubuntu 18.04:

apt install python3 python3-dev libdpkg-perl virtualenv nginx

Minimum of one PascalCoin Daemon with RPC enabled.

Redis server running on the default port 6379

On debian-based systems redis can be installed with:

sudo apt install redis-server



  1. Run the app under a dedicated user
  2. Clone the repository
  3. Configuration
  4. Run
sudo adduser blaise # Add blaise user
sudo usermod -aG sudo blaise # Add blaise to sudo group
sudo usermod -aG www-data blaise # Add blaise to www-data group
sudo su - blaise # Change to blaise
git clone blaise_server # Clone repository

Ensure python3.6 or newer is installed (python3 --version) and

cd blaise_server
virtualenv -p python3 venv
source venv/bin/activate
pip install -r requirements.txt

Some things can be configured with environment variables, most are optional

Create the file .env in the same directory as with the contents:

RPC_URL=  # Pascal RPC URL
DEBUG=0                   # Debug mode (0 is off)
FCM_API_KEY=None          # (Optional) Firebase Legacy API KEY (From Firebase Console)
FCM_SENDER_ID=1234        # (Optional) Firebase Sender ID (From Firebase Console)
SIGNER_ACCOUNT=1234       # (Optional) Account on the wallet that is used to sign transactions related to the borrow process
PUBKEY_B58=3gb0p          # (Optional) Public key of the daemon wallet

Price Cron

The prices are updated via a cron job. This can be created as such.

crontab -e

Add the following line to crontab and save

*/5 * * * * /home/blaise/blaise_server/venv/bin/python /home/blaise/blaise_server/ >/dev/null 2>&1


The recommended configuration is to run the server behind nginx, which will act as a reverse proxy

Next, we'll define a systemd service unit


Description=Blaise Server

ExecStart=/home/blaise/blaise_server/venv/bin/python --host --port %i --log-file /tmp/blaise%i.log


Enable this service and start it, ensure all is working as expected

sudo systemctl enable blaise@4443
sudo systemctl start blaise@4443
sudo systemctl status blaise@4443

Next, configure nginx to proxy requests to this server


upstream blaise_nodes {


server {

        location / {
                proxy_pass http://blaise_nodes;
                proxy_redirect off;
                proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
                proxy_set_header X-Real-IP $remote_addr;
                proxy_set_header X-Forwarded-Host $server_name;
                proxy_set_header X-Forwarded-Proto $scheme;
                proxy_http_version 1.1;
                proxy_set_header Host $host;
                proxy_set_header Upgrade $http_upgrade;
                proxy_set_header Connection "upgrade";

Enable this configuration and restart nginx

sudo ln -s /etc/nginx/sites-available/ /etc/nginx/sites-enabled/
sudo service nginx restart

Let's encrypt

sudo add-apt-repository ppa:certbot/certbot
sudo apt update
sudo apt install python-certbot-nginx 
sudo certbot --nginx
You can’t perform that action at this time.