Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit ceb532d

Browse files
author
Cai
committed
first commit
0 parents  commit ceb532d

File tree

7 files changed

+90
-0
lines changed

7 files changed

+90
-0
lines changed

Dockerfile

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
FROM labphp5
2+
3+
# Install app
4+
RUN rm -rf /var/www/*
5+
ADD src /var/www
6+
7+
# Configure apache
8+
ENV APACHE_RUN_USER www-data
9+
ENV APACHE_RUN_GROUP www-data
10+
ENV APACHE_LOG_DIR /var/log/apache2
11+
12+
EXPOSE 80
13+
14+
CMD ["/usr/sbin/apache2", "-D", "FOREGROUND"]

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Amazon ECS PHP Demo App

src/assets/css/bootstrap-responsive.min.css

Lines changed: 9 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/assets/css/bootstrap.min.css

Lines changed: 9 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/assets/js/bootstrap.min.js

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/index.php

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
4+
<head>
5+
<meta charset="utf-8">
6+
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
7+
<title>ECS Demo Website</title>
8+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
9+
<link href="assets/css/bootstrap.min.css" rel="stylesheet">
10+
<style>body {margin-top: 40px; background-color: #333;}</style>
11+
<link href="assets/css/bootstrap-responsive.min.css" rel="stylesheet">
12+
<!--[if lt IE 9]><script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
13+
</head>
14+
15+
<body>
16+
<div class="container">
17+
<div class="hero-unit">
18+
<h1>ECS Demo Website</h1>
19+
<p>Your website is now running on a container in Amazon ECS</p>
20+
<p>The container hostname is <?php echo gethostname(); ?>.</p>
21+
</div>
22+
</div>
23+
24+
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"></script>
25+
<script src="assets/js/bootstrap.min.js"></script>
26+
</body>
27+
28+
</html>

taskdef.json

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"family": "ecslabphp",
3+
"containerDefinitions": [
4+
{
5+
"name": "ecslabphp",
6+
"image": "%REPOSITORY_URI%:v_%BUILD_NUMBER%",
7+
"cpu": 10,
8+
"memory": 256,
9+
"portMappings": [
10+
{
11+
"containerPort": 80,
12+
"hostPort": 0
13+
}
14+
],
15+
"entryPoint": [
16+
"/usr/sbin/apache2",
17+
"-D",
18+
"FOREGROUND"
19+
],
20+
"essential": true
21+
}
22+
]
23+
}

0 commit comments

Comments
 (0)