sudo yum update -y && sudo reboot
sudo yum install -y --enablerepo=epel bash-completion
sudo yum install -y git jq
version: '2' | |
services: | |
db: | |
image: mysql:5.7 | |
volumes: | |
- db_data:/var/lib/mysql | |
restart: always | |
environment: | |
MYSQL_ROOT_PASSWORD: wordpress |
sudo yum update -y && sudo reboot
sudo yum install -y --enablerepo=epel bash-completion
sudo yum install -y git jq
#!/bin/bash | |
tmpdir=$(mktemp -d -p "./") | |
tmpf=$(mktemp -u) | |
mkfifo $tmpf | |
#!/bin/bash | |
set -me | |
function exitf(){ | |
echo "catch exit" | |
} | |
function excep(){ | |
echo "catch exception" | |
} |
#!/bin/bash | |
shopt -s extglob | |
string='@(foo|bar)' | |
read choice | |
case $choice in | |
$string ) printf 'String choice %-20s' "$choice"; ;; | |
$s1|$s2 ) printf 'Two val choice %-20s' "$choice"; ;; | |
*) printf 'A Bad choice! %-20s' "$choice"; ;; |
#cloud-config | |
repo_update: true | |
repo_upgrade: all | |
timezone: "Asia/Tokyo" | |
power_state: | |
mode: reboot | |
yum -y update | |
yum install -y openldap-servers openldap-clients | |
yum install -y --enablerepo=epel ldapvi | |
echo -e '#ldaplog\nlocal4.*\t-/var/log/ldaplog' > /etc/rsyslog.d/ldap.conf | |
sed -i '3s/\(.*\)/\1\n\/var\/log\/ldaplog/' /etc/logrotate.d/syslog | |
service rsyslog restart | |
cp /usr/share/openldap-servers/DB_CONFIG.example /var/lib/ldap/DB_CONFIG |
yum -y update | |
yum install -y openldap-servers openldap-clients | |
yum install -y --enablerepo=epel ldapvi | |
echo -e '#ldaplog\nlocal4.*\t-/var/log/ldaplog' > /etc/rsyslog.d/ldap.conf | |
sed -i '3s/\(.*\)/\1\n\/var\/log\/ldaplog/' /etc/logrotate.d/syslog | |
service rsyslog restart | |
cp /usr/share/openldap-servers/DB_CONFIG.example /var/lib/ldap/DB_CONFIG |
yum install -y git | |
cd | |
curl -s https://raw.githubusercontent.com/Shougo/dein.vim/master/bin/installer.sh > installer.sh | |
sh ./installer.sh ~/.vim | |
cat <<'EOF' > ~/.vimrc | |
set noexpandtab | |
set autoindent | |
set smartindent |
#!/bin/bash | |
set -eu | |
atexit() { | |
[[ -n $tmpfile ]] && rm -f "$tmpfile" | |
} | |
tmpfile=$(mktemp "/tmp/${0##*/}.tmp.XXXXXX") | |
trap atexit EXIT | |
trap 'atexit; exit -1' SIGHUP SIGINT SIGTERM |