Sign inSign up

bilal1130/php

By bilal1130

•Updated over 1 year ago

A Docker image featuring Ubuntu with Apache2, PHP, and Composer pre-installed.

Image
Languages & frameworks
0

125

bilal1130/php repository overview

Here’s an overview for your Docker repository:


⁠Docker Repository: Ubuntu with Apache2, PHP, and Composer
⁠Description

This Docker image is built on Ubuntu and comes pre-installed with:

  • Apache2: A widely used open-source web server.
  • PHP: The scripting language commonly used for web development.
  • Composer: A dependency manager for PHP to manage libraries and packages.

The image is designed to streamline development for PHP applications, offering a ready-to-use environment with essential tools pre-configured.


⁠Features
  • Base Image: Ubuntu (latest stable version).
  • Apache2: Configured to serve PHP applications.
  • PHP: Includes essential extensions commonly required for modern PHP projects.
  • Composer: Pre-installed for managing dependencies.
  • Lightweight and customizable.

⁠Usage

Pull the image from Docker Hub:

docker pull <repository-name>:<tag>

Run a container:

docker run -d -p 80:80 <repository-name>:<tag>

⁠Volumes

To persist data or serve your application:

docker run -d -p 80:80 -v /path/to/app:/var/www/html <repository-name>:<tag>

⁠Environment Variables
  • APACHE_DOCUMENT_ROOT: Customize the document root for Apache (default: /var/www/html).
  • PHP_MEMORY_LIMIT: Configure PHP memory limit (default: 128M).

Example:

docker run -d -p 80:80 -e PHP_MEMORY_LIMIT=256M <repository-name>:<tag>

⁠Customizing the Image

Use the image as a base for your project:

FROM <repository-name>:<tag>

# Add your custom configurations or dependencies
COPY ./my-app /var/www/html
RUN composer install

Build your custom image:

docker build -t my-custom-php-image .

⁠Exposed Ports
  • 80: Default HTTP port for Apache2.

⁠Tags
  • php:v7.1: Specific version with PHP 7.1.

⁠Contributions

Feel free to open issues or submit pull requests to improve the image or add new features.


Let me know if you'd like help with more detailed instructions or creating a Dockerfile for this repository.

Tag summary

Content type

Image

Digest

sha256:4a5b5caf4…

Size

190.8 MB

Last updated

over 1 year ago

docker pull bilal1130/php:v8.3