A site to upload, view, and edit beerxml recipes.
- http://olrecept.se
- http://malt.io
- http://beercalc.org
- http://beerrecipes.org
- http://brewgr.com
- http://brewtoad.com
- http://brewersfriend.com
- Beersmith
- QBrew
- Brewtarget
- Brew Pal (iOS)
- BrewR (Android)
- Wort (Android)
- Brewer's Friend (iOS, Android)
- Brewfather
This application needs the following:
- Ruby v3.0.2
- Postgres v9.6
- Docker for development environment
Use docker to setup a local development environment.
docker-compose build
docker-compose up
docker-compose run web rake db:create
docker-compose run web rake db:migrate
Add the following to a file called .env.development
.
DEVISE_PEPPER: changeme
GOOGLE_CLIENT_ID: changeme
GOOGLE_CLIENT_SECRET: changeme
SECRET_KEY_BASE: changeme
WEB_CONCURRENCY: 3
PUSHOVER_USER: changeme
PUSHOVER_TOKEN: changeme
PUSHOVER_GROUP_RECIPE: changeme
PROJECT_HONEYPOT_KEY: changeme
SMTP_PASSWORD: changeme
INKSCAPE_PATH: /usr/bin/inkscape
INKSCAPE_VERSION=1
DEVELOPMENT_HOST: yourcomputer.local
SLACK_SIGNING_SECRET: changeme
Run bundle exec rake secret
twice and add them to the .env.development
where it says 'changeme' (SECRET_KEY_BASE
and DEVISE_PEPPER
).
For the Google signin support, you need to create credentials on the Google
Developers console and add client_id
and client_secret
to the
.env.development
https://console.developers.google.com
The reCAPTCHA supports needs a site_key
and secret_key
:
https://www.google.com/recaptcha/admin
The Pushover integration needs keys from https://pushover.net/
Project Honeypot is used for spam protection. A key can be obtained from: https://www.projecthoneypot.org/
For mailers to work, an SMTP password needs to be configured in
smtp_password
.
The SMTP server and user_name is hardcoded in config/application.rb
If you have inkscape installed, you can set INKSCAPE_PATH
to use inkscape
to generate beer labels when creating the beer label pdf.
Create a file called .envrc
in the project root directory with the
environments below.
DEVISE_PEPPER=changeme
GOOGLE_CLIENT_ID=changeme
GOOGLE_CLIENT_SECRET=changeme
RACK_ENV=production
RAILS_ENV=production
SECRET_KEY_BASE=changeme
WEB_CONCURRENCY=3
PUSHOVER_USER=changeme
PUSHOVER_TOKEN=changeme
PUSHOVER_GROUP_RECIPE=changeme
PROJECT_HONEYPOT_KEY=changeme
SMTP_PASSWORD=changeme
RECAPTCHA_SITE_KEY=changeme
RECAPTCHA_SECRET_KEY=changeme
SPAM_IP=space separated list of IP addresses to block
INKSCAPE_PATH=/usr/bin/inkscape
SLACK_SIGNING_SECRET=changeme
SPAM_COUNTRIES=space separated list of countries to block registrations from
If you don't have Ruby, here is a short primer:
-
Install rbenv: https://github.com/rbenv/rbenv#basic-github-checkout
-
Install ruby-build rbenv plugin:
$ git clone https://github.com/rbenv/ruby-build.git ~/.rbenv/plugins/ruby-build
-
Install Ruby
$ rbenv install 3.0.2
-
Install bundler
$ gem install bundler
Basically just clone the Github repository and run bundle install
.
$ git clone https://github.com/ollej/brewnit.git brewnit
$ cd brewnit
$ bundle install
$ createdb brewnit_dev
$ bundle exec rake db:migrate
Run bundle exec rake secret
twice and add them to the config/secrets.yml
where it says 'changeme' (secret_key_base and devise_pepper).
For the Google signin support, you need to create credentials on the Google Developers console and add client_id and client_secret to the config/secrets.yml
https://console.developers.google.com
Start the web server with the following command.
$ bundle exec rails s
rails generate favicon
- Loading spinner from: https://preloaders.net
- Flat icons from: https://flaticon.com
- Sounds from: https://www.soundjay.com
- Sounds from: https://www.freesound.org
It's easy, just follow the contribution guidelines.