Skip to content

Instantly share code, notes, and snippets.

View sagarkt's full-sized avatar
🧩
building....

Sagar Kamble sagarkt

🧩
building....
  • Pune
View GitHub Profile
server {
server_name test24.company.io;
index index.html;
root /home/ubuntu/project-source/company/entry;
location / {
root /home/ubuntu/project-source/company/entry;
}
@aklap
aklap / fix-missing-libcrypto-osx.md
Created October 17, 2016 04:25
Resolving missing link to libcrypto/openssl on OSX
@umar-siddiqui
umar-siddiqui / drop_restore_db.sh
Last active August 24, 2016 07:43
Script for fetching DB on server and restoring locally.
#!/bin/bash
## Parameter 1 :: Database name on server
## Parameter 2 :: Server Domain name
## Parameter 3 :: Capistrano deployment script
## eg ./drop_restore_db.sh havells_resustain_io havells.resustain.io security
dbname=$1
instancedomain=$2
envi=$3
echo "#################### [INFO] Executing Command :: cap $envi deploy:mongo_backup\"[$dbname]\""
@fernandoaleman
fernandoaleman / fix-libv8-mac.txt
Created May 5, 2016 15:14
Fixing libv8 and therubyracer on Mac
brew tap homebrew/versions
brew install v8-315
gem install libv8 -v '3.16.14.13' -- --with-system-v8
gem install therubyracer -- --with-v8-dir=/usr/local/opt/v8-315
bundle install
@vasanthk
vasanthk / System Design.md
Last active July 30, 2024 00:17
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
@maxivak
maxivak / 00.md
Last active May 23, 2024 13:24
Sending emails with ActionMailer and Sidekiq

Sending emails with ActionMailer and Sidekiq

Send email asynchroniously using Sidekiq.

ActionMailer

Create your mailer us usual:

@iangreenleaf
iangreenleaf / gist:b206d09c587e8fc6399e
Last active June 20, 2024 02:39
Rails naming conventions

Rails naming conventions

General Ruby conventions

Class names are CamelCase.

Methods and variables are snake_case.

Methods with a ? suffix will return a boolean.

# Type(<scope>): <subject>
# <body>
# <footer>
# Type should be one of the following:
# * feat (new feature)
# * fix (bug fix)
# * docs (changes to documentation)
@wayspurrchen
wayspurrchen / gist:b6fd4eb085edf54406b7
Last active January 20, 2024 22:49
Web Performance Optimization Techniques