Skip to content

Instantly share code, notes, and snippets.

@jubel-han
jubel-han / sonar-project.properties
Created February 6, 2015 07:03
sonar-project.properties example file
# an sonar-project.properties example file
sonar.projectKey=org.apache.thrift
sonar.projectName=Apache Thrift
sonar.projectDescription=
The Apache Thrift software framework, for scalable cross-language services
development, combines a software stack with a code generation engine to build
services that work efficiently and seamlessly between all major languages.
# Apache Thrift Version
sonar.projectVersion=1.0.0-dev
# use this to set another version string
# set public key
# update VM
sudo apt-get update
# JAVA installation
sudo add-apt-repository ppa:webupd8team/java && sudo apt-get update && sudo apt-get install oracle-java7-installer && sudo apt-get install oracle-java7-set-default
# install git
sudo apt-get install git zip ant
@jubel-han
jubel-han / Vagrantefile
Created February 6, 2015 07:12
an Vagrantfile example( multiple vms )
# -*- mode: ruby -*-
# vi: set ft=ruby :
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.define "ylmaster" do |ylmaster|
config.vm.provider :virtualbox do |vb|
@jubel-han
jubel-han / create_sonar_mysql_db.sql
Created February 6, 2015 07:17
Create Sonar database and user.
# Command: mysql -u root -p < create_sonar_database.sql
#
CREATE DATABASE sonar CHARACTER SET utf8 COLLATE utf8_general_ci;
CREATE USER 'sonar' IDENTIFIED BY 'sonar';
GRANT ALL ON sonar.* TO 'sonar'@'%' IDENTIFIED BY 'sonar';
GRANT ALL ON sonar.* TO 'sonar'@'localhost' IDENTIFIED BY 'sonar';
FLUSH PRIVILEGES;
@jubel-han
jubel-han / zabbix_send_notify_hipchat
Last active February 15, 2017 03:27
zabbix notify to hipchat actions
{
"HIPCHAT": ["zabbix", "TOKEN", "api.hipchat.com"],
"TRIGGER": {
"NAME": "{TRIGGER.NAME}",
"STATUS": "{TRIGGER.STATUS}",
"SEVERITY": "{TRIGGER.SEVERITY}",
"URL": "{TRIGGER.URL}"
},
"ITEM": {
"NAME": "{ITEM.NAME1}",
@jubel-han
jubel-han / nginx.conf
Last active August 29, 2015 14:21 — forked from plentz/nginx.conf
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048
@jubel-han
jubel-han / nginx.conf
Last active August 29, 2015 14:22 — forked from jrom/nginx.conf
if ($request_uri = /) {
set $test A;
}
if ($host ~* teambox.com) {
set $test "${test}B";
}
if ($http_cookie !~* "auth_token") {
set $test "${test}C";
server {
listen 443 ssl spdy;
server_name sslplayground.dev;
root /var/www/sslplayground;
index index.html;
# Enable SSL
ssl on;
ssl_certificate /etc/nginx/conf.d/server.crt;
ssl_certificate_key /etc/nginx/conf.d/server.key;
#!/bin/bash
usage ()
{
cat <<UsageHERE
boot2docker-fwd -- Helper function to quickly manage port forwards between the boot2docker-vm and the host
Usage: boot2docker-fwd [ -n RULE_NAME ] [ -h HOST_PORT ] [ -p {tcp|udp} ] [ -i HOST_IP ] GUEST_PORT
or boot2docker-fwd -d RULE_NAME
or boot2docker-fwd -l
or boot2docker-fwd -A