PHP Classes

File: .docker/Dockerfile

Recommend this page to a friend!
  Packages of WsdlToPhp   Package Base   .docker/Dockerfile   Download  
File: .docker/Dockerfile
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: Package Base
Base classes for implementing a package generator
Author: By
Last change: Refactor docker container to be able to run any PHP version from 7.4 (#56)

Thanks AI for 😄:
- update Dockerfile
- update docker-compose
- create Makefile

Update code with:
- CS Fixer
- Rector
Date: 4 days ago
Size: 1,210 bytes
 

Contents

Class file image Download
FROM debian:trixie-slim # Prevent interactive prompts ENV DEBIAN_FRONTEND=noninteractive # Install dependencies RUN apt-get update && apt-get install -y \ apt-transport-https \ ca-certificates \ curl \ git \ lsb-release \ unzip \ zip \ && curl -sSLo /usr/share/keyrings/deb.sury.org-php.gpg https://packages.sury.org/php/apt.gpg \ && echo "deb [signed-by=/usr/share/keyrings/deb.sury.org-php.gpg] https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list \ && apt-get update # Supported PHP Versions ENV PHP_VERSIONS="7.4 8.0 8.1 8.2 8.3 8.4 8.5" # Install all PHP versions using a loop RUN for ver in $PHP_VERSIONS; do \ apt-get install -y \ php${ver}-cli php${ver}-xml php${ver}-mbstring php${ver}-soap; \ done \ && apt-get clean && rm -rf /var/lib/apt/lists/* # Create symlinks (php-X.Y) using the same list RUN for ver in $PHP_VERSIONS; do \ ln -s /usr/bin/php${ver} /usr/bin/php-${ver}; \ done # Install Composer COPY --from=composer:latest /usr/bin/composer /usr/bin/composer # Set working directory WORKDIR /var/www # Copy project files COPY . /var/www/ # Default command CMD ["bash"]