- csv file for ranking. get from ncs web page
docker compose build
docker compose run web rails db:seed
docker compose up
open http://localhost:3064/players
- copy config/master.key (this file is ignored from git)
- or you can recreate credentials.yml.enc and master.key:
rm credentials.yml.enc
docker compose run -e EDITOR=vim web rails credentials:edit
- you need to set
Rails.application.credentials
variables
- you need to set
- or you can recreate credentials.yml.enc and master.key:
docker compose -f docker-compose.production.yml build
docker compose -f docker-compose.production.yml up -d
- reset database:
docker compose -f docker-compose.production.yml run web rails db:migrate:reset RAILS_ENV=production DISABLE_DATABASE_ENVIRONMENT_CHECK=1
-
get a new excel file from NCS and export as csv file
-
put the csv file to lib/assets
-
docker compose run web rails db:seed
-
victory distance:
docker compose exec web rake victory_distance:save
- generate Home controller
docker compose run web rails g controller Users
docker compose run web bundle install
docker compose up --build
docker compose exec web rubocop -A
docker compose exec web rails test
We use sitemap_generator.
Generate public/sitemap.xml.gz file by rake sitemap:refresh
.
This file is ignored by git.
- set
binding.pry
- check container id:
docker ps
- docker attach container_id
- open browser
exit
- Ctrl + q
docker compose exec web rake add_rank:update_null_ranks
psql --host=localhost --port=5464 --username=postgres --password --dbname=chess_ranking_development