This file contains hidden or 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
for a in *.jpg; do convert $a -fuzz 50% -fill black -opaque "#00ff00" -type Grayscale ../MASKS/$a;done |
This file contains hidden or 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
iptables -A INPUT -p tcp --dport 8080 -j ACCEPT | |
iptables -A INPUT -p tcp --dport 8181 -j ACCEPT | |
iptables -A INPUT -p tcp --dport 80 -j ACCEPT | |
iptables -t nat -A PREROUTING -p tcp -m tcp --dport 80 -j REDIRECT --to-ports 8080 | |
iptables -A INPUT -p tcp --dport 443 -j ACCEPT | |
iptables -t nat -A PREROUTING -p tcp -m tcp --dport 443 -j REDIRECT --to-ports 8181 |
This file contains hidden or 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
# When http then https but no redirect for "knowledgebase" path | |
$HTTP["scheme"] == "http" { | |
$HTTP["host"] =~ "secure.site.com" { | |
url.redirect = ( "^/(?!(knowledgebase).*)" => "https://secure.site.com/$1" ) | |
server.document-root = "/site/secure" | |
} | |
} | |
#behavior for SSL | |
$HTTP["scheme"] == "https" { | |
$HTTP["host"] =~ "^secure\.site\.com" { |
This file contains hidden or 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 | |
# description: Glassfish Start Stop Restart | |
# processname: glassfish | |
# chkconfig: 234 20 80 | |
JAVA_HOME=/usr/java/default | |
export JAVA_HOME | |
PATH=$JAVA_HOME/bin:$PATH | |
export PATH | |
GLASSFISH_HOME=/usr/local/glassfish4/glassfish | |
GLASSFISH_USER=glassfish |
This file contains hidden or 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
all: | |
$(MAKE) -C directory1 | |
$(MAKE) -C directory2 | |
$(MAKE) -C directory3 | |
clean: | |
$(MAKE) -C directory1 clean | |
$(MAKE) -C directory2 clean | |
$(MAKE) -C directory3 clean |
This file contains hidden or 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
#this is a part of the original playbook: | |
- name: Creating pub SSH keys | |
command: ssh-keygen -N '' -f /root/.ssh/id_rsa | |
- name: Downloading pub key | |
fetch: src=/root/.ssh/id_rsa.pub dest=/tmp/id_rsa.tmp flat=yes | |
- name: Coping local key to other.server.net | |
local_action: shell cat /tmp/id_rsa.tmp | ssh -p 2244 [email protected] "cat >> /root/.ssh/authorized_keys" |
This file contains hidden or 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 | |
# | |
# iperf advanced bandwidth test tool | |
# | |
# chkconfig: - 90 60 | |
# description: iperf is an advanced bandwidth test tool | |
# processname: iperf | |
# pidfile: /var/run/iperf.pid | |
# Source function library. | |
. /etc/init.d/functions |
This file contains hidden or 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
# Configuration for collectd-web | |
ScriptAlias /stats/cgi-bin/ /var/www/collectd-web-master/cgi-bin/ | |
Alias /stats/ /var/www/collectd-web-master/ | |
DirectoryIndex index.html | |
<Directory "/var/www/collectd-web-master/"> | |
AllowOverride All | |
AuthType Basic | |
AuthName "Restringido" |
This file contains hidden or 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
#!/usr/bin/python | |
# | |
# This program is free software: you can redistribute it and/or modify | |
# it under the terms of the GNU General Public License as published by | |
# the Free Software Foundation, either version 3 of the License, or | |
# (at your option) any later version. | |
# | |
# This program is distributed in the hope that it will be useful, | |
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
This file contains hidden or 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
#!/usr/bin/env python | |
import os, smtplib | |
from sys import exit |