CMSインストール · 5 min read · Nov 22, 2025
Ubuntu 22.04にNeos CMSをインストールする方法

Neos CMSは、コーディング知識なしでウェブサイトやブログを管理するのに役立つ無料のオープンソースで革新的なコンテンツ管理システムです。シンプルで安全で、使いやすさを考慮して設計されており、ビジネスオーナーが複数のデバイスでユーザーとコラボレーションするのを助けます。完全なUnicodeサポート、完全な国際化、SEO、インライン編集など、非常に便利な機能を提供します。このプロジェクトの核心的なアイデアは、編集者がコンテンツをできるだけシームレスに編集できるようにしながら、その構造を保持することです。
このチュートリアルでは、Ubuntu 22.04サーバーにApacheとLet’s Encrypt SSLを使用してNeos CMSをインストールする方法を示します。
前提条件
- Ubuntu 22.04を実行しているサーバー。
- サーバーIPにポイントされた有効なドメイン名。
- サーバーに設定されたrootパスワード。
始めに
まず、次のコマンドを実行して、すべてのシステムパッケージを最新バージョンに更新します:
apt update -y
apt upgrade -y完了したら、次のステップに進むことができます。
Apache、MariaDB、およびPHPのインストール
次に、Apache、MariaDB、PHP、およびその他の必要なパッケージをシステムにインストールする必要があります。次のコマンドを実行して、すべてをインストールします:
apt-get install apache2 mariadb-server php libapache2-mod-php php-common php-mysql php-gmp php-curl php-intl php-mbstring php-xmlrpc php-gd php-bcmath php-xml php-cli php-gmagick php-zip curl unzip git -yすべてのパッケージをインストールしたら、php.iniファイルを編集していくつかの変更を加えます:
nano /etc/php/8.1/apache2/php.ini次の行を変更します:
short_open_tag = On
memory_limit = 256M
upload_max_filesize = 150M
max_execution_time = 360
date.timezone = UTC
ファイルを保存して閉じたら、変更を適用するためにApacheサービスを再起動します:
systemctl restart apache2Neos CMS用のデータベースを作成
まず、MariaDBのrootパスワードを設定し、インストールを保護する必要があります。次のコマンドを使用して行うことができます:
mysql_secure_installation以下のようにすべての質問に答えます:
Enter current password for root (enter for none):
Set root password? [Y/n]: N
Remove anonymous users? [Y/n]: Y
Disallow root login remotely? [Y/n]: Y
Remove test database and access to it? [Y/n]: Y
Reload privilege tables now? [Y/n]: Y
完了したら、次のコマンドを使用してMariaDBにログインします:
mysql -u root -pログインしたら、次のコマンドを使用してNeos CMS用のデータベースとユーザーを作成します:
MariaDB [(none)]> CREATE DATABASE neosdb;
MariaDB [(none)]> CREATE USER 'neos'@'localhost' IDENTIFIED BY 'mypassword';次に、次のコマンドを使用してNeosデータベースにすべての権限を付与します:
MariaDB [(none)]> GRANT ALL PRIVILEGES ON neosdb.* TO 'neos'@'localhost' IDENTIFIED BY 'mypassword' WITH GRANT OPTION;次に、データベースの文字セットをutf8mb4に変更し、特権をフラッシュし、次のコマンドでMariaDBから退出します:
MariaDB [(none)]> ALTER DATABASE neosdb charset=utf8mb4;
MariaDB [(none)]> FLUSH PRIVILEGES;
MariaDB [(none)]> EXIT;次に、MariaDBの設定ファイルを編集していくつかの変更を加えます:
nano /etc/mysql/mariadb.conf.d/50-server.cnf次の行を追加します:
innodb_file_format = Barracuda
innodb_large_prefix = 1
innodb_file_per_table = 1
innodb_default_row_format = dynamic
ファイルを保存して閉じたら、変更を適用するためにMariaDBサービスを再起動します:
systemctl restart mariadb完了したら、次のステップに進むことができます。
Neos CMSのインストール
始める前に、システムにComposerをインストールする必要があります。Composerは、PHPの依存関係をインストールするために使用される依存関係マネージャーです。
次のコマンドを実行してComposerをインストールします:
curl -sS https://getcomposer.org/installer | php次の出力が得られるはずです:
All settings correct for using Composer
Downloading...
Composer (version 2.4.1) successfully installed to: /root/composer.phar
Use it: php composer.phar
次に、Composerファイルをシステムの場所に移動します:
mv composer.phar /usr/local/bin/composer次に、Apacheのウェブルートにディレクトリを変更し、次のコマンドでNeos CMSをダウンロードします:
cd /var/www/html/
git clone https://github.com/neos/neos-base-distribution.git次に、ダウンロードしたディレクトリの名前を変更し、composerコマンドを実行してすべてのPHP依存関係をインストールします:
mv neos-base-distribution neoscms
cd neoscms
composer install次に、Neosディレクトリに適切な権限と所有権を設定します:
chown -R www-data:www-data /var/www/html/neoscms/
chmod -R 755 /var/www/html/neoscms/完了したら、次のステップに進むことができます。
Neos CMSのためのApacheの設定
次に、Neos CMSをホストするためのApache仮想ホスト設定ファイルを作成する必要があります。次のコマンドで作成できます:
nano /etc/apache2/sites-available/neoscms.conf次の行を追加します:
ServerAdmin [email protected]
DocumentRoot /var/www/html/neoscms/Web
ServerName neos.example.com
Options FollowSymlinks
AllowOverride All
Require all granted
ErrorLog ${APACHE_LOG_DIR}/neos_error.log
CustomLog ${APACHE_LOG_DIR}/neos_access.log combined
RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*) index.php [PT,L]
ファイルを保存して閉じたら、次のコマンドで仮想ホストを有効にし、Apacheのリライトモジュールを有効にします:
a2ensite neoscms.conf
a2enmod rewrite次に、変更を適用するためにApacheサービスを再起動します:
systemctl restart apache2次のコマンドでApacheサービスのステータスを確認することもできます:
systemctl status apache2次の出力が得られるはずです:
? apache2.service - The Apache HTTP Server
Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor preset: enabled)
Active: active (running) since Sun 2022-09-04 08:07:38 UTC; 8s ago
Docs: https://httpd.apache.org/docs/2.4/
Process: 22571 ExecStart=/usr/sbin/apachectl start (code=exited, status=0/SUCCESS)
Main PID: 22577 (apache2)
Tasks: 6 (limit: 4579)
Memory: 14.7M
CPU: 128ms
CGroup: /system.slice/apache2.service
??22577 /usr/sbin/apache2 -k start
??22578 /usr/sbin/apache2 -k start
??22579 /usr/sbin/apache2 -k start
??22580 /usr/sbin/apache2 -k start
??22581 /usr/sbin/apache2 -k start
??22582 /usr/sbin/apache2 -k start
Sep 04 08:07:38 ubuntu2204 systemd[1]: Starting The Apache HTTP Server...
この時点で、ApacheウェブサーバーはNeos CMSを提供するように設定されています。次のステップに進むことができます。
Neos CMSにアクセス
今、ウェブブラウザを開いて、URL http://neos.example.com を使用してNeos CMSにアクセスします。次のページにリダイレクトされます:

