Skip to content

Commit d6c9bc6

Browse files
unknownunknown
unknown
authored and
unknown
committedMar 23, 2015
Initial commit
1 parent 73cd81f commit d6c9bc6

File tree

4 files changed

+90
-0
lines changed

4 files changed

+90
-0
lines changed
 

Diff for: ‎Dockerrun.aws.json

+63
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
{
2+
"AWSEBDockerrunVersion": 2,
3+
"volumes": [
4+
{
5+
"name": "php-app",
6+
"host": {
7+
"sourcePath": "/var/app/current/php-app"
8+
}
9+
},
10+
{
11+
"name": "nginx-proxy-conf",
12+
"host": {
13+
"sourcePath": "/var/app/current/proxy/conf.d"
14+
}
15+
}
16+
],
17+
"containerDefinitions": [
18+
{
19+
"name": "php-app",
20+
"image": "php:fpm",
21+
"essential": true,
22+
"memory": 128,
23+
"mountPoints": [
24+
{
25+
"sourceVolume": "php-app",
26+
"containerPath": "/var/www/html",
27+
"readOnly": true
28+
}
29+
]
30+
},
31+
{
32+
"name": "nginx-proxy",
33+
"image": "nginx",
34+
"essential": true,
35+
"memory": 128,
36+
"portMappings": [
37+
{
38+
"hostPort": 80,
39+
"containerPort": 80
40+
}
41+
],
42+
"links": [
43+
"php-app"
44+
],
45+
"mountPoints": [
46+
{
47+
"sourceVolume": "php-app",
48+
"containerPath": "/var/www/html",
49+
"readOnly": true
50+
},
51+
{
52+
"sourceVolume": "awseb-logs-nginx-proxy",
53+
"containerPath": "/var/log/nginx"
54+
},
55+
{
56+
"sourceVolume": "nginx-proxy-conf",
57+
"containerPath": "/etc/nginx/conf.d",
58+
"readOnly": true
59+
}
60+
]
61+
}
62+
]
63+
}

Diff for: ‎php-app/index.php

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<h1>Hello World!!!</h1>
2+
<h3>PHP Version <?= phpversion() ?></h3>
3+
<a href="/static.html">Static HTML Page</a>

Diff for: ‎php-app/static.html

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
<h1>This is a static HTML page</h1>
2+
<a href="/">Go Back</a>

Diff for: ‎proxy/conf.d/default.conf

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
server {
2+
listen 80;
3+
server_name localhost;
4+
root /var/www/html;
5+
6+
index index.php;
7+
8+
location ~ [^/]\.php(/|$) {
9+
fastcgi_split_path_info ^(.+?\.php)(/.*)$;
10+
if (!-f $document_root$fastcgi_script_name) {
11+
return 404;
12+
}
13+
14+
include fastcgi_params;
15+
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
16+
fastcgi_param PATH_INFO $fastcgi_path_info;
17+
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
18+
19+
fastcgi_pass php-app:9000;
20+
fastcgi_index index.php;
21+
}
22+
}

0 commit comments

Comments
 (0)