Skip to content

wrburgess/kc-tennis

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

KC Tennis

References

Useful Commands

  • Lock Bundle: bundle lock --add-platform x86_64-linux

Tools Versions

Install asdf for dependency versioning

  • asdf
  • Install with brew install asdf

Install Plugins

  • ruby: asdf plugin-add ruby
  • nodejs: asdf plugin-add nodejs
  • postgres: asdf plugin-add postgres

Update Dependencies

  • Update all plugins: asdf plugin update --all
  • List available versions: asdf list all [plugin]
  • Install latest library: asdf install [plugin] latest
  • Set global version: asdf global [plugin] latest
  • Set local version: asdf local [plugin] latest

Setup Yarn 4+

  • Delete existing yarn.lock: rm -rf yarn.lock
  • Create a blank file: touch yarn.lock
  • Update to the latest yarn version: yarn set version berry

Production

Foundation

Tools

Encrypted Credentials

  • run rails credentials:edit
  • Your editor will need to run with --wait due to decryption speed
  • example: export EDITOR="code -w"
  • Retrieve keys with Rails.application.credentials.[environment_name].[key_name]
  • example Rails.application.credentials.development.postmark_api_token

Database Management

Heroku Commands

  • heroku run rails db:reset -r [staging|production] # warning: destructive
  • heroku run rails db:migrate -r [staging|production]
  • heroku run rails db:seed -r [staging|production]

pghero

  • pghero gem
  • Update stats with rake pghero:capture_query_stats

blazer

Running Application Locally

Local Server Commands

  • alias foreb="foreman start -f Procfile.dev.backend"

  • alias foref="foreman start -f Procfile.dev.frontend"

  • alias rs="rails s"

  • foreb runs good_job worker

  • foref runs a js and css watcher for changes

  • rs8 runs puma locally on port 8000

Setup Cloudflare Tunnel

Setup References

Setup Steps

  • KC Tennis uses the local.kc.tennis domain for local tunneling with Cloudflare and the cloudflared ci
  • Install (on Mac) with brew install cloudflared
  • Login with cloudflared tunnel login
  • Create name tunnel cloudflared tunnel create <NAME> or cloudflared tunnel create localkct
  • Create config file at /User/[username]/.cloudflared/config.yaml
  • KC Tennis Cloudflare Tunnel Dashboard
  • Note: Config for the www.kctennis.com domain is managed on the Cloudflared Tunnel Dashboard

Running Tunnel Commands

  • Run tunnel with cloudflared tunnel run localkct
  • Setup alias alias localkct="cloudflared tunnel run localkct"
  • Check tunnel status with cloudflared tunnel info localkct

Security Checks

  • run bundle outdated > update gems with bundle update > run tests
  • run bundle-audit update
  • run bundle-audit
  • run brakeman

Security References

Asset Pipeline

  • propshaft
  • js_bundling_rails
  • css_bundling_rails
  • esbuild
  • bootstrap
  • sass

Hotwire

  • stimulus
  • turbo

Authentication

  • Devise
  • Pundit
  • System Permissions

Database

Testing

  • rspec
  • capybara

Linting

  • rubocop

Async

  • GoodJob

Caching

  • SolidCache

Notifications

  • Noticed
  • Topics/Subs

Views

  • ViewComponent

Assets

  • AWS
  • cloudfront or cloudflare

API

  • inbound_requests_controller

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •