/etc/yum.repos.d/ の下に nginx.repo という名前のファイルを作成します。vi /etc/yum.repos.d/nginx.repo
[nginx]name = nginx repobaseurl = https://nginx.org/packages/mainline/centos/7/$basearch/gpgcheck = 0enabled = 1
yum install -y nginx
default.confファイルを開きます。vim /etc/nginx/conf.d/default.conf
default.confファイルを編集します。server{...}を見つけて、 server 大括弧内の対応する設定情報を次の内容に置き換えます。 server {listen 80;root /usr/share/nginx/html;server_name localhost;#charset koi8-r;#access_log /var/log/nginx/log/host.access.log main;#location / {index index.php index.html index.htm;}#error_page 404 /404.html;#redirect server error pages to the static page /50x.html#error_page 500 502 503 504 /50x.html;location = /50x.html {root /usr/share/nginx/html;}#pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000#location ~ .php$ {fastcgi_pass 127.0.0.1:9000;fastcgi_index index.php;fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;include fastcgi_params;}}
systemctl start nginx
systemctl enable nginx
http://CVMインスタンスのパブリックIPアドレス

rpm -qa | grep -i mariadb

yum -y remove パッケージ名
/etc/yum.repos.d/ の下に MariaDB.repo ファイルを作成します。vi /etc/yum.repos.d/MariaDB.repo
mirrors.cloud.tencent.comをmirrors.tencentyun.comプライベートネットワークアドレスに置き換えることができます。プライベートネットワークのトラフィックは、パブリックトラフィックを占有せず、より高速になります。# MariaDB 10.4 CentOS repository list - created 2019-11-05 11:56 UTC# http://downloads.mariadb.org/mariadb/repositories/[mariadb]name = MariaDBbaseurl = https://mirrors.cloud.tencent.com/mariadb/yum/10.4/centos7-amd64gpgkey=https://mirrors.cloud.tencent.com/mariadb/yum/RPM-GPG-KEY-MariaDBgpgcheck=1
yum -y install MariaDB-client MariaDB-server
systemctl start mariadb
systemctl enable mariadb
mysql

\\q
rpm -Uvh https://mirrors.cloud.tencent.com/epel/epel-release-latest-7.noarch.rpm
rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
yum -y install mod_php72w.x86_64 php72w-cli.x86_64 php72w-common.x86_64 php72w-mysqlnd php72w-fpm.x86_64
systemctl start php-fpm
systemctl enable php-fpm
echo "<?php phpinfo(); ?>" >> /usr/share/nginx/html/index.php
systemctl restart nginx
http://CVMインスタンスのパブリックIPアドレス

フィードバック