Skip to content

Instantly share code, notes, and snippets.

How to setup AWS lambda function to talk to the internet and VPC

I'm going to walk you through the steps for setting up a AWS Lambda to talk to the internet and a VPC. Let's dive in.

So it might be really unintuitive at first but lambda functions have three states.

  1. No VPC, where it can talk openly to the web, but can't talk to any of your AWS services.
  2. VPC, the default setting where the lambda function can talk to your AWS services but can't talk to the web.
  3. VPC with NAT, The best of both worlds, AWS services and web.
@jmcguirk
jmcguirk / PerformBuild.cs
Created March 8, 2013 01:56
Unity3D Ant Build Configuration
// C# example
using UnityEditor;
using System.IO;
using System.Collections;
using UnityEngine;
using System.Collections.Generic;
class PerformBuild
{
static string[] GetBuildScenes()
@rodw
rodw / gollum-wiki-tag-indexer.rb
Created July 10, 2012 19:46
wiki-tag-indexer - Processes a directory of Gollum wiki files updating special "tag" pages with a list of pages that contain that tag.
#!/usr/bin/env ruby
# wiki-tag-indexer - Processes a directory of Gollum wiki files updating
# special "tag" pages with a list of pages that contain that tag.
#===============================================================================
# QUICK-START INSTRUCTIONS
# ------------------------
#
# 0. If you haven't already, clone the git repository containing your wiki.
# E.g., if you're on GitHub, use something like:
@leon
leon / gollum.conf
Created May 9, 2012 11:45
Gollum Upstart script
#
# Install:
# install https://github.com/github/gollum
# in /srv/wiki do a git init
# add this script to /etc/init/gollum.conf
#
# Usage:
# start/stop/restart gollum
#
@troelskn
troelskn / app.rb
Last active August 12, 2021 17:25 — forked from dstrelau/app.rb
Gollum protected by HTTP Basic
require 'gollum/frontend/app'
require 'digest/sha1'
class App < Precious::App
User = Struct.new(:name, :email, :password_hash, :can_write)
before { authenticate! }
before /^\/(edit|create|delete|livepreview|revert)/ do authorize_write! ; end
helpers do