You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
fosspay/README.md

71 lines
2.0 KiB

9 years ago
# fosspay [![Donate with fosspay](https://drewdevault.com/donate/static/donate-with-fosspay.png)](https://drewdevault.com/donate?project=3)
9 years ago
9 years ago
Donation collection for FOSS groups and individuals.
9 years ago
9 years ago
* Supports one-time and monthly donations
* Process cards with Stripe
9 years ago
* Flexible and customizable
9 years ago
9 years ago
It works for individuals (like me) and it works for organizations. Expect to
spend about an hour or two setting up everything and then you're good to go.
9 years ago
For support, visit [#cmpwn on
irc.libera.chat](http://web.libera.chat/gamja/)
or file a GitHub issue.
9 years ago
## Before you start
9 years ago
9 years ago
You will need a number of things set up before you start:
9 years ago
9 years ago
1. An approved [Stripe](https://stripe.com/) account
1. A mail server
1. A domain name and an SSL certificate
1. A web server to host fosspay on
9 years ago
9 years ago
## Installation
9 years ago
9 years ago
Install these things:
9 years ago
9 years ago
* Python 3
* pip (python 3)
* PostgreSQL
9 years ago
9 years ago
You're responsible for setting up PostgreSQL yourself. Prepare a connection
string for later.
9 years ago
9 years ago
Clone the git repository on the server that you want to host fosspay on:
9 years ago
git clone https://git.sr.ht/~sircmpwn/fosspay
9 years ago
cd fosspay
9 years ago
9 years ago
Install the Python packages:
9 years ago
9 years ago
sudo pip3 install -r requirements.txt
9 years ago
9 years ago
Compile the static assets:
9 years ago
9 years ago
make
9 years ago
9 years ago
Create a configuration file:
cp config.ini.example config.ini
9 years ago
9 years ago
Edit `config.ini` to your liking. Then, you can run the following to start up
the development server:
python3 app.py
9 years ago
9 years ago
Log into http://your-domain:5000, and you will receive further instructions.
9 years ago
## Deployment
9 years ago
Once you have everything configured, you will need to switch from the dev server
into something more permanent. Install gunicorn on your server and use the
systemd unit provided in `contrib/`. You will also probably want to run this
through nginx instead of directly exposing gunicorn to the web, see
`contrib/nginx.conf`. Neither the nginx configuration or the systemd unit are
immediately ready to use - read them and change them to suit your needs.
9 years ago
9 years ago
Using nginx or something like it is necessary for SSL support, and you must
serve your site with https for Stripe to work.