teratail header banner
teratail header banner
質問するログイン新規登録

質問編集履歴

1

defoult.conf の内容を追記しました。

2020/07/14 00:35

投稿

Sento__aa
Sento__aa

スコア21

title CHANGED
File without changes
body CHANGED
@@ -54,7 +54,33 @@
54
54
 
55
55
  WORKDIR /var/www/html
56
56
  ```
57
+ **defoult.conf**
58
+ ```
59
+ server {
57
60
 
61
+ listen 80;
62
+ root /var/www/html/;
63
+ index index.php index.html index.htm;
64
+
65
+ access_log /var/log/nginx/access.log;
66
+ error_log /var/log/nginx/error.log;
67
+
68
+ location / {
69
+ try_files $uri $uri/ /index.php$is_args$args;
70
+ }
71
+
72
+ location ~ .php$ {
73
+ fastcgi_split_path_info ^(.+.php)(/.+)$;
74
+ fastcgi_pass app:9000;
75
+ fastcgi_index index.php;
76
+
77
+ include fastcgi_params;
78
+ fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
79
+ fastcgi_param PATH_INFO $fastcgi_path_info;
80
+ }
81
+ }
82
+ ```
83
+
58
84
  **コンテナ起動確認**
59
85
  ```CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
60
86
  d14940a5fd4e mysql:5.7 "docker-entrypoint.s…" 4 days ago Up 37 minutes 0.0.0.0:3306->3306/tcp, 33060/tcp workspace_mysql_1