Skip to content

Instantly share code, notes, and snippets.

# Varnish 4.0 file for our Craft CMS projects
# Based on https://github.com/mattiasgeniar/varnish-4.0-configuration-templates/blob/master/default.vcl
#
# This is still work in progress, comments appreciated.
vcl 4.0;
import std;
import directors;
@cmalven
cmalven / craft-fastly.md
Last active August 12, 2020 22:59
Integrating Craft with Fastly

Running a Craft site on Fastly

Fastly is essentially Varnish as a service. Similarly to how Heroku drastically simplifies the running of a web server, Fastly simplifies full-page caching of websites with running with dynamic content.

How Fastly Works

In a nutshell:

  • Every time there is a request for your website, it is routed through Fastly instead of directly to your backend.
  • If Fastly has an existing cache for the requested URL, it serves the cached page and your backend isn't touched at all.
# This is a basic VCL configuration file for varnish. See the vcl(7)
# man page for details on VCL syntax and semantics.
#
# Default backend definition. Set this to point to your content
# server.
#
# Switch to 8080 when we go live.
backend default {
.host = "127.0.0.1";
@LeCoupa
LeCoupa / nodejs-cheatsheet.js
Last active June 30, 2024 04:14
Complete Node.js CheatSheet --> UPDATED VERSION --> https://github.com/LeCoupa/awesome-cheatsheets
/* *******************************************************************************************
* THE UPDATED VERSION IS AVAILABLE AT
* https://github.com/LeCoupa/awesome-cheatsheets
* ******************************************************************************************* */
// 0. Synopsis.
// http://nodejs.org/api/synopsis.html
@pake007
pake007 / WordPress on Mac OS X.md
Created December 20, 2011 03:35
Install and Configure WordPress on Mac OS X Snow Leopard Step-By-Step

It is very convenient to install and configure WordPress on Max OS X Snow Leopard or higher version like Lion, because it already builds an apache2 server and php5 in the system, you just need to configure them and your wordpress site can be run!

Install WordPress

  • Download the latest version of WordPress (3.3 as of this writing)

  • Extract and copy the "wordpress" folder to your "Sites" folder. So, in my case the full path to WordPress is: /Users/jimmy/Sites/wordpress you can rename the folder as your wanted.