Skip to content

Instantly share code, notes, and snippets.

View hendricius's full-sized avatar

Hendrik Kleinwaechter hendricius

View GitHub Profile
server {
listen 80;
server_name staging.musterbrand-system.com *.staging.musterbrand-system.com;
location / {
proxy_pass http://127.0.0.1:6081/;
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
proxy_read_timeout 600;
proxy_connect_timeout 600;
send_timeout 600;
- (void) resize:(NSDictionary *) properties
{
NSRect frame = [self.webView window].frame;
frame.size.width = [[properties valueForKey:@"width"] doubleValue];
frame.size.height = [[properties valueForKey:@"height"] doubleValue];
[[self.webView window] setFrame:frame display:YES];
}
- (void) resize
{
.right-icon-wrapper
.row-fluid.top-indicator
.left.span2
i.icon-double-angle-left
.right.span10  
.row-fluid.bottom-content
.left.span2
| 
.left-icons
span {% t send_message %}
#!/bin/bash
#/sbin/iptables -A INPUT -p udp -m udp --dport domain -j ACCEPT
#-A INPUT -p tcp -m tcp --dport 20000 -j ACCEPT
/sbin/iptables -A INPUT -i lo -j ACCEPT
/sbin/iptables -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
/sbin/iptables -A INPUT -p tcp -s 127.0.0.1 -m tcp --dport 10000 -j ACCEPT
/sbin/iptables -A INPUT -p tcp -m tcp --dport https -j ACCEPT
/sbin/iptables -A INPUT -p tcp -m tcp --dport http -j ACCEPT
#!/bin/sh
# firewall Start iptables firewall
# chkconfig: 2345 97 87
# description: Starts, stops and saves iptables firewall
# This script sets up the firewall for the INPUT chain (which is for
# the HN itself) and then processes the config files under
# /etc/firewall.d to set up additional rules in the FORWARD chain
# to allow access to containers' services.
# http://wiki.openvz.org/Setting_up_an_iptables_firewall
der
die
und
in
den
von
zu
das
mit
sich
class UrlValidator < ActiveModel::EachValidator
# Credits to Lee Machin https://coderwall.com/p/ztig5g
# Place this in app/validators/url_validator.rb
def validate_each(record, attribute, value)
record.errors[attribute] << (options[:message] || "must be a valid URL") unless url_valid?(value)
end
# a URL may be technically well-formed but may
class UrlValidator < ActiveModel::EachValidator
# Credits to Lee Machin https://coderwall.com/p/ztig5g
# Place this in app/validators/url_validator.rb
def validate_each(record, attribute, value)
record.errors[attribute] << (options[:message] || I18n.t(:must_be_valid_url)) unless url_valid?(value)
end
def url_valid?(url)
class UrlValidator < ActiveModel::EachValidator
# Credits to Lee Machin https://coderwall.com/p/ztig5g
# Place this in lib/validators/url_validator.rb
# class Something < ActiveRecord::Base
# validates :link, url: true
# end
def validate_each(record, attribute, value)
<!-- Google Code for EM robot CV 9703429128 1380558313 Conversion Page -->
<script type="text/javascript">
/* <![CDATA[ */
var google_conversion_id = 974657010;
var google_conversion_language = "de";
var google_conversion_format = "3";
var google_conversion_color = "ffffff";
var google_conversion_label = "2nzHCJaT-QYQ8qvg0AM";
var google_conversion_value = 0;
var google_remarketing_only = false;