Skip to content

Instantly share code, notes, and snippets.

Avatar

Diego Plentz plentz

View GitHub Profile
View default.rb
include_recipe "logrotate"
logrotate_app "tomcat" do
cookbook "logrotate"
path "/var/log/tomcat/catalina.out"
options ["copytruncate", "missingok", "notifempty"]
frequency "daily"
rotate 3
create "644 tomcat tomcat"
size "50M"
View recover_opsworks_sg.sh
#!/bin/sh
# creating security groups
ec2-create-group 'AWS-OpsWorks-Web-Server' -d 'AWS OpsWorks Web server - do not change or delete'
ec2-create-group 'AWS-OpsWorks-Default-Server' -d 'AWS OpsWorks Default server - do not change or delete'
ec2-create-group 'AWS-OpsWorks-Blank-Server' -d 'AWS OpsWorks blank server - do not change or delete'
ec2-create-group 'AWS-OpsWorks-LB-Server' -d 'AWS OpsWorks load balancer - do not change or delete'
ec2-create-group 'AWS-OpsWorks-PHP-App-Server' -d 'AWS OpsWorks PHP-App server - do not change or delete'
ec2-create-group 'AWS-OpsWorks-DB-Master-Server' -d 'AWS OpsWorks database master server - do not change or delete'
ec2-create-group 'AWS-OpsWorks-Memcached-Server' -d 'AWS OpsWorks Memcached server - do not change or delete'
ec2-create-group 'AWS-OpsWorks-Monitoring-Master-Server' -d 'AWS OpsWorks Monitoring Ganglia server - do not change or delete'
View gist:171280
#hudson auto-update job
cd /usr/share/jetty6/webapps/
wget http://hudson-ci.org/latest/hudson.war
mv hudson.war.1 hudson.war
touch /usr/share/jetty6/contexts/hudson.xml
View hibernate translations
You will need po2xml
http://www.hibernate.org/422.html
http://www.hibernate.org/30.html
Using mac http://mac.kde.org/
You are not modifying the PO/POT files correctly.
The general process should be to:
1) make change in the master
2) run the pot update process (mvn jdocbook:update-pot)
View ubuntu
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install build-essential
sudo apt-get install sun-java6-jdk
sudo update-java-alternatives --set java-6-sun
sudo apt-get install nginx libjetty-java libjetty-extra-java jetty
apt-get autoremove
View gist:315727
sudo gem uninstall --a --ignore-dependencies .+
View rails ignoring rails_env
server {
listen 80;
server_name foo.bar.com;
root /home/ruby/apps/my_app/public;
passenger_enabled on;
rails_env foo;
}
server {
listen 80;
@plentz
plentz / gist:641118
Created Oct 22, 2010
não foi dessa vez
View gist:641118
Opa,
Bom, estou mandando esse email (atrasado, pelo que tinha prometido pra alguns) pra avisar que infelizmente
você não foi selecionado pra trabalhar com a gente. Agradeço *muito* o interesse em entrar na nossa equipe,
e espero que não desista.
Quem sabe na próxima vez você surpreenda a gente? Seja com algum livro novo que tenha lido(aqui tem uma
lista bem bacana http://plentz.org/unsorted/mustread.html) ou com alguma contribuição que tenha
feito em um projeto opensource (aqui tem algunsque usamos e gostamos http://github.com/plentz/following).
View gist:655248
Oct 24, 2010 9:44:29 PM NewRelic WARNING: Unable to create a Hibernate statistics sampler : java.lang.reflect.InvocationTargetException
Oct 24, 2010 9:48:24 PM NewRelic SEVERE: An ASM array bounds exception occurred transforming class org/postgresql/jdbc3/AbstractJdbc3Statement (11.931 bytes) : java.lang.ArrayIndexOutOfBoundsException: 51966
Oct 25, 2010 12:08:55 PM NewRelic SEVERE: The tracer stack is inconsistent com.newrelic.agent.tracers.ErrorReportingTracer / None
Oct 25, 2010 12:08:55 PM NewRelic SEVERE: The tracer stack is inconsistent com.newrelic.agent.tracers.servlet.ServletTracer / com.newrelic.agent.instrumentation.pointcuts.database.CreatePreparedStatementPointCut$CreatePreparedStatementTracer
Oct 28, 2010 3:36:41 PM NewRelic SEVERE: The tracer stack is inconsistent com.newrelic.agent.tracers.servlet.ServletTracer / None
Oct 28, 2010 3:38:24 PM NewRelic SEVERE: The tracer stack is inconsistent com.newrelic.agent.instrumentation.pointcuts.container.jetty.JettyDispatcherTracerFactory$JettyDispatche
View gist:706648