セットアップに進むをクリックします。次のページが表示されるはずです:

SetupPassword.txtファイルからセットアップパスワードを入力し、ログインボタンをクリックします。次のページが表示されるはずです:

すべての必要なPHP拡張がインストールされていることを確認し、次へボタンをクリックします。次のページが表示されるはずです:

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

名前、管理者ユーザー名、パスワードを入力し、次へボタンをクリックします。次のページが表示されるはずです:


バックエンドに進むをクリックします。次に、Neos CMSのログインページが表示されるはずです:

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

Let’s EncryptでNeos CMSを保護
Let’s Encrypt Free SSLでウェブサイトを保護することは良いアイデアです。まず、SSLをインストールおよび管理するためにCertbotクライアントをインストールします。次のコマンドでインストールできます:
apt-get install python3-certbot-apache -yインストールが完了したら、次のコマンドを実行してLet’s Encrypt SSLでウェブサイトを保護します:
certbot --apache -d neos.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 neos.example.com
Enabled Apache rewrite module
Waiting for verification...
Cleaning up challenges
Created an SSL vhost at /etc/apache2/sites-available/neos-le-ssl.conf
Enabled Apache socache_shmcb module
Enabled Apache ssl module
Deploying Certificate to VirtualHost /etc/apache2/sites-available/neos-le-ssl.conf
Enabling available site: /etc/apache2/sites-available/neos-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/neos.conf to ssl vhost in /etc/apache2/sites-available/neos-le-ssl.conf
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Congratulations! You have successfully enabled https://neos.example.com
You should test your configuration at:
https://www.ssllabs.com/ssltest/analyze.html?d=neos.example.com
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
IMPORTANT NOTES:
- Congratulations! Your certificate and chain have been saved at:
/etc/letsencrypt/live/neos.example.com/fullchain.pem
Your key file has been saved at:
/etc/letsencrypt/live/neos.example.com/privkey.pem
Your cert will expire on 2022-12-07. 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
結論
おめでとうございます!Ubuntu 22.04サーバーにApacheとLet’s Encrypt SSLを使用してNeos CMSを正常にインストールしました。これで、ウェブブラウザを通じてウェブサイトを簡単に作成および編集できます。質問があればお気軽にお尋ねください。
新しい投稿を受信箱で受け取る
スパムはありません。いつでも購読を解除できます。