Deployment FAQ
Last updated
Was this helpful?
Last updated
Was this helpful?
This document covers the most common questions, errors, and issues you may encounter prior and during the installation of the software. For a detailed list of deployment methods and instructions for each, please see .
Bitcart is a 100% free and open-source software. We do not charge you anything. However, to run it, you should host it. You can run it as a self-hosted solution on your own local server, or use a cloud hosting provider, which is what a majority of users do.
Advanced users can run Bitcart on .
If you do not wish to host your own server, you can use a free .
Visit our for more information on the various ways in which you can run Bitcart.
Hosting prices differ, but even a minimal server would suffice.
Hosting your own instance might make it a bit harder to start using Bitcart, but it is worth it, to get a , with no third-party.
The system requirements depend on the components you have chosen, but a typical full installation (with all essential components enabled, and btc daemon):
1 GB RAM (if using 1 GB RAM, adding a bit of swap space is recommended, due to the OS using some resources too)
~= 10 GB disk (way less actually, but just to be sure)
Docker support by the OS (Ubuntu should work)
Note that, adding new coins typically don't increase the requirements a lot.
As of Bitcart 0.3.1.0 (March 8 2021), the system requirements to run Bitcart with all supported coins enabled are the same as the minimal requirements (maybe with a bit more swap space allocated).
After deployment, you need to register on your instance. The first registered user is the server admin.
So click on the register link, and create your admin account.
There are a few possible cases why this happens. But in almost all cases it is because it is having trouble connecting to the Merchants API.
If that's not what you want, unset those variables:
If that's what you want, then maybe the BITCART_ADMIN_URL
or BITCART_STORE_URL
is set to an incorrect value. Ensure that it starts with the protocol (http:// or https://), and that that URL is accessible.
If merchant API is not running, you can check it's logs for possible issues:
You need to run:
Tor for Bitcart is intended more as an improvement of the setup process, and allows for more flexibility for hosting on one's own device at home or in an office.
Having Tor activated would allow for simpler, plug-and-play usage of Bitcart, as it suppress the need for the following configuration steps:
Opening multiple ports on the firewall
Configuring the NAT for port redirection to your device on your local network
Setting up a DNS entry to get a HTTPS certificate
And any other difficulties you may face
While these steps are usually not a problem when Bitcart is hosted on a VPS, it can be difficult to solve for non-technical users on home or office networks.
Of course, you may use .local domain, but it will only be accessible from your local PC.
Tor just solves all these issues in one shot, all you have to do is plug your device on the local network. It is especially useful for POS application.
But if you're looking for perfect privacy and security, activating Tor with your Bitcart just won't do it.
Tor is a really tricky software to use for developers, as the slightest mistake can tear down the anonymity it provides. As Bitcart is evolving into a rather complex service and adding more and more plugins, even if we tried to route all this traffic through Tor, we couldn't guarantee that there would never be leaks of data in clear. There are many different requests we can't fully control or guarantee we control. When enabling Tor support, we do route the electrum and exchange rate requests through Tor, but that's the best we can do.
We think that the illusion of security is more dangerous that no security, or at least security we know is imperfect. So be aware that activating Tor doesn't prevent others to connect to your instance website, your bitcoin or lightning node in clear, it doesn't make you anonymous at all.
Bitcart is configured via environment variables.
You can always set some environment variable like so:
Running ./setup.sh
will apply new settings.
For example, let's say I want to deactivate Tor:
Similarly if you are adding a new component, the export command would instead look like this:
There is no such term as "testnet Bitcart". Bitcart is modular, and what you can do instead is, enable testnet on certain coins (daemons), but not on every one. So it is possible, let's say, to have bitcoin daemon running in mainnet, bitcoin cash in testnet, and litecoin in regtest.
To change the network of a coin, run:
Replace COIN
with the coin symbol (BTC, LTC, etc.), and network
with the actual network name (mainnet,testnet,regtest).
So, for example, to enable testnet on bitcoin, run:
Theoretically it's possible, but it is not recommended.
Due to the nature of electrum networking, it is possible. But if you receive a payment when Bitcart is offline, it will only be processed when Bitcart is back up.
Yes, it is possible.
The recommended way though is, to use the Merchants API, which handles many edge cases.
But if you need to connect to your daemon directly, you can either:
You can add a custom component to the deployment stack via the BITCART_ADDITIONAL_COMPONENTS
setting, and then, when running inside docker, you can always connect to daemons via their docker-compose name. For example, for bitcoin, the URL will be http://bitcoin:5000
.
Note: it is not recommended, as it might be a security risk! The daemon default credentials can be viewed from the source code, so you should either change them, or make sure daemon can not be accessed by anyone but your services.
For that, run:
The coin will now be accessible from the outside network.
The SSL certificates are automatically refreshed. But it something is not working, you can always restart your instance by running:
Yes you can! Just make sure to use the proper configuration.
Create an extra config file for your vhost in /etc/nginx/sites-available/bitcart
and create a symlink for this file at /etc/nginx/sites-enabled/bitcart
The contents of this vhost file should look like this:
Also, put the following in your main Nginx config file at /etc/nginx/nginx.conf
:
Now test your Nginx config with nginx -t
and reload the config with service nginx reload
.
Then, you need to make sure that Bitcart does not try to handle HTTPS on its side, you can do this by disabling it on your Bitcart instance.
Similar to the requirements for hosting a website, a web server is required for a Bitcart instance. While it is possible to run Bitcart locally on your PC, it would have to meet the minimal requirements and also run 24/7 if you don't want interruptions of service. You might also not want to expose your home IP address for the activity related to Bitcart payments. For all these reasons, while local hosting is suitable for testing, it's not a viable solution for production. A Virtual Private Server (VPS) is commonly used to address these problems.
But if you really need to do so, you have two options:
If the BITCART_HOST
variable ends with .local, then local mode will be activated. The setup script will automatically edit /etc/hosts. Note that, the reverse proxy must be set to nginx
, and not default nginx-https
.
The downside of this method is that it requires modifying /etc/hosts
, and that the instance will only be accessible from your own PC.
You can enable Tor support, and then your instance will be available from anywhere via .onion
domain.
Shutdown Bitcart with ./stop.sh
and cleanup the install with ./cleanup.sh
.
Delete all volumes in /var/lib/docker/volumes/
with:docker-compose -f compose/generated.yml down --v
Remove other Bitcart system files with: rm /etc/systemd/system/bitcart.service && rm /etc/profile.d/bitcart-env.sh
Remove your Bitcart installation folder with rm -r "$BITCART_BASE_DIRECTORY"
Just to make sure, run docker system prune
after a reboot to get rid of any other docker related artifacts.
First, you need to make sure that bitcart and docker is not running
Now, you need to format your drive. If you have already done it, you can skip this step.
The second lsblk
should show the drive you just plugged in. (of TYPE disk
) Make sure you don't make a mistake as the next command will erase all the data on this disk.
For the sake of this example, let's suppose it has the NAME /dev/sdd
.
Now we can partition the disk and format the partition:
Then we need to mount the partition on the linux filesystem.
Then, we need to make sure that docker won't start before the mount.
Now, imagine you want to transfer all the docker volume data to the new partition.
Now restart docker and bitcart
Note: We use mount bind instead of symbolic link because docker would complain when running docker volume rm
.
Since nginx gets the IP address in the request instead of raspberrypi.local it does not know where to route that request and returns:
You can fix this by forcing nginx to route the HTTP request to Bitcart even if the request domain name is not recognized. Simply, re-run the setup script like this:
Now putting local IP in the web-browser works.
To check, run:
Press "q" to quit out of less.
The output should contain:
jrcs/letsencrypt-nginx-proxy-companion
bitcart/bitcart
And the status should be "Up"
If the docker container is not running, then check the reason for crash like this:
Where compose-backend-1
is the container name that is having issues.
# Cause 4: Other
For a self-hosted solution, we recommend using our to easily deploy instances, without any technical skills required. You may also use the Lunanode Web deployment.
For just trying out, you can use our or a .
Please refer to page to view comparison of different deployment methods
Yes, the installation instructions almost don't differ. Refer to guide.
It might be possible that admin panel tries to access the merchants API via https:// URL, but there is no SSL certificate available yet, which causes SSL error. Just wait a bit, and usually the problem is resolved. If not, try .
When using , it should always work. But if you have accidentally set any of BITCART_ADMIN_HOST
, BITCART_ADMIN_URL
, BITCART_STORE_HOST
, BITCART_STORE_URL
, then one domain mode is disabled.
If some error is unexpected, please .
Refer to the for more details.
See this .
If you need to figure out which environment variable you need to modify, have a look at .
Check the list of URLs to connect to .
It is way easier to use built-in reverse proxy, but in cases when you are running , it is required.
Notice: If your Bitcart install has more than one domain (for example, when is off) you will need to modify your config for each domain name. The example above only covers 1 domain name called bitcart.domain.com
.
See the for more details.
See this .
Your nginx config is set to route the HTTP request to a particular container based on the domain name of the request. For example, the official said to setup the source domain name to http://raspberrypi.local/ yet getting automatic local domain raspberrypi.local does not always work. You are probably in this situation and trying to type the IP address of your Bitcart into the web-browser.
There could be many causes for 5XX HTTP errors. Please create an and when cause becomes known add it here in the doc.