Skip to content

Instantly share code, notes, and snippets.

View drumsco's full-sized avatar

Munenori TAKEI drumsco

View GitHub Profile
@drumsco
drumsco / 00-nginx_status.conf
Created July 31, 2024 02:33
nginx stub_status configuration
server {
listen 80;
server_name localhost;
location /nginx_status {
stub_status on;
access_log off;
server_tokens on;
allow 127.0.0.1;
allow ::1;
# Apache Tomcat logrotate
/opt/apache-tomcat/logs/catalina.out
/opt/apache-tomcat/logs/localhost_access_log.txt
{
copytruncate
daily
rotate 7
compress
missingok
@drumsco
drumsco / jmx-remote.xml
Last active June 6, 2017 03:22
Firewalld service definition file for Java Management Extensions (JMX).
<?xml version="1.0" encoding="utf-8"?>
<service>
<short>Java Management Extensions</short>
<description>This option allows you to access Java Management Extensions (JMX) listening port.
You need the java package installed for this option to be useful.</description>
<port protocol="tcp" port="8686"/>
</service>
@drumsco
drumsco / OutlookConfirmRecipients.vba
Created April 12, 2017 03:55
Outlook で送信先確認ダイアログを表示させる VBA マクロ
Private Sub Application_Itemsend(ByVal Item As Object, Cancel As Boolean)
Dim strCC
strCC = vbCrLf
Dim objRec As Recipient
For Each objRec In Item.Recipients
strCC = strCC & objRec.Name & vbCrLf
Next
@drumsco
drumsco / git-svn-relocate.sh
Last active February 21, 2017 12:15
svn switch --relocate のようにベースとする Subversion リポジトリの再配置をしてくれる。 http://d.hatena.ne.jp/do_aki/20110530/1306751266
#!/bin/sh
GIT_CONFIG='.git/config'
OLD_REP=$1
NEW_REP=$2
WORKSPACE=$3
# show usage
if [ -z "$OLD_REP" -o -z "$NEW_REP" ]; then
@drumsco
drumsco / zabbix-java-gateway.xml
Last active December 18, 2015 06:41
Firewalld service definition file for zabbix-java-gateway package.
<?xml version="1.0" encoding="utf-8"?>
<service>
<short>Zabbix Java Gateway</short>
<description>This option allows to access Zabbix Java Gateway listening port.
You need the zabbix-java-gateway package installed for this option to be useful.</description>
<port protocol="tcp" port="10052"/>
</service>
@drumsco
drumsco / zabbix-server.xml
Last active December 18, 2015 06:35
Firewalld service definition file for zabbix-server package.
<?xml version="1.0" encoding="utf-8"?>
<service>
<short>Zabbix Server</short>
<description>This option allows you to access Zabbix Server listening port.
You need the zabbix-server package or zabbix-proxy package installed for this option to be useful.</description>
<port protocol="tcp" port="10051"/>
</service>
@drumsco
drumsco / zabbix-agent.xml
Last active December 18, 2015 06:36
Firewalld service definition file for zabbix-agent package.
<?xml version="1.0" encoding="utf-8"?>
<service>
<short>Zabbix Agent</short>
<description>This option allows you to access Zabbix Agent listening port.
You need the zabbix-agent package installed for this option to be useful.</description>
<port protocol="tcp" port="10050"/>
</service>