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
# Ubuntu 22.04 はインストール完了しておく | |
# Nginx のインストール | |
sudo apt update | |
sudo apt install nginx | |
sudo systemctl start nginx | |
sudo systemctl enable nginx | |
# MariaDB のインストール |
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
# 取得したドメインのDNS設定を完了しておく(TTL : 1800) | |
# Ubuntu 22.04 はインストールしておく | |
# 必要なものを root でインストールとリポジトリ追加 | |
sudo apt install nginx gnupg2 openjdk-11-jdk curl apt-transport-https | |
sudo apt-add-repository universe | |
sudo apt update | |
# ホスト名の設定 | |
sudo hostnamectl set-hostname meet.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
S3_ENABLED=true | |
S3_BUCKET=media.yourdomain.com ← 自分の作ったバケット名(mediaなどをつけてエイリアスを使う場合はOptionalも設定する) | |
AWS_ACCESS_KEY_ID=ABCDEFGHIJKLMNOPQRST ← 設定されたアクセスキー | |
AWS_SECRET_ACCESS_KEY=ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890abcd ← 設定されたシークレットキー | |
S3_REGION=ap-northeast-1 ← 東京リージョンならこれ | |
S3_PROTOCOL=https | |
S3_ENDPOINT=https://s3-ap-northeast-1.amazonaws.com ← 東京リージョンならこれ | |
# Optional alias for S3 (e.g. to serve files on a custom domain, possibly using Cloudfront or Cloudflare) | |
S3_CLOUDFRONT_HOST=media.yourdomain.com ←ここに自分の設定した S3Bucket と Cloudflare で合わせた CNAME 入れる |
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
# systemctl stop mastodon* | |
# su - mastodon | |
$ cd ~/.rbenv | |
$ git pull | |
$ cd ~/.rbenv/plugins/ruby-build | |
$ git pull | |
$ cd ~/.rbenv | |
$ rbenv install 2.4.2 | |
$ rbenv global 2.4.2 |
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
#Mastodon を止める | |
systemctl stop mastodon-{web,sidekiq,streaming}.service | |
#まず PostgreSQL のリポジトリを追加して、アップデートする | |
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add - | |
sudo add-apt-repository "deb http://apt.postgresql.org/pub/repos/apt/ xenial-pgdg main" | |
sudo apt update | |
#今回は PostgreSQL 10 にするのでバージョンを指定してインストール | |
sudo apt install postgresql-10 postgresql-client-10 postgresql-contrib-10 |
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
#Mastodon を止める | |
systemctl stop mastodon-{web,sidekiq,streaming}.service | |
#クラスタを確認 | |
pg_lsclusters | |
#下記のように 2 つの PostgreSQL が見えるはず | |
Ver Cluster Port Status Owner Data directory Log file | |
11 main 5432 online postgres /var/lib/postgresql/11/main /var/log/postgresql/postgresql-11-main.log | |
12 main 5433 online postgres /var/lib/postgresql/12/main /var/log/postgresql/postgresql-12-main.log | |
#このときは 12 の接続先が 5433 になっていて、まだ 11 が通常ポートの 5432 につながった状態 |
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
#まずさっきの Yarn の設定をして、キーを更新して全体のアプデは終わらせておく | |
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add - | |
echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list | |
sudo apt update | |
sudo apt upgrade -y | |
#リリースノートにある Node の 10 入れる | |
curl -sL https://deb.nodesource.com/setup_10.x | bash - | |
sudo apt update | |
sudo apt install nodejs |
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
#うちはだいぶ前に追加してたんだけど、Ubuntu 16.04 でまだ追加してない人は Redis をバージョンアップするためにこのリポジトリ追加する | |
#Ubuntu 18.04 の人は大丈夫みたい | |
add-apt-repository ppa:chris-lea/redis-server | |
apt update && apt upgrade | |
#Mastodon を止める | |
systemctl stop mastodon-{web,sidekiq,streaming}.service | |
#Mastodon ユーザになる | |
sudo su - mastodon |
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
#Mastodon を止める | |
systemctl stop mastodon-{web,sidekiq,streaming}.service | |
#Mastodon ユーザになる | |
sudo su - mastodon | |
#今回の Ruby 2.6.5 のアップデートをするためにrbenvのおいてあるディレクトリに移り最新版をダウンロード | |
cd ~/.rbenv | |
git pull |
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
#Mastodonを止める | |
systemctl stop mastodon-{web,sidekiq,streaming}.service | |
#Mastodonユーザになる | |
sudo su - mastodon | |
#Rubyのアップデートをするためにrbenvのおいてあるディレクトリに移り最新版をダウンロード | |
cd ~/.rbenv | |
git pull | |
#同じようにプラグインのディレクトリに移り最新版をダウンロード |
NewerOlder