Posted On March 31, 2019

LAMP Stack using Docker

kimconnect 0 comments
blog.KimConnect.com >> Codes , Virtualization >> LAMP Stack using Docker
# Install docker and compose
yum install docker docker-compose -y

# Add user into docker group
usermod -aG docker kimconnect

# Create test file and directory
mkdir -p /var/www/dockerized-lamp/
echo "<?php phpinfo(); ?>" > /var/www/dockerized-lamp/index.php

# Create yaml file
vim /var/www/dockerized-lamp/docker-compose.yml

# Content of yaml file
version: '3'
services:
php-apache:
image: php:7.2-cli
ports:
- 8081:80
volumes:
- ./:/var/www/html
links:
- 'mysql-server'

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post

VMware: How To Mount a USB Thumb Drive as a Data Store

Although USB is not a recommended data store type, it is still possible to mount…

PowerShell: Creating Scheduled Tasks on Remote Servers

This script is deprecated. Here is a better iteration. # scheduledTasksRemote_V0.0.2.ps1# Purpose: to add a…

Linux: How To Use Dig

Checking Name Server(s) kim@kim-linux:~$ dig @8.8.8.8 microsoft.com ; <<>> DiG 9.16.1-Ubuntu <<>> @8.8.8.8 microsoft.com ;…