TYPO3インストール · 4 min read · Nov 06, 2025
Ubuntu 20.04にLet's Encrypt SSLを使用してTYPO3 CMSをインストールする方法

TYPO3はPHPで書かれた無料でオープンソースのコンテンツ管理システムです。これは、オープンソースコードと信頼性、真のスケーラビリティを組み合わせたエンタープライズクラスのCMSです。ウェブサーバー上で動作し、Windows、Linux、macOSなど多くのオペレーティングシステムをサポートしています。これはシンプルで、レスポンシブで、モバイル対応で、安全なCMSであり、コードを書くことなく簡単にカスタマイズおよび拡張できます。これは、ウェブサイトを迅速に立ち上げるための非常に人気があり、素晴らしい選択肢です。
このチュートリアルでは、Ubuntu 20.04にApacheウェブサーバーとLet’s Encrypt SSLを使用してTYPO3 CMSをインストールする方法を示します。
前提条件
- Ubuntu 20.04を実行しているサーバー。
- サーバーIPにポイントされた有効なドメイン名。
- サーバーに設定されたルートパスワード。
始めに
まず、システムパッケージを最新バージョンに更新することをお勧めします。次のコマンドを実行してすべてのパッケージを更新できます。
apt-get update -yすべてのパッケージが最新の状態になったら、次のステップに進むことができます。
LAMPサーバーのインストール
次に、サーバーにApacheウェブサーバー、MariaDB、PHP、およびその他のPHP拡張機能をインストールする必要があります。次のコマンドを使用してすべてをインストールできます。
apt-get install apache2 mariadb-server php libapache2-mod-php php-common php-gmp php-curl php-intl php-mbstring php-xmlrpc php-mysql php-gd php-xml php-cli php-zip curl git gnupg2 -yすべてのパッケージをインストールした後、php.iniファイルを編集していくつかの推奨設定を変更します。
nano /etc/php/7.4/apache2/php.ini次の行を変更します。
memory_limit = 256M
upload_max_filesize = 100M
post_max_size = 100M
max_execution_time = 360
max_input_vars = 1500
date.timezone = Asia/Kolkata
ファイルを保存して閉じたら、変更を適用するためにApacheサービスを再起動します。
systemctl restart apache2TYPO3用のデータベースを作成
次に、TYPO3用のデータベースとユーザーを作成する必要があります。まず、次のコマンドを使用してMariaDBシェルにログインします。
mysqlログインしたら、次のコマンドを使用してデータベースとユーザーを作成します。
MariaDB [(none)]> CREATE DATABASE typo3db;
MariaDB [(none)]> CREATE USER ''@'localhost' IDENTIFIED BY 'password';次に、次のコマンドを使用してtypo3dbにすべての権限を付与します。
MariaDB [(none)]> GRANT ALL ON typo3db.* TO 'typo3'@'localhost' IDENTIFIED BY 'password' WITH GRANT OPTION;次に、権限をフラッシュしてMariaDBから退出します。
MariaDB [(none)]> FLUSH PRIVILEGES;
MariaDB [(none)]> EXIT;この時点で、MariaDBデータベースが設定されました。
TYPO3 CMSのインストール
まず、公式ウェブサイトからTYPO3の最新バージョンをダウンロードする必要があります。curlコマンドを使用してダウンロードできます。
curl -L -o typo3_src.tgz https://get.typo3.org/10.4.9ダウンロードが完了したら、次のコマンドを使用してダウンロードしたファイルを抽出します。
tar -xvzf typo3_src.tgz次に、抽出したディレクトリをApacheのウェブルートディレクトリに移動します。
mv typo3_src-10.4.9 /var/www/html/typo3次に、次のコマンドを使用して適切な権限を与えます。
chown -R www-data:www-data /var/www/html/typo3
chmod -R 775 /var/www/html/typo3完了したら、次のステップに進むことができます。
TYPO3用のApacheの設定
次に、TYPO3 CMSをホストするためのApache仮想ホスト設定ファイルを作成します。次のコマンドを使用して作成できます。
nano /etc/apache2/sites-available/typo3.conf次の行を追加します。
ServerAdmin [email protected]
DocumentRoot /var/www/html/typo3
ServerName typo3.example.com
Options +FollowSymlinks
AllowOverride All
Require all granted
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
ファイルを保存して閉じたら、次のコマンドを使用して仮想ホスト設定ファイルとリライトモジュールを有効にします。
a2ensite typo3.conf
a2enmod rewrite次に、変更を適用するためにApacheサービスを再起動します。
systemctl restart apache2この時点で、ApacheウェブサーバーはTYPO3を提供するように設定されています。次のステップに進むことができます。
TYPO3 CMSにアクセス
今、ウェブブラウザを開いて、URL http://typo3.example.com を使用してTYPO3にアクセスします。次のページが表示されるはずです。

