- Add common system directories to .dockerignore to prevent accidental inclusion
- Reorder Dockerfile instructions for better clarity and performance
- Remove remote deployment targets from Makefile to simplify local development workflow
- Use fully qualified image names for clarity
- Remove manual PHP extension installation as base image likely includes them
- Leverage COPY --chown to set permissions directly
- Remove redundant permission fix commands
- Keep same final command and exposed port
The base image is changed from the official php:8.4-fpm-alpine to thecodingmachine/php:8.4-v4-fpm-alpine to leverage additional pre-installed extensions, configurations, and utilities provided by the TheCodingMachine Docker images, which simplifies the setup for common PHP development and production environments.
- Replace manual apk install and docker-php-ext-install with mlocati/docker-php-extension-installer
- Combine system dependency installation and PHP extension setup into a single step
- Reorder steps for better clarity: copy files before permission fixes
- Maintain same PHP extensions and final permissions
- Use php:8.4-fpm-alpine for smaller image size
- Replace apt-get with apk package manager
- Use docker-php-ext-install instead of external extension installer
- Remove unnecessary comments and clean up cache appropriately
The docker-php-ext-install command can have permission issues on some
remote servers when extracting tarballs. Using mlocati/docker-php-extension-installer
provides a more reliable method for installing PHP extensions in Docker
containers.
The third-party extension installer (mlocati/docker-php-extension-installer) was causing tar permission issues on the remote server. Using the standard `docker-php-ext-install` method resolves this compatibility problem.
Add the --cleanup flag to the install-php-extensions command to remove downloaded archives after installation, reducing the final image size.
Use the --no-cache flag for the remote podman build in the deployment script to ensure a clean build from the latest source on the server.
Previously the image was built locally and pushed to a registry. Now we build directly on the remote server to simplify the deployment flow and avoid registry dependencies.
The deploy-server target was failing due to insufficient permissions on the remote server. Adding sudo ensures kubectl can apply the deployment configuration.
- Update default server user, IP, and deployment path to match current environment
- Redirect podman kube down output to /dev/null to reduce noise
- Use /tmp directory for temporary YAML files to avoid WSL permission issues
- Consolidate deployment steps to reduce password prompts during remote deployment
Generate a temporary merged YAML file locally before copying to the server. This reduces the number of SSH/SCP commands from multiple to two, minimizing password prompts and connection overhead.
The .env file is now expected to be present before running deploy commands. This simplifies the Makefile by removing conditional copy logic that was causing confusion about environment setup.
Add deploy-server target to deploy application to a remote Kubernetes cluster.
Includes server configuration variables and uses scp/ssh for file transfer and
kubectl commands for applying configuration and deployment.
The previous COPY instruction with --chown flag was not recursively setting permissions. Explicitly set directory and file permissions for the www-data user and remove unnecessary CI directories to reduce image size and potential security exposure.
- Remove stderr suppression from podman kube down to show potential errors
- Remove @ prefix from kubectl command to show execution in output
- Add comment clarifying the purpose of removing stderr redirection
- Update Dockerfile to use fully qualified composer image name
- Replace kubectl commands with podman kube play/down in Makefile
- Change from Kubernetes Secret to ConfigMap for environment variables
- Set imagePullPolicy to Never and use localhost/ prefix for local images
- Reduce replica count to 1 for local development
- Add stop target to Makefile for easier cleanup
Set working directory before copying files to avoid potential conflicts with host files. Also reorder Dockerfile steps for better logical flow and maintainability.
- Add .github and .circleci to .dockerignore to reduce image size
- Replace docker-php-ext-install with mlocati's extension installer for better reliability and maintenance
- Add comprehensive .dockerignore file to exclude unnecessary files
- Update Dockerfile to install required system dependencies and PHP extensions
- Set proper working directory and user permissions
- Use multi-stage build for Composer installation
- Replace Docker Compose setup with Kubernetes manifests for deployment
- Simplify Dockerfile to use PHP's built-in server instead of nginx+supervisor
- Add Makefile with build and deploy commands for local development
- Update environment configuration for production deployment
- Remove docker-specific configuration files (nginx.conf, supervisord.conf)
- Replace Laravel Sail docker-compose with a single-container Dockerfile
- Configure nginx and PHP-FPM via supervisor for production-like environment
- Include optimized PHP extensions and Redis support
- Simplify deployment by removing multi-service orchestration
The !important flag was previously used to override Tailwind's default styles, but it is no longer needed after recent framework updates. This change improves maintainability and follows CSS best practices by avoiding excessive specificity.
2026-02-19 03:18:00 +08:00
7 changed files with 172 additions and 67 deletions
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.