npm i
bundle isudo service postgresql start
sudo -u postgres psql
CREATE DATABASE cardeons_backend_development;
CREATE DATABASE cardeons_backend_test;
rails db:migraterails db:seed cards=cardsrails db:seed users=usersWe are using foreman to start redis/sidekiq and puma in one shell:
gem install foremanYou need to install redis before you can use the dev env:
sudo apt install redis-server foreman start -f Procfile.devadd master as remote
git remote add dokku ssh://dokku@projects.multimediatechnology.at:5412/cardeonadd develop as remote
git remote add dokku-develop ssh://dokku@projects.multimediatechnology.at:5412/cardeon-developCode gets pushed automatically as soon as you push to the master in the corresponding repo.
if in any case you need to push manuallyuse:
gem install dokku-cli
git push dokku YOUR_BRANCH_TO_PUSH:master
git push dokku-develop YOUR_BRANCH_TO_PUSH:masterif in any case you need to run commands on dokku:
dokku run rails db:migrate
dokku run rails db:migrate --remote=dokku-developreset db/set temp env variables: pls never do this on our production server
dokku run rails db:reset DISABLE_DATABASE_ENVIRONMENT_CHECK=1env variablen setzen::
dokku config:set MY_ENV="myvalue"
dokku config:set MY_ENV="myvalue" --remote=dokku-developA private key is needed for deploying!
Happy Coding😘👩💻
rspec -> runs all testshttps://cardeon.projects.multimediatechnology.at/ https://cardeon-develop.projects.multimediatechnology.at/
yes its cardeon not cardeons :(