Ghost(ブログプラットフォーム)を実行しているNginx Webサーバーに大量のhtmlファイルと画像ファイルをアップロードしようとしていますghost-blog.com
. ghost-blog.com/text.html
ゴーストは完全に正常に動作しますが、さらに、同じドメインの下にある他のファイルとフォルダーを提供したいghost-blog.com/subfolder/index.html
.
グーグルで答えを探すのに時間を費やした後、何か「新しい」ものに出くわしたようです。ファイルに変更を加える必要があることは承知してい/etc/nginx/sites-available/default
ます。私が知らないのは、何を追加/編集すればよいかです
/some/random/public
フォルダー publicを作成しますindex index.html index.htm
これは、コンテンツ、特にデフォルトファイルを既に提供している Ghost と競合しません。
現在の/etc/nginx/sites-available/default
構成ファイルは次のようになります。
server {
listen 80;
server_name www.ghost-blog.com;
rewrite ^/(.*) http://ghost-blog.com/$1 permanent;
}
server {
root /usr/share/nginx/www;
index index.html index.htm;
server_name localhost;
location / {
try_files $uri $uri/ /index.html;
}
location /doc/ {
alias /usr/share/doc/;
autoindex on;
allow 127.0.0.1;
deny all;
}
}
/public
他のファイルやサブフォルダーを提供するフォルダーを作成する方法について何か提案はありますか?