Forward HTTP through an intermediary server (Local Port Forwarding)

Tunnel HTTP traffic to a specific host and port through an SSH server with local port forwarding, useful for reaching internal services from localhost.

thoughtbot/fake_stripe: A Stripe fake so that you can avoid hitting Stripe servers in tests.

fake_stripe runs a local Stripe-like server and fake Stripe.js for feature specs, letting purchase flows be tested without external HTTP requests or Stripe sandbox flakiness.

How to use the Capistrano 2 shell to execute commands on servers

Capistrano 2 provides shell and invoke for running tasks or ad hoc commands on deployment targets, with support for individual hosts and roles.

Loading dumps via SSH, unpacking and sourcing them, all with a progress bar

Load a compressed MySQL dump directly from a remote server over SSH with a progress bar, without copying or unpacking the file first.

How to fix "Too many authentic authentication failures" with SSH and/or Capistrano

SSH or Capistrano connections can fail when ssh-agent offers too many keys and servers stop after repeated authentication attempts.

Listing all gems on a private gem server

gem list -r --clear-sources -s can inspect gems on a private remote server, useful when Bundler reports a gem in multiple sources.

Common mistakes when storing file uploads with Rails

File uploads in Rails are easy to misconfigure, causing lost files, public exposure of confidential data, and environment collisions. Existing uploads also need migration when storage paths change.

Make Nokogiri use system libxml2

Nokogiri can be built against system libxml2 instead of bundled binaries, reducing rebuild work after security updates and aligning installs with patched OS libraries.

Show and change MySQL default character set

MySQL character-set mismatches cause garbled text and inconsistent comparisons; SHOW VARIABLES LIKE 'char%' and my.cnf settings reveal and change the server defaults.

Net::SSH::Exception: could not settle on encryption_client algorithm

Old net-ssh versions can fail to connect when servers disable weak ciphers; pinning net-ssh or updating SSH client support restores deployment access.

Interacting with a Microsoft Exchange server from Ruby

Connect Ruby to Exchange Web Services for mail, calendar, and meeting data when Outlook-only tasks need automation.

Working around OpenSSL::SSL::SSLErrors

Ruby and curl requests can fail when a server only accepts older SSL/TLS versions; forcing a specific protocol version can restore connectivity.

Configuring ActionMailer host and protocol for URL generation

ActionMailer URL generation fails without a configured host and protocol. Rails can use hardcoded defaults or derive them from the request for mailers sent outside the request cycle.

Unpoly: Showing the better_errors page when Rails raises an error

AJAX errors in Unpoly can hide the full better_errors page in Rails development. A fallback full-page reload restores the interactive error view and CSS.

SSL: Build a Certificate signing request (CSR)

Creating a CSR and private key for an SSL certificate requires careful server-side generation; the common name must match the domain exactly or the certificate becomes invalid.

Middleman: Use pretty URLs without doubling requests

Middleman pretty URLs can trigger an extra redirect and second page request; Apache can serve /foo/index.html directly while canonicalizing /foo/.

Install a local Gemfile on a remote server

Run bundle install on a remote host using a local Gemfile, even for vendored gems or a different BUNDLE_GEMFILE.

Speed up file downloads with Rails, Apache and X-Sendfile

Rails can hand file delivery to Apache with X-Sendfile, reducing application-server load and preventing zero-byte downloads when local files are sent.

Differences between transactions and locking

Concurrent database access needs two different tools: transactions for atomic multi-row changes and locks for exclusive access; using the wrong one causes lost updates and deadlocks.

Capistrano: Different usernames for each server

Capistrano deployments to multiple servers can fail when each host needs a different login; putting the username in the server definition avoids a global set :user setting.

IMAP: Check credentials

IMAP login problems can be isolated by testing the server with openssl s_client and sending a manual LOGIN command to verify credentials and connectivity.

Zeus promises to make rails development faster

Rails app boot and test startup become slow as gems grow; Zeus preloads the app so console, server, generate, and specs run in under a second.

Defining host aliases in your SSH config

SSH host aliases in ~/.ssh/config make hard-to-remember servers easier to reach and let you use names instead of raw IP addresses.

Setup (and secure) an SSH server on Ubuntu

Install and harden an SSH daemon on Ubuntu by adjusting sshd_config to block root logins, restrict users, and disable password authentication.