Skip to content

Instantly share code, notes, and snippets.

@Caixiaopig
Caixiaopig / gist:7bfdbc2c285d8e973a49
Created October 14, 2015 03:18
Mac下面设置Java的环境变量,可以避免其使用系统代理
因为Java不遵守游戏规则,在Mac下面使用系统代理的时候不按照bypass规则来玩,所以只能在启动的java进程的时候去禁止掉了。传入如下参数即可:
-Dhttps.proxyHost
-Dhttps.proxyPort
-Dhttp.proxyHost
-Dhttp.proxyPort
-DsocksProxyHost
-DsocksProxyPort
-Djava.net.useSystemProxies=false
#!/bin/sh
#
# Startup script for the DNS caching server
#
# chkconfig: - 49 50
# description: This script starts your DNS caching server
# processname: dnsmasq
# pidfile: /var/run/dnsmasq
# Source function library.
nameserver 202.96.209.5
nameserver 202.96.209.133
nameserver 223.5.5.5
nameserver 223.6.6.6
nameserver 114.114.114.114
nameserver 8.8.4.4
@Caixiaopig
Caixiaopig / dnsmasq.conf
Created August 1, 2015 05:53
dnsmasq.conf
#ITGeeker每次开启都提示错误,目的是让dnsmasq读取目录内所有配置文件
#conf-dir=/etc/dnsmasq.d
#让dnsmasq读取你设定的resolv-file
#no-resolv
resolv-file=/etc/dnsmasq.d/resolv.dnsmasq.conf
no-poll
strict-order
@Caixiaopig
Caixiaopig / set_reis_start.sh
Created July 27, 2015 09:46
设置redis自启动的脚本
#!/bin/sh
#
# redis Startup script for Redis Server
#
# chkconfig: - 80 12
# description: Redis is an open source, advanced key-value store.
#
# processname: redis-server
# config: /etc/redis.conf
# pidfile: /var/run/redis.pid
#!/bin/bash
#
# httpd Startup script for the Apache HTTP Server
#
# chkconfig: - 85 15
# description: The Apache HTTP Server is an efficient and extensible \
# server implementing the current HTTP standards.
# processname: httpd
# config: /etc/httpd/conf/httpd.conf
# config: /etc/sysconfig/httpd