新しいサーバーにTYPO3をインストールしている場合は、TYPO3のウェブルートディレクトリ内にFIRST_INSTALLファイルを作成する必要があります。次のコマンドを使用して作成できます。
touch /var/www/html/typo3/FIRST_INSTALL次に、ウェブページを更新します。次のページが表示されるはずです。

問題は検出されませんでした。インストールを続行しますをクリックすると、次のページが表示されます。

データベースのユーザー名、パスワード、ホストを入力し、続行ボタンをクリックします。次のページが表示されるはずです。

TYPO3データベース名を選択し、続行ボタンをクリックします。次のページが表示されるはずです。

次に、管理ユーザー名、パスワード、サイト名を入力し、続行ボタンをクリックします。TYPO3のログインページにリダイレクトされます。

管理ユーザー名、パスワードを入力し、ログインボタンをクリックします。次のページにTYPO3ダッシュボードが表示されるはずです。

Let’s EncryptでTYPO3を保護
ウェブサイトをLet’s Encryptの無料SSLで保護することをお勧めします。まず、SSLをインストールおよび管理するためにCertbotクライアントをインストールします。次のコマンドを使用してインストールできます。
apt-get install python3-certbot-apache -yインストールが完了したら、次のコマンドを実行してウェブサイトをLet’s Encrypt SSLで保護します。
certbot --apache -d typo3.example.com次のように、メールアドレスを提供し、利用規約に同意するよう求められます。
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator standalone, Installer None
Enter email address (used for urgent renewal and security notices) (Enter 'c' to
cancel): [email protected]
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Please read the Terms of Service at
https://letsencrypt.org/documents/LE-SA-v1.2-November-15-2017.pdf. You must
agree in order to register with the ACME server at
https://acme-v02.api.letsencrypt.org/directory
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(A)gree/(C)ancel: A
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Would you be willing to share your email address with the Electronic Frontier
Foundation, a founding partner of the Let's Encrypt project and the non-profit
organization that develops Certbot? We'd like to send you email about our work
encrypting the web, EFF news, campaigns, and ways to support digital freedom.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(Y)es/(N)o: Y
Plugins selected: Authenticator apache, Installer apache
Obtaining a new certificate
Performing the following challenges:
http-01 challenge for typo3.example.com
Enabled Apache rewrite module
Waiting for verification...
Cleaning up challenges
Created an SSL vhost at /etc/apache2/sites-available/typo3-le-ssl.conf
Enabled Apache socache_shmcb module
Enabled Apache ssl module
Deploying Certificate to VirtualHost /etc/apache2/sites-available/typo3-le-ssl.conf
Enabling available site: /etc/apache2/sites-available/typo3-le-ssl.conf
次に、HTTPトラフィックをHTTPSにリダイレクトするかどうかを選択します。
Please choose whether or not to redirect HTTP traffic to HTTPS, removing HTTP access.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
1: No redirect - Make no further changes to the webserver configuration.
2: Redirect - Make all requests redirect to secure HTTPS access. Choose this for
new sites, or if you're confident your site works on HTTPS. You can undo this
change by editing your web server's configuration.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Select the appropriate number [1-2] then [enter] (press 'c' to cancel): 2
2を入力してEnterを押して、ウェブサイトのLet’s Encrypt SSLをインストールします。
Enabled Apache rewrite module
Redirecting vhost in /etc/apache2/sites-enabled/typo3.conf to ssl vhost in /etc/apache2/sites-available/typo3-le-ssl.conf
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Congratulations! You have successfully enabled https://typo3.example.com
You should test your configuration at:
https://www.ssllabs.com/ssltest/analyze.html?d=typo3.example.com
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
IMPORTANT NOTES:
- Congratulations! Your certificate and chain have been saved at:
/etc/letsencrypt/live/typo3.example.com/fullchain.pem
Your key file has been saved at:
/etc/letsencrypt/live/typo3.example.com/privkey.pem
Your cert will expire on 2020-10-23. To obtain a new or tweaked
version of this certificate in the future, simply run certbot again
with the "certonly" option. To non-interactively renew *all*
of your certificates, run "certbot renew"
- If you like Certbot, please consider supporting our work by:
Donating to ISRG / Let's Encrypt: https://letsencrypt.org/donate
Donating to EFF: https://eff.org/donate-le
これで、URL https://typo3.example.com を使用してTYPO3 CMSに安全にアクセスできます。
結論
おめでとうございます!Ubuntu 20.04にTYPO3 CMSを正常にインストールし、Let’s Encrypt SSLで保護しました。これで、ウェブブラウザを通じて簡単にウェブサイトやブログを作成できます。質問があればお気軽にお尋ねください。
新しい投稿を受信箱で受け取る
スパムはありません。いつでも購読を解除できます。