PHP 8.1 Apache image forked from official php:8.1-apache-bookworm
72
Optimized PHP 8.1 with Apache image based on Debian Bookworm, designed for production environments with minimal footprint.
# Pull the image
docker pull ltanh1194/deepworks-php-apache:8.1
# Run a container
docker run -d -p 8080:80 -v /path/to/your/app:/var/www/html --name my-php-app ltanh1194/deepworks-php-apache:8.1
version: '3'
services:
php-apache:
image: ltanh1194/deepworks-php-apache:8.1
container_name: my-php-app
ports:
- "8080:80"
volumes:
- ./app:/var/www/html
# Optional: Mount custom configurations
- ./config/php/custom-php.ini:/usr/local/etc/php/conf.d/custom-php.ini
- ./config/apache/000-default.conf:/etc/apache2/sites-available/000-default.conf
restart: unless-stopped
This image allows for easy customization through volume mounts:
/usr/local/etc/php/conf.d/custom-php.ini/etc/apache2/sites-available/000-default.confOnce the container is running, you can access your web application at:
http://localhost:8080
This image supports both ARM64 (Apple Silicon) and AMD64 (Intel/Linux) architectures. To build for both platforms:
# Make the build script executable
chmod +x build-multiplatform.sh
# Run the build script
./build-multiplatform.sh
Alternatively, you can build manually with Docker Buildx:
# Create and use a buildx builder
docker buildx create --name multiplatform-builder --use
# Build for both platforms
docker buildx build --platform linux/amd64,linux/arm64 --tag custom-php-apache:8.1-general --load .
MIT
Content type
Image
Digest
sha256:dcedc0824…
Size
184.6 MB
Last updated
12 months ago
docker pull ltanh1194/deepworks-php-apache:1.0