Skip to content

Creating a Self signed website build with pHp on Nginx container using Docker-Compose.

Notifications You must be signed in to change notification settings

amalbosemathew/self_signed_nginx_php_website

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PHP website on Nginx (Docker-compose)

Builds


Description

Creating a simple php website using Docker-compose. Website will be self-signed.


Features

  • Docker-compose is used for easy deploy.
  • You can upload your own php website in the website folder which is 'bind mounted' to the container.

Prerequisites

  • Need to have Docker installed in your machine.
  • Need to have Git installed in your machine.
  • Need to have Docker-compose installed in your machine.

Installation


How to clone this repository to your machine.

Steps:

yum install docker -y
yum install git -y
git clone https://github.com/amalbosemathew/self_signed_nginx_php_website
cd self_signed_nginx_php_website/

Screenshots

Cloning the repository from Github and installing docker-compose :

alt text


Uploading the php contents to the website folder.

Here you can upload your own code in the website directory. I have used to clone my php website code stored in the github repository

cd website/
git clone https://github.com/amalbosemathew/aws-elb-site ./

Creating docker container for PHP website with self-signed certificate.

Steps

docker-compose config <--------Check whether the configuration in yaml is correct.
docker-compose up -d <---------Creating the container in detach mode.(To reuse the same screen)
docker container ls -a <-------Listing all the container.
docker-compose down -v <--------To stop containers created using the docker-compose and to remove containers, volumes and networks.

Screenshots

alt text

alt text

Conclusion

The Intention of this Reposistory is to showcase the php website using Docker-compose.

About

Creating a Self signed website build with pHp on Nginx container using Docker-Compose.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published