This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Lightsail WordPress の Let's Encrypt による SSL 化スクリプト | |
# | |
# 第 1 引数: ドメイン | |
# 第 2 引数: メールアドレス | |
# | |
# 使用例) ./setup_lightsail_wordpress_letsencrypt.sh example.com mail@example.com | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM alpine:3.9 | |
ENV HUB_VERSION=2.8.4 | |
ENV HUB_DIR=hub-linux-amd64-${HUB_VERSION} | |
ENV HUB_TGZ=${HUB_DIR}.tgz | |
RUN apk add --no-cache \ | |
git \ | |
curl \ | |
libc6-compat \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash -eu -o pipefail | |
# | |
# ある組織の全リポジトリをPull (CloneしていなければClone) するシェルスクリプト | |
# | |
# 前提: GitHubのSSH鍵が設定済であること | |
# 依存関係: git, jq | |
# 注意: GitHub APIの制限に注意してください | |
# カレントディレクトリではなく、このスクリプトが存在するディレクトリで実行する | |
cd `dirname $0` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash -eu | |
TARGET_FILE=${1:-.htpasswd} | |
USER=user | |
PASSWORD=password | |
docker run \ | |
--rm \ | |
httpd \ | |
htpasswd -nbs $USER $PASSWORD \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
PREFIX=private-key | |
cd `dirname $0` | |
openssl genrsa 2048 > $PREFIX.pem | |
openssl req -new -key $PREFIX.pem > $PREFIX.csr | |
openssl x509 -req -signkey $PREFIX.pem < $PREFIX.csr > $PREFIX.crt |