This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## | |
# Calendar helper with proper events | |
# http://www.cuppadev.co.uk/webdev/making-a-real-calendar-in-rails/ | |
# | |
# (C) 2009 James S Urquhart (jamesu at gmail dot com) | |
# Derived from calendar_helper | |
# (C) Jeremy Voorhis, Geoffrey Grosenbach, Jarkko Laine, Tom Armitage, Bryan Larsen | |
# Licensed under MIT. http://www.opensource.org/licenses/mit-license.php | |
## | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/bash | |
### BEGIN INIT INFO | |
# Provides: gitlab | |
# Required-Start: $local_fs $remote_fs $network $syslog redis-server | |
# Required-Stop: $local_fs $remote_fs $network $syslog | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: GitLab git repository management | |
# Description: GitLab git repository management | |
### END INIT INFO |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
upstream gitlab { | |
server unix:/home/gitlab/gitlab/tmp/sockets/gitlab.socket; | |
} | |
server { | |
listen YOUR_SERVER_IP:80; | |
server_name gitlab.YOUR_DOMAIN.com; | |
root /home/gitlab/gitlab/public; | |
# individual nginx logs for this gitlab vhost |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
aliases = Tire::Configuration.client.get("#{Tire::Configuration.url}/_aliases") | |
JSON.parse(aliases.body).keys.select{|v| v =~ /^logstash/i }.each do |n| | |
Tire::Index.new(n).delete | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# run it with command: | |
# bash -c "$(curl -fsSL https://gist.github.com/troszok/9598077)" | |
# wget -O - https://gist.github.com/troszok/9598077 | bash | |
sudo apt-get -q -y install software-properties-common python-software-properties | |
sudo add-apt-repository ppa:webupd8team/java | |
wget -q -O - http://pkg.jenkins-ci.org/debian/jenkins-ci.org.key | apt-key add - | |
echo deb http://pkg.jenkins-ci.org/debian binary/ > /etc/apt/sources.list.d/jenkins.list | |
apt-get update -y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<link rel="import" href="../polymer/polymer.html"> | |
<polymer-element name="my-element"> | |
<template> | |
<style> | |
:host { | |
position: absolute; | |
width: 100%; | |
height: 100%; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<link rel="import" href="../paper-tabs/paper-tab.html"> | |
<link rel="import" href="../paper-tabs/paper-tabs.html"> | |
<polymer-element name="my-element"> | |
<template> | |
<style> | |
:host { | |
position: absolute; | |
width: 100%; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require "formula" | |
class Elasticsearch < Formula | |
homepage "http://www.elasticsearch.org" | |
url "https://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-1.4.0.Beta1.tar.gz" | |
sha1 "5e3d07fdf2d5aab75d49b38fa6743b43f07eef70" | |
depends_on :java => "1.7" | |
head do |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Index hit rate | |
WITH idx_hit_rate as ( | |
SELECT | |
relname as table_name, | |
n_live_tup, | |
round(100.0 * idx_scan / (seq_scan + idx_scan),2) as idx_hit_rate | |
FROM pg_stat_user_tables | |
ORDER BY n_live_tup DESC | |
), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# based on that: http://myronmars.to/n/dev-blog/2011/10/custom-request-matchers-in-vcr-2-0 | |
uri_without_timestamp = VCR.request_matchers.uri_without_param("Timestamp", "Signature") | |
context "amazon integration", vcr: {record: :once, :match_requests_on => [:method, uri_without_timestamp]} do | |
end |
OlderNewer