Skip to content

Instantly share code, notes, and snippets.

View digdag-error.log
$ digdag server --config server.properties
2020-12-11 13:38:05 +0900: Digdag v0.9.42
2020-12-11 13:38:06 +0900 [INFO] (main): secret encryption engine: aesgcm
2020-12-11 13:38:07 +0900 [INFO] (main): Applying database migration:20151204221156
2020-12-11 13:38:07 +0900 [INFO] (main): Applying database migration:20160602123456
2020-12-11 13:38:07 +0900 [INFO] (main): Applying database migration:20160602184025
2020-12-11 13:38:07 +0900 [INFO] (main): Applying database migration:20160610154832
2020-12-11 13:38:07 +0900 [INFO] (main): Applying database migration:20160623123456
2020-12-11 13:38:07 +0900 [INFO] (main): Applying database migration:20160719172538
Exception in thread "main" java.lang.Error: java.lang.reflect.InvocationTargetException
View sed
- 完全一致
sed -i "s/'utf8'/'utf8mb4'/g" test
sed -i "/'client'/a default-character-set=utf8mb4" my.cnf
View vuls-docker-update.sh
#!/bin/bash
set -e
## Current goval/go-cve-dictionary,Vuls version
echo -e "----Current goval/go-cve-dictionary/gost,Vuls version----"
docker run --rm vuls/go-cve-dictionary -v
docker run --rm vuls/goval-dictionary -v
docker run --rm vuls/gost -v
View git-command.memo
### Git command
# git pull時にマージされたローカルリポジトリを削除
$ git branch --merged | grep -vE '^\*|master$|develop$' | xargs -I % git branch -d %
# リモートブランチをローカルブランチにする
$ git ch -b adachin-develop origin/adachin-develop
# fetchやpullする際に自動的にリモートで削除されているリモートブランチを削除
$ git fetch --prune
View memo.sql
・dtテーブルの削除
mysql> START TRANSACTION;
Query OK, 0 rows affected (0.00 sec)
mysql> delete from daily_profile_views where dt='2018-05-30';
Query OK, 13031 rows affected (0.60 sec)
mysql> delete from daily_profile_views where dt LIKE '2018-%';
Query OK, 8843 rows affected, 1 warning (0.30 sec)
@RVIRUS0817
RVIRUS0817 / vim.txt
Last active May 21, 2019
vim command memo
View vim.txt
### Vim command
- `があったら削除
:%s/`//g
- 改行削除
:%s/\n//g
- 空白削除
:%s/ //g
@RVIRUS0817
RVIRUS0817 / vscode-command
Last active Jan 28, 2019
how to use vscode
View vscode-command
■vscode command
・文字列検索 grep
Command Shift f
・検索 ファイル検索
Command p
・プロジェクトを開く
Command o
View lambda_function-general.py
import datetime
import time
import boto3
log_name_general = 'general-log'
log_group_name_general = '/aws/rds/cluster/xxxxx/general'
s3_bucket_name = 'xxxxxxxxxx'
s3_prefix_general = 'xxxx/log/mysql/' + log_name_general + '/%s' % (datetime.date.today().strftime("%Y")) + '/%s' % (datetime.date.today().strftime("%m")) + '/%s' % (datetime.date.today().strftime("%d"))
def get_from_timestamp():
@RVIRUS0817
RVIRUS0817 / vuls_autoscan.sh
Last active Oct 22, 2018
centos/amazonlinux
View vuls_autoscan.sh
#!/bin/bash
RETRY=3
PAST_YEAR=2
########################
VULS_HOME=`cd $(dirname $0) && pwd`
VULS_LOG="${VULS_HOME}/results"
@RVIRUS0817
RVIRUS0817 / sidekiq
Last active Sep 26, 2018
/etc/init.d/ centos/amazonlinux
View sidekiq
#!/bin/sh
# chkconfig: 2345 90 10
# description: sidekiq system status
NAME="sidekiq"
ROOT_DIR="/var/www/sidekiq"
PID="/var/www/sidekiq/tmp/pids/sidekiq.pid"
CONF="/var/www/sidekiq/config/sidekiq.yml"