Skip to content

Instantly share code, notes, and snippets.

View krishnadiamesso's full-sized avatar

Krishna Diamesso krishnadiamesso

  • Toronto, Canada
View GitHub Profile
diff --git a/app/controllers/account/registrations_controller.rb b/app/controllers/account/registrations_controller.rb
index 376f20a77..a554c9f8d 100644
--- a/app/controllers/account/registrations_controller.rb
+++ b/app/controllers/account/registrations_controller.rb
@@ -1,6 +1,8 @@
# frozen_string_literal: true
module Account
class RegistrationsController < Devise::RegistrationsController
+ before_action :reject_spam, only: :create
+
@iEv0lv3
iEv0lv3 / gcp_docker_rails.md
Last active February 17, 2024 22:32
GCP Cloud Run :: Docker :: Rails

Google Cloud Platform (GCP) :: Docker :: Rails

This guide covers deploying a Docker image of a Rails and PostgreSQL application on Google Cloud Platform using Cloud Build, Container Registry, Cloud Key Management Service, Cloud Run, Cloud SQL, and Cloud Store. The following section provides links to a detailed guide created by a Google Developer Advocate which was the base for my build, but needed to be adjusted.

Cloud Run + Rails + PostgreSQL Guide

Google Cloud Run on Rails: a real life example Part 1

Google Cloud Run on Rails: a real life example Part 2

Google Cloud Run on Rails: a real life example Part 3

@esteedqueen
esteedqueen / fix_rbenv.md
Last active July 12, 2024 13:25
How to fix rbenv: version `x.x.x` is not installed

So, you just cloned an existing project's repo and you run bundle install but you got the error: rbenv: version x.x.x is not installed....

What the issue means? The project uses a specific ruby version that you do not have on your system.

Here's how to fix it:

  • Install the Ruby build for the specified version using:
rbenv install x.x.x
@maxivak
maxivak / readme.md
Last active January 22, 2024 17:51
Send email to multiple recipients in Rails with ActionMailer

Send email to multiple recipients

Send multiple emails to different recipients.

Mailer class

# app/mailers/notify_mailer.rb

class NotifyMailer < ApplicationMailer
@tomas-stefano
tomas-stefano / Capybara.md
Last active July 3, 2024 12:47
Capybara cheatsheet

Capybara Actions

# Anchor
click_link 'Save'

# Button
click_button 'awesome'

# Both above