From 20ecec1d9668088200d3ef1cc9b80186935ccde2 Mon Sep 17 00:00:00 2001 From: Jay Rogers Date: Mon, 5 Feb 2024 13:22:46 -0600 Subject: [PATCH] Release/v3.0 (#207) * Improved query accuracy * Removed sort * Removed version data * Changed docker repo * Restructured docker repository name * Moved readme control to beta for now * Improved error handling * Removed unset check * Added dev script * Removed copy command * Fixed merging of YML * Disabled debugging * Fixed merge * Remove debug * Improved dependency install * Fixed structure of dev command * Improved documentation * Initial commit of S6 * Initial commit of other variations * Added early exits * Fixed separation of commands * Added init script * Removed whitespace * Sort scripts to run by numerical order * Fixed execution of commands * Improved development script * Removed debug * WIP migrated FPM and NGINX over * Removed wget dependency * Fixed reference to php-fpm * Changed shells * Fixed dependency installer * WIP - adding nginx * Converted logic to shell * Added trace * Working NGINX * Working NGINX-FPM * Working Alpine support * Functioning Alpine image * Added special thanks * Cleaned up error output * Removed whitespace * Fixed error reference * Remove unnecessary code * WIP Nginx Unit * Set script name * Renamed nginx-unit to unit * Fixed base image reference * Improved error output * Working NGINX Unit with SSL-Off * Cleaned up output * Explicit script names * Added debug * WIP Unit Mixed * Renamed SSL to self-signed * Working SSL configuration * Changed to serversideup/php * Changed docker-php-pro to docker-php-serversideup * Fixed illegal character error * Added minimum TLS * Updated ciphers * Working NGINX Unit configuration * Changed name reference * Changed branch name for beta * Added usage notes * Refactored tag script * Renamed base config file * Renamed base config * Moved RC and added usage instructions * Removed whitespace * Removed whitespace * Require base config * Clarified defaults * Renamed DEPENDENCY_PACKAGES_BOOKWORM to DEPENDENCY_PACKAGES_DEBIAN * Refactored and improved readability * Added base operating systems * Updated php-version.yml structure * Added base os for RC * Refactored assemble-docker-tags * Adjusted Base OS Logic * Fixed variable name * Variable name change * Pretty print * Changed permissions * Added help menu * Fixed help menu * Remove help tag * Added fpm configs * Added default variables * Organized and renamed variables for better clarity * Remove PHP open base dir * Fixed permissions on configs * Moved PHP_SESSION_COOKIE_SECURE to ini. Fixes #105. Ref #107 * Moved init scripts to be at a higher number * Added PHP_ERROR_LOG * Changed order of execution for debug * Changed debug output order * Removed default base os * Prepared for push of images * Default to any debian os * Updated landing page * Updated readme * Improved NGINX Unit description * Updated features * Improved output * Added newer versions * Added build process * Removed fpm-apache for now * Updated NGINX Unit version to 1.31.1 * Added variations from config file * Fixed tagging issues for default_base_os * Added comment for why we can't include an alpine version of Unit * Ignore DS_Store files * Added PHP extensions * Removed whitespace * Commented out sqllit * Specified branch due to https://github.com/cloudflare/pages-action/issues/97 * Update s6-overlay version to v3.1.6.2 * Updated comparison and moved S6 overlay to its own page * Added APP_BASE_DIR * Clarified release notes location * Started migration guide * Removed whitespace * Update migration guide with v3 changes * Updated Laravel automations * Fixed heading reference * Add branch parameter to Cloudflare deployment * Cleaned up GitHub Action names * Added skip-download option * Temporarily set skip download * Add expanded Laravel automations * Clarified output * Fix autorun Laravel migration to true * Update PHP Docker Images and Add New Features * Clarified comment * Enabled downloads again * Add PHP 8.3 with Alpine and Bookworm support * Default to 8.3 * Added debug mode * Moved debug mode to entrypoint * Update Dockerfile and entrypoint scripts * Added labels and ability to set repo versions * Adjusted argument order * Update environment variable specification * Update REPOSITORY_BUILD_VERSION to include GIT Short SHA and GitHub Run ID * Update Dockerfile comments for CLI and FPM variations * Update PHP Docker Images description * Add explanation for "Optimized for Laravel & WordPress" in getting started guide * Simplified checkout process * Added ability to push to GHCR * Add multi-arch support and published registry URLs * Remove Discourse link * Updated installation instructions * Update upgrade guide with version selection details * Add links to view available images and tags * Update installation.md with information about selecting the version of PHP * Update link to guide on selecting the right image * Updated contribution guide * Update docker-compose.yml to include .dockerignore file * Add composer support * Set S6 Overlay version in variable instead of file * Update project credits and special thanks * Update title in marketing layout * Adjusted default PHP extensions * Added $build_major_version-$build_base_os tag * Add default entrypoint scripts and disable default configuration * Fix typo in default configurations * Add guide for migrating from official PHP Docker images * Fix missing image tag and add link to installation guide * Update PHP image migration guide * Add default environment variable specification * Add guide on changing common PHP settings * Remove customizing the image guide * Add migration guide from v2 to v3 * Update Docker Compose and add Dockerfile for installing additional PHP extensions * Fix image tag not found issue in older versions of PHP * Add instructions for rebuilding Docker image on Docker Compose initialization * Add install-php-extensions support * Refactor Docker tag generation logic * WIP of SSL and start up scripts * Docs Upgrade (#245) * Upgraded to Nuxt 3.8 * Added about images and content ref #238 * Updated to H1 Title * Removed methods for SEO data * Added OG Image template * Cleaned up SEO * Fixed undefined page variable * Added sign up form * Added nvm * Add Node.js setup and update build process * Update link to customizations guide * Update environment name in marketing site preview workflow * Updated to base 64 * Update environment name in action_marketing-site-publish.yml * Add BASE_PATH to .env.example * Add SSL configuration options * Update SSL configuration options * Update ogImage and twitterImage URLs in marketing layout * Allow for nuxt base url to be null * Adjusted w and h of image --------- Co-authored-by: Jay Rogers * Update SSL configuration * Updated logo * Update PHP patch versions * Fixed code highlights * Update SSL configuration and provide examples for self-signed and custom certificates * Add note about php.ini in changing-common-php-settings.md * Update Dockerfile versions and install additional PHP extensions * Add guide for adding custom startup scripts * Organized variables better * Update migration guide with v3 changes * Update PHP installation instructions and remove deprecated features * Removed arrow for compatibility reasons * Update link to discussion * Update PHP Docker Images with improved customization * Added PHP 8.3 support * Update description in index.md file * Update description of serversideup/php Docker images * Update PHP Docker Images name * Changed to PNG image * Update ogImageHeight in marketing layout * Update ogDescription and twitterDescription in marketing layout * Update social image file type * Update social image * Adjusted OG image template * Adjusted borders * Update border and rounded styles in OgImage component * Update command reference in PHP Docker image * Updated favicon Url ref #251 * Add PHP_OPEN_BASEDIR environment variable to Dockerfiles. Fixes #258 * Add port exposure for HTTP and HTTPS. Fixes #260 * Add PHP_MAX_INPUT_TIME environment variable. Fixes #257 * Added ZIP to Debian images. Fixes #261 * Add WORKDIR instruction. Fixes #263 * Update environment names for marketing site workflows * Test CI * CI test 2 * Revert environment names * Cleaned up environment names * CI test 1 * Remove testing * Update PHP_EXT_INSTALLER_VERSION to 2.1.71 * Update PHP_EXT_INSTALLER_VERSION to 2.1.73 * Update Docker actions to latest versions * Add prefix option for Docker image tag * Add composer cache directory creation and ownership * Added docker-php-serversideup-set-id script * Removed --chown flag. Fixes #265 * Added video embed component * Added Book & updated header * Fix typo * Fixed code execution * Improved s6-init build process * Added Dockerfile support * Added S6 overlay script customization * Add book recommendation for building multi-platform browser extensions * Update menu link to Bugflow and change "Books" to "Products" * Added automated checks to ensure database connection is alive before running migrations * Added AUTORUN_LARAVEL_MIGRATION_TIMEOUT. Default timeout of 30 seconds * Update PHP_EXT_INSTALLER_VERSION to 2.1.76 * Improved test connection to database. Fixes #279 * Upgraded to actions/checkout@v4 * Prepare for merge * Update PHP patch versions in base config --------- Co-authored-by: Dan Pastori --- .dockerignore | 1 + .../action_marketing-site-preview.yml | 14 + .../action_marketing-site-publish.yml | 14 + .../workflows/action_publish-beta-images.yml | 20 + .../action_publish-production-images.yml | 16 + .../publish_docker-images-production.yml | 65 - .../scheduled-task_update-sponsors.yml | 2 +- .../workflows/service_deploy-static-site.yml | 48 + .../service_docker-build-and-publish.yml | 150 +- .github/workflows/site_deploy-static-site.yml | 43 - .github/workflows/site_preview-setup.yml | 40 - .gitignore | 4 +- README.md | 20 +- dev.sh | 80 - docs/.env.example | 2 + docs/.nvmrc | 1 + docs/components/Global/OgImage/DocsImage.vue | 35 + docs/components/Global/ServerSideUp.vue | 59 +- docs/components/content/About.vue | 26 + docs/components/content/CodeGroup.vue | 2 +- docs/components/content/CodePanel.vue | 4 +- docs/components/content/Features.vue | 22 +- docs/components/content/LandingSignup.vue | 41 + docs/components/content/MarketingGrid.vue | 24 +- docs/components/content/MarketingHeader.vue | 6 +- docs/components/content/MarketingHero.vue | 4 +- docs/components/content/VideoEmbed.vue | 21 + docs/content/docs/1.index.md | 6 +- .../1.these-images-vs-others.md | 106 +- .../docs/2.getting-started/2.installation.md | 83 +- .../3.default-configurations.md | 66 + .../docs/2.getting-started/3.upgrade-guide.md | 63 +- .../docs/2.getting-started/5.changelog.md | 4 +- .../content/docs/2.getting-started/6.about.md | 48 +- .../docs/2.getting-started/7.contributing.md | 75 +- .../3.guide/1.choosing-the-right-image.md | 43 - .../1.migrating-from-official-php-images.md | 28 + .../3.guide/2.changing-common-php-settings.md | 58 + .../docs/3.guide/2.customizing-the-image.md | 145 - .../3.installing-additional-php-extensions.md | 121 + .../4.adding-your-own-start-up-scripts.md | 157 + .../content/docs/3.guide/5.configuring-ssl.md | 101 + .../docs/3.guide/6.using-s6-overlay.md | 96 + .../docs/3.guide/7.migrating-from-v2-to-v3.md | 57 + .../4.laravel/2.laravel-task-scheduler.md | 4 +- .../content/docs/4.laravel/3.laravel-queue.md | 4 +- .../docs/4.laravel/4.laravel-horizon.md | 4 +- .../1.environment-variable-specification.md | 83 +- .../docs/6.reference/2.command-reference.md | 14 + docs/content/index.md | 3 + docs/layouts/docs.vue | 40 +- docs/layouts/marketing.vue | 27 +- docs/nuxt.config.ts | 24 +- docs/package.json | 16 +- .../public/images/icons/cloudflare-square.svg | 6 + docs/public/images/icons/php-square.svg | 7 + docs/public/images/icons/ubuntu-square.svg | 5 - docs/public/images/logos/og-logo.png | Bin 0 -> 5098 bytes docs/public/images/logos/og-ssu-logo.png | Bin 0 -> 3732 bytes docs/public/images/logos/php-docker-logo.svg | 21 +- docs/public/images/logos/x-logo.svg | 3 + docs/public/images/social-image.jpg | Bin 66528 -> 229668 bytes docs/yarn.lock | 8857 +++++++++++------ scripts/assemble-docker-tags.sh | 317 + scripts/conf/php-versions-base-config.yml | 52 + scripts/dev.sh | 150 + scripts/get-php-versions.sh | 144 + src/cli/Dockerfile | 69 - src/cli/README.md | 3 - .../etc/s6-overlay/s6-rc.d/runas-user/type | 1 - src/cli/etc/s6-overlay/s6-rc.d/runas-user/up | 1 - .../s6-rc.d/user/contents.d/runas-user | 0 src/cli/etc/s6-overlay/scripts/runas-user | 43 - src/cli/php-version-packages/7.4.txt | 14 - src/cli/php-version-packages/8.0.txt | 13 - src/cli/php-version-packages/8.1.txt | 13 - src/cli/php-version-packages/8.2.txt | 13 - .../etc/entrypoint.d/0-container-info.sh | 31 + src/common/etc/entrypoint.d/1-debug-mode.sh | 30 + .../entrypoint.d/50-laravel-automations.sh | 112 + ...docker-php-serversideup-dep-install-alpine | 46 + ...docker-php-serversideup-dep-install-debian | 48 + .../bin/docker-php-serversideup-entrypoint | 38 + ...php-serversideup-install-php-ext-installer | 27 + .../local/bin/docker-php-serversideup-set-id | 58 + src/common/usr/local/etc/php/php.ini | 1975 ++++ src/fpm-apache/Dockerfile | 78 - src/fpm-apache/README.md | 5 - .../etc/apache2/conf-available/remoteip.conf | 26 - .../etc/apache2/conf-available/security.conf | 103 - .../etc/apache2/mods-available/mpm_event.conf | 18 - .../etc/apache2/sites-available/ssl-full.conf | 23 - .../apache2/sites-available/ssl-mixed.conf | 7 - .../etc/apache2/sites-available/ssl-off.conf | 3 - .../etc/apache2/vhost-templates/http.conf | 40 - .../etc/apache2/vhost-templates/https.conf | 48 - .../php/fpm/pool.d/z-fpm-with-overrides.conf | 6 - .../etc/s6-overlay/s6-rc.d/apache2/data/check | 10 - .../s6-overlay/s6-rc.d/apache2/dependencies | 3 - .../etc/s6-overlay/s6-rc.d/apache2/run | 6 - .../s6-rc.d/configure-ssl/dependencies | 1 - .../etc/s6-overlay/s6-rc.d/configure-ssl/type | 1 - .../etc/s6-overlay/s6-rc.d/configure-ssl/up | 1 - .../s6-rc.d/debug-apache2/dependencies | 1 - .../etc/s6-overlay/s6-rc.d/debug-apache2/type | 1 - .../etc/s6-overlay/s6-rc.d/debug-apache2/up | 1 - .../etc/s6-overlay/s6-rc.d/msmtp/type | 1 - .../etc/s6-overlay/s6-rc.d/msmtp/up | 1 - .../s6-rc.d/user/contents.d/apache2 | 0 .../s6-rc.d/user/contents.d/configure-ssl | 0 .../s6-rc.d/user/contents.d/debug-apache2 | 0 .../s6-overlay/s6-rc.d/user/contents.d/msmtp | 0 .../etc/s6-overlay/scripts/configure-ssl | 34 - .../etc/s6-overlay/scripts/debug-apache2 | 13 - src/fpm-apache/etc/s6-overlay/scripts/msmtp | 13 - src/fpm-nginx/Dockerfile | 44 - src/fpm-nginx/README.md | 5 - src/fpm-nginx/etc/nginx/nginx.conf | 56 - .../php/fpm/pool.d/z-fpm-with-overrides.conf | 6 - .../s6-rc.d/configure-ssl/dependencies | 1 - .../etc/s6-overlay/s6-rc.d/configure-ssl/type | 1 - .../etc/s6-overlay/s6-rc.d/configure-ssl/up | 1 - .../s6-rc.d/debug-nginx/dependencies | 1 - .../etc/s6-overlay/s6-rc.d/debug-nginx/type | 1 - .../etc/s6-overlay/s6-rc.d/debug-nginx/up | 1 - .../etc/s6-overlay/s6-rc.d/msmtp/type | 1 - src/fpm-nginx/etc/s6-overlay/s6-rc.d/msmtp/up | 1 - .../etc/s6-overlay/s6-rc.d/nginx/dependencies | 3 - .../s6-rc.d/user/contents.d/configure-ssl | 0 .../s6-rc.d/user/contents.d/debug-nginx | 0 .../s6-overlay/s6-rc.d/user/contents.d/msmtp | 0 .../etc/s6-overlay/scripts/configure-ssl | 34 - .../etc/s6-overlay/scripts/debug-nginx | 13 - src/fpm-nginx/etc/s6-overlay/scripts/msmtp | 13 - src/fpm/Dockerfile | 50 - src/fpm/README.md | 3 - .../s6-rc.d/laravel-automations/dependencies | 1 - .../s6-rc.d/laravel-automations/type | 1 - .../s6-overlay/s6-rc.d/laravel-automations/up | 1 - .../etc/s6-overlay/s6-rc.d/php-fpm/data/check | 2 - .../s6-overlay/s6-rc.d/php-fpm/dependencies | 2 - .../s6-rc.d/php-fpm/notification-fd | 1 - src/fpm/etc/s6-overlay/s6-rc.d/php-fpm/type | 1 - .../user/contents.d/laravel-automations | 0 .../s6-overlay/scripts/laravel-automations | 33 - .../docker-php-serversideup-pool.conf} | 118 +- .../entrypoint.d/10-init-webserver-config.sh | 127 + .../etc/s6-overlay/s6-rc.d/php-fpm/data/check | 2 + .../s6-overlay/s6-rc.d/php-fpm/dependencies | 1 + .../s6-rc.d/php-fpm}/notification-fd | 0 .../etc/s6-overlay/s6-rc.d/php-fpm/run | 2 +- .../etc/s6-overlay/s6-rc.d/php-fpm}/type | 0 .../s6-rc.d/user/contents.d/php-fpm | 0 .../local/bin/docker-php-serversideup-s6-init | 57 + .../bin/docker-php-serversideup-s6-install | 38 + src/variations/cli/Dockerfile | 64 + src/variations/fpm-nginx/Dockerfile | 162 + .../fpm-nginx/etc/nginx/nginx.conf.template | 33 + .../etc/nginx/server-opts.d/performance.conf | 0 .../etc/nginx/server-opts.d/remoteip.conf | 0 .../etc/nginx/server-opts.d/security.conf | 0 .../etc/nginx/site-opts.d/http.conf.template} | 8 +- .../nginx/site-opts.d/https.conf.template} | 15 +- .../etc/nginx/sites-available/ssl-full | 0 .../etc/nginx/sites-available/ssl-mixed | 0 .../etc/nginx/sites-available/ssl-off | 0 .../etc/s6-overlay/s6-rc.d/nginx/data/check | 4 +- .../etc/s6-overlay/s6-rc.d/nginx/dependencies | 1 + .../s6-overlay/s6-rc.d/nginx/notification-fd | 0 .../etc/s6-overlay/s6-rc.d/nginx/run | 0 .../etc/s6-overlay/s6-rc.d/nginx/type | 0 .../s6-overlay/s6-rc.d/user/contents.d/nginx | 0 src/variations/fpm/Dockerfile | 80 + src/variations/unit/Dockerfile | 144 + .../unit/etc/entrypoint.d/10-init-unit.sh | 194 + .../etc/unit/config.d/ssl-full.json.template | 106 + .../etc/unit/config.d/ssl-mixed.json.template | 94 + .../etc/unit/config.d/ssl-off.json.template | 57 + 178 files changed, 11412 insertions(+), 4953 deletions(-) create mode 100644 .dockerignore create mode 100644 .github/workflows/action_marketing-site-preview.yml create mode 100644 .github/workflows/action_marketing-site-publish.yml create mode 100644 .github/workflows/action_publish-beta-images.yml create mode 100644 .github/workflows/action_publish-production-images.yml delete mode 100644 .github/workflows/publish_docker-images-production.yml create mode 100644 .github/workflows/service_deploy-static-site.yml delete mode 100644 .github/workflows/site_deploy-static-site.yml delete mode 100644 .github/workflows/site_preview-setup.yml delete mode 100755 dev.sh create mode 100644 docs/.nvmrc create mode 100644 docs/components/Global/OgImage/DocsImage.vue create mode 100644 docs/components/content/About.vue create mode 100644 docs/components/content/LandingSignup.vue create mode 100644 docs/components/content/VideoEmbed.vue create mode 100644 docs/content/docs/2.getting-started/3.default-configurations.md delete mode 100644 docs/content/docs/3.guide/1.choosing-the-right-image.md create mode 100644 docs/content/docs/3.guide/1.migrating-from-official-php-images.md create mode 100644 docs/content/docs/3.guide/2.changing-common-php-settings.md delete mode 100644 docs/content/docs/3.guide/2.customizing-the-image.md create mode 100644 docs/content/docs/3.guide/3.installing-additional-php-extensions.md create mode 100644 docs/content/docs/3.guide/4.adding-your-own-start-up-scripts.md create mode 100644 docs/content/docs/3.guide/5.configuring-ssl.md create mode 100644 docs/content/docs/3.guide/6.using-s6-overlay.md create mode 100644 docs/content/docs/3.guide/7.migrating-from-v2-to-v3.md create mode 100644 docs/content/docs/6.reference/2.command-reference.md create mode 100644 docs/public/images/icons/cloudflare-square.svg create mode 100644 docs/public/images/icons/php-square.svg delete mode 100644 docs/public/images/icons/ubuntu-square.svg create mode 100644 docs/public/images/logos/og-logo.png create mode 100644 docs/public/images/logos/og-ssu-logo.png create mode 100644 docs/public/images/logos/x-logo.svg create mode 100755 scripts/assemble-docker-tags.sh create mode 100644 scripts/conf/php-versions-base-config.yml create mode 100755 scripts/dev.sh create mode 100755 scripts/get-php-versions.sh delete mode 100644 src/cli/Dockerfile delete mode 100644 src/cli/README.md delete mode 100644 src/cli/etc/s6-overlay/s6-rc.d/runas-user/type delete mode 100644 src/cli/etc/s6-overlay/s6-rc.d/runas-user/up delete mode 100644 src/cli/etc/s6-overlay/s6-rc.d/user/contents.d/runas-user delete mode 100644 src/cli/etc/s6-overlay/scripts/runas-user delete mode 100644 src/cli/php-version-packages/7.4.txt delete mode 100644 src/cli/php-version-packages/8.0.txt delete mode 100644 src/cli/php-version-packages/8.1.txt delete mode 100644 src/cli/php-version-packages/8.2.txt create mode 100644 src/common/etc/entrypoint.d/0-container-info.sh create mode 100644 src/common/etc/entrypoint.d/1-debug-mode.sh create mode 100644 src/common/etc/entrypoint.d/50-laravel-automations.sh create mode 100644 src/common/usr/local/bin/docker-php-serversideup-dep-install-alpine create mode 100644 src/common/usr/local/bin/docker-php-serversideup-dep-install-debian create mode 100644 src/common/usr/local/bin/docker-php-serversideup-entrypoint create mode 100644 src/common/usr/local/bin/docker-php-serversideup-install-php-ext-installer create mode 100644 src/common/usr/local/bin/docker-php-serversideup-set-id create mode 100644 src/common/usr/local/etc/php/php.ini delete mode 100644 src/fpm-apache/Dockerfile delete mode 100644 src/fpm-apache/README.md delete mode 100644 src/fpm-apache/etc/apache2/conf-available/remoteip.conf delete mode 100644 src/fpm-apache/etc/apache2/conf-available/security.conf delete mode 100644 src/fpm-apache/etc/apache2/mods-available/mpm_event.conf delete mode 100644 src/fpm-apache/etc/apache2/sites-available/ssl-full.conf delete mode 100644 src/fpm-apache/etc/apache2/sites-available/ssl-mixed.conf delete mode 100644 src/fpm-apache/etc/apache2/sites-available/ssl-off.conf delete mode 100644 src/fpm-apache/etc/apache2/vhost-templates/http.conf delete mode 100644 src/fpm-apache/etc/apache2/vhost-templates/https.conf delete mode 100644 src/fpm-apache/etc/php/fpm/pool.d/z-fpm-with-overrides.conf delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/apache2/data/check delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/apache2/dependencies delete mode 100755 src/fpm-apache/etc/s6-overlay/s6-rc.d/apache2/run delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/configure-ssl/dependencies delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/configure-ssl/type delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/configure-ssl/up delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/debug-apache2/dependencies delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/debug-apache2/type delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/debug-apache2/up delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/msmtp/type delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/msmtp/up delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/user/contents.d/apache2 delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/user/contents.d/configure-ssl delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/user/contents.d/debug-apache2 delete mode 100644 src/fpm-apache/etc/s6-overlay/s6-rc.d/user/contents.d/msmtp delete mode 100644 src/fpm-apache/etc/s6-overlay/scripts/configure-ssl delete mode 100644 src/fpm-apache/etc/s6-overlay/scripts/debug-apache2 delete mode 100644 src/fpm-apache/etc/s6-overlay/scripts/msmtp delete mode 100644 src/fpm-nginx/Dockerfile delete mode 100644 src/fpm-nginx/README.md delete mode 100644 src/fpm-nginx/etc/nginx/nginx.conf delete mode 100644 src/fpm-nginx/etc/php/fpm/pool.d/z-fpm-with-overrides.conf delete mode 100644 src/fpm-nginx/etc/s6-overlay/s6-rc.d/configure-ssl/dependencies delete mode 100644 src/fpm-nginx/etc/s6-overlay/s6-rc.d/configure-ssl/type delete mode 100644 src/fpm-nginx/etc/s6-overlay/s6-rc.d/configure-ssl/up delete mode 100644 src/fpm-nginx/etc/s6-overlay/s6-rc.d/debug-nginx/dependencies delete mode 100644 src/fpm-nginx/etc/s6-overlay/s6-rc.d/debug-nginx/type delete mode 100644 src/fpm-nginx/etc/s6-overlay/s6-rc.d/debug-nginx/up delete mode 100644 src/fpm-nginx/etc/s6-overlay/s6-rc.d/msmtp/type delete mode 100644 src/fpm-nginx/etc/s6-overlay/s6-rc.d/msmtp/up delete mode 100644 src/fpm-nginx/etc/s6-overlay/s6-rc.d/nginx/dependencies delete mode 100644 src/fpm-nginx/etc/s6-overlay/s6-rc.d/user/contents.d/configure-ssl delete mode 100644 src/fpm-nginx/etc/s6-overlay/s6-rc.d/user/contents.d/debug-nginx delete mode 100644 src/fpm-nginx/etc/s6-overlay/s6-rc.d/user/contents.d/msmtp delete mode 100644 src/fpm-nginx/etc/s6-overlay/scripts/configure-ssl delete mode 100644 src/fpm-nginx/etc/s6-overlay/scripts/debug-nginx delete mode 100644 src/fpm-nginx/etc/s6-overlay/scripts/msmtp delete mode 100644 src/fpm/Dockerfile delete mode 100644 src/fpm/README.md delete mode 100644 src/fpm/etc/s6-overlay/s6-rc.d/laravel-automations/dependencies delete mode 100644 src/fpm/etc/s6-overlay/s6-rc.d/laravel-automations/type delete mode 100644 src/fpm/etc/s6-overlay/s6-rc.d/laravel-automations/up delete mode 100644 src/fpm/etc/s6-overlay/s6-rc.d/php-fpm/data/check delete mode 100644 src/fpm/etc/s6-overlay/s6-rc.d/php-fpm/dependencies delete mode 100644 src/fpm/etc/s6-overlay/s6-rc.d/php-fpm/notification-fd delete mode 100644 src/fpm/etc/s6-overlay/s6-rc.d/php-fpm/type delete mode 100644 src/fpm/etc/s6-overlay/s6-rc.d/user/contents.d/laravel-automations delete mode 100644 src/fpm/etc/s6-overlay/scripts/laravel-automations rename src/{fpm/etc/php/fpm/pool.d/y-override-php-defaults.conf => php-fpm.d/usr/local/etc/php-fpm.d/docker-php-serversideup-pool.conf} (70%) create mode 100644 src/s6/etc/entrypoint.d/10-init-webserver-config.sh create mode 100644 src/s6/etc/s6-overlay/s6-rc.d/php-fpm/data/check create mode 100644 src/s6/etc/s6-overlay/s6-rc.d/php-fpm/dependencies rename src/{fpm-apache/etc/s6-overlay/s6-rc.d/apache2 => s6/etc/s6-overlay/s6-rc.d/php-fpm}/notification-fd (100%) rename src/{fpm => s6}/etc/s6-overlay/s6-rc.d/php-fpm/run (60%) rename src/{fpm-apache/etc/s6-overlay/s6-rc.d/apache2 => s6/etc/s6-overlay/s6-rc.d/php-fpm}/type (100%) rename src/{fpm => s6}/etc/s6-overlay/s6-rc.d/user/contents.d/php-fpm (100%) create mode 100644 src/s6/usr/local/bin/docker-php-serversideup-s6-init create mode 100644 src/s6/usr/local/bin/docker-php-serversideup-s6-install create mode 100644 src/variations/cli/Dockerfile create mode 100644 src/variations/fpm-nginx/Dockerfile create mode 100644 src/variations/fpm-nginx/etc/nginx/nginx.conf.template rename src/{ => variations}/fpm-nginx/etc/nginx/server-opts.d/performance.conf (100%) rename src/{ => variations}/fpm-nginx/etc/nginx/server-opts.d/remoteip.conf (100%) rename src/{ => variations}/fpm-nginx/etc/nginx/server-opts.d/security.conf (100%) rename src/{fpm-nginx/etc/nginx/site-opts.d/http.conf => variations/fpm-nginx/etc/nginx/site-opts.d/http.conf.template} (79%) rename src/{fpm-nginx/etc/nginx/site-opts.d/https.conf => variations/fpm-nginx/etc/nginx/site-opts.d/https.conf.template} (57%) rename src/{ => variations}/fpm-nginx/etc/nginx/sites-available/ssl-full (100%) rename src/{ => variations}/fpm-nginx/etc/nginx/sites-available/ssl-mixed (100%) rename src/{ => variations}/fpm-nginx/etc/nginx/sites-available/ssl-off (100%) rename src/{ => variations}/fpm-nginx/etc/s6-overlay/s6-rc.d/nginx/data/check (76%) create mode 100644 src/variations/fpm-nginx/etc/s6-overlay/s6-rc.d/nginx/dependencies rename src/{ => variations}/fpm-nginx/etc/s6-overlay/s6-rc.d/nginx/notification-fd (100%) rename src/{ => variations}/fpm-nginx/etc/s6-overlay/s6-rc.d/nginx/run (100%) rename src/{ => variations}/fpm-nginx/etc/s6-overlay/s6-rc.d/nginx/type (100%) rename src/{ => variations}/fpm-nginx/etc/s6-overlay/s6-rc.d/user/contents.d/nginx (100%) create mode 100644 src/variations/fpm/Dockerfile create mode 100644 src/variations/unit/Dockerfile create mode 100644 src/variations/unit/etc/entrypoint.d/10-init-unit.sh create mode 100644 src/variations/unit/etc/unit/config.d/ssl-full.json.template create mode 100644 src/variations/unit/etc/unit/config.d/ssl-mixed.json.template create mode 100644 src/variations/unit/etc/unit/config.d/ssl-off.json.template diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 00000000..6a3e68da --- /dev/null +++ b/.dockerignore @@ -0,0 +1 @@ +**/.DS_Store \ No newline at end of file diff --git a/.github/workflows/action_marketing-site-preview.yml b/.github/workflows/action_marketing-site-preview.yml new file mode 100644 index 00000000..72d40978 --- /dev/null +++ b/.github/workflows/action_marketing-site-preview.yml @@ -0,0 +1,14 @@ +name: Site Deployment - Preview 👨‍đŸ”Ŧ + +on: + pull_request: + types: [opened, synchronize, reopened] + paths: + - docs/** + +jobs: + publish-preview-site: + uses: ./.github/workflows/service_deploy-static-site.yml + secrets: inherit + with: + environment-name: 'docker-php (Preview)' \ No newline at end of file diff --git a/.github/workflows/action_marketing-site-publish.yml b/.github/workflows/action_marketing-site-publish.yml new file mode 100644 index 00000000..31adc686 --- /dev/null +++ b/.github/workflows/action_marketing-site-publish.yml @@ -0,0 +1,14 @@ +name: Site Deployment - Production 🚀 +on: + push: + branches: + - main + paths: + - docs/** + +jobs: + publish-production-site: + secrets: inherit + uses: ./.github/workflows/service_deploy-static-site.yml + with: + environment-name: 'docker-php (Production)' \ No newline at end of file diff --git a/.github/workflows/action_publish-beta-images.yml b/.github/workflows/action_publish-beta-images.yml new file mode 100644 index 00000000..f5064673 --- /dev/null +++ b/.github/workflows/action_publish-beta-images.yml @@ -0,0 +1,20 @@ +name: Docker Publish (Beta Images) + +on: + workflow_dispatch: + push: + branches: + - main + paths: + - src/** + - .github/workflows/** + - scripts/** + schedule: + - cron: '0 8 * * 1' + +jobs: + build-beta-images: + uses: ./.github/workflows/service_docker-build-and-publish.yml + with: + tag-prefix: "beta-" + secrets: inherit \ No newline at end of file diff --git a/.github/workflows/action_publish-production-images.yml b/.github/workflows/action_publish-production-images.yml new file mode 100644 index 00000000..b5e7b70b --- /dev/null +++ b/.github/workflows/action_publish-production-images.yml @@ -0,0 +1,16 @@ +name: Docker Publish (Production Images) + +on: + workflow_dispatch: + release: + types: [released] + # Commenting out until 3.x is launched + # schedule: + # - cron: '0 8 * * 2' + +jobs: + build-production-images: + uses: ./.github/workflows/service_docker-build-and-publish.yml + with: + tag-prefix: '' + secrets: inherit \ No newline at end of file diff --git a/.github/workflows/publish_docker-images-production.yml b/.github/workflows/publish_docker-images-production.yml deleted file mode 100644 index ff138fee..00000000 --- a/.github/workflows/publish_docker-images-production.yml +++ /dev/null @@ -1,65 +0,0 @@ -name: Docker Publish (Production Images) - -on: - workflow_dispatch: - release: - types: [released] - schedule: - - cron: '0 8 * * 2' - -jobs: - cli: - uses: ./.github/workflows/service_docker-build-and-publish.yml - with: - upstream-channel-prefix: '' - tag-prefix: '' - php-variation: cli - checkout-type: latest-stable - secrets: inherit - - fpm: - needs: cli - uses: ./.github/workflows/service_docker-build-and-publish.yml - with: - upstream-channel-prefix: '' - tag-prefix: '' - php-variation: fpm - checkout-type: latest-stable - secrets: inherit - - fpm-nginx: - needs: fpm - uses: ./.github/workflows/service_docker-build-and-publish.yml - with: - upstream-channel-prefix: '' - tag-prefix: '' - php-variation: fpm-nginx - checkout-type: latest-stable - secrets: inherit - - fpm-apache: - needs: fpm - uses: ./.github/workflows/service_docker-build-and-publish.yml - with: - upstream-channel-prefix: '' - tag-prefix: '' - php-variation: fpm-apache - checkout-type: latest-stable - secrets: inherit - - update_container_readme: - runs-on: ubuntu-latest - name: Push README to Docker Hub - steps: - - name: git checkout - uses: actions/checkout@v3 - with: - ref: main - - - name: push README to Dockerhub - uses: peter-evans/dockerhub-description@v3 - with: - username: ${{ secrets.DOCKER_HUB_README_USERNAME }} - password: ${{ secrets.DOCKER_HUB_README_PASSWORD }} - repository: serversideup/php - short-description: ${{ github.event.repository.description }} \ No newline at end of file diff --git a/.github/workflows/scheduled-task_update-sponsors.yml b/.github/workflows/scheduled-task_update-sponsors.yml index 4c2144cf..7e61ffc3 100644 --- a/.github/workflows/scheduled-task_update-sponsors.yml +++ b/.github/workflows/scheduled-task_update-sponsors.yml @@ -8,7 +8,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout 🛎ī¸ - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Generate Sponsors 💖 uses: JamesIves/github-sponsors-readme-action@v1 diff --git a/.github/workflows/service_deploy-static-site.yml b/.github/workflows/service_deploy-static-site.yml new file mode 100644 index 00000000..ec62b629 --- /dev/null +++ b/.github/workflows/service_deploy-static-site.yml @@ -0,0 +1,48 @@ +on: + workflow_call: + inputs: + environment-name: + required: true + type: string + +jobs: + deploy-static-site: + runs-on: ubuntu-latest + permissions: + contents: read + deployments: write + environment: + name: ${{ inputs.environment-name }} + steps: + - uses: actions/checkout@v4 + + - uses: actions/setup-node@v4 + with: + node-version-file: './docs/.nvmrc' + + - name: Set env file + run: | + if [[ -z "$BASE_64_SECRET" ]]; then + echo '🚨🚨🚨 ENV File not set 🚨🚨🚨' 1>&2 + exit 1 + fi + echo $BASE_64_SECRET | base64 -d > .env + working-directory: ./docs + env: + BASE_64_SECRET: ${{ secrets.ENV_FILE_BASE64 }} + + - run: | + yarn install --frozen-lockfile + yarn build + npx nuxi generate + working-directory: ./docs + + - name: Publish to Cloudflare Pages + uses: cloudflare/pages-action@v1 + with: + apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} + accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} + projectName: docker-php + directory: docs/.output/public + branch: ${{ github.head_ref || github.ref_name }} + gitHubToken: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file diff --git a/.github/workflows/service_docker-build-and-publish.yml b/.github/workflows/service_docker-build-and-publish.yml index 87baf499..0ea3de0c 100644 --- a/.github/workflows/service_docker-build-and-publish.yml +++ b/.github/workflows/service_docker-build-and-publish.yml @@ -1,65 +1,72 @@ on: workflow_call: inputs: - upstream-channel-prefix: - required: true - type: string - default: '' tag-prefix: required: true type: string - default: 'beta-' - php-variation: - required: true + default: 'edge-' + php-versions-file: type: string - checkout-type: - required: true + default: 'scripts/conf/php-versions.yml' + default-image-variation: type: string + default: 'cli' jobs: + setup-matrix: + runs-on: ubuntu-22.04 + outputs: + php-version-map-json: ${{ steps.get-php-versions.outputs.php-version-map-json }} + steps: + - name: Check out code + uses: actions/checkout@v4 + + - name: Prepare PHP versions for the matrix. 😎 + run: | + chmod +x ./scripts/get-php-versions.sh + ./scripts/get-php-versions.sh + + - name: Ensure our PHP Versions file exists. + run: | + if [ ! -f "${{ inputs.php-versions-file }}" ]; then + echo "PHP Versions file does not exist. Exiting." + exit 1 + else + cat ${{ inputs.php-versions-file }} + fi + + - name: Assemble PHP versions into the matrix. 😎 + id: get-php-versions + run: | + MATRIX_JSON=$(yq -o=json scripts/conf/php-versions.yml | jq -c '{include: [(.php_variations[] | {name, supported_os: (.supported_os // ["alpine", "bullseye", "bookworm"])} ) as $variation | .php_versions[] | .minor_versions[] | .patch_versions[] as $patch | .base_os[] as $os | select($variation.supported_os | if length == 0 then . else . | index($os.name) end) | {patch_version: $patch, base_os: $os.name, php_variation: $variation.name}]}') + echo "php-version-map-json=${MATRIX_JSON}" >> $GITHUB_OUTPUT + echo "${MATRIX_JSON}" | jq '.' + + - name: Upload the php-versions.yml file + uses: actions/upload-artifact@v3 + with: + name: php-versions.yml + path: ${{ inputs.php-versions-file }} + docker-publish: + needs: setup-matrix runs-on: ubuntu-22.04 strategy: - matrix: - php-version: - - "7.4" - - "8.0" - - "8.1" - - "8.2" - steps: - ## - # Checkout branch (for push deployments) - ## - - name: Get branch name - if: inputs.checkout-type == 'branch' - id: branch-name - uses: tj-actions/branch-names@v6 + matrix: ${{fromJson(needs.setup-matrix.outputs.php-version-map-json)}} - - uses: actions/checkout@v3 - if: inputs.checkout-type == 'branch' + steps: + - name: Check out code. + uses: actions/checkout@v4 + + - name: Download PHP Versions file + uses: actions/download-artifact@v3 with: - ref: ${{ steps.branch-name.outputs.current_branch }} + name: php-versions.yml + path: ./artifacts + + - name: Move PHP Versions file + run: mv ./artifacts/php-versions.yml ${{ inputs.php-versions-file }} - ## - # Checkout latest stable release (for production releases) - ## - - name: Get latest stable release - if: inputs.checkout-type == 'latest-stable' - id: latest-stable-version - run: | - echo "LATEST_STABLE_VERSION=$(curl --silent --header "Accept: application/vnd.github.v3.sha" "$GITHUB_API_URL/repos/$GITHUB_REPOSITORY/releases/latest" | grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/')" >> $GITHUB_OUTPUT - - - name: Confirm release tag - if: inputs.checkout-type == 'latest-stable' - run: | - echo "Latest Stable Release Tag: ${{ steps.latest-stable-version.outputs.LATEST_STABLE_VERSION }}" - - - name: Checkout latest stable tag - if: inputs.checkout-type == 'latest-stable' - uses: actions/checkout@v3 - with: - ref: ${{ steps.latest-stable-version.outputs.LATEST_STABLE_VERSION }} - ## # Docker build & publish ## @@ -69,27 +76,52 @@ jobs: username: ${{ secrets.DOCKER_HUB_USERNAME }} password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }} + - name: Login to GitHub Container Registry + uses: docker/login-action@v3 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + - name: Set up QEMU - uses: docker/setup-qemu-action@v2 + uses: docker/setup-qemu-action@v3 - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v2 - - - name: "👨‍đŸ”Ŧ Set docker tags: Non-Release " - if: inputs.checkout-type == 'branch' - run: echo "DOCKER_TAGS=serversideup/php:${{ inputs.tag-prefix}}${{ matrix.php-version }}-${{ inputs.php-variation }}" >> $GITHUB_ENV + uses: docker/setup-buildx-action@v3 - - name: "🚀 Set docker tags: Release" - if: inputs.checkout-type == 'latest-stable' - run: echo "DOCKER_TAGS=serversideup/php:${{ inputs.tag-prefix}}${{ matrix.php-version }}-${{ inputs.php-variation }}, serversideup/php:${{ inputs.tag-prefix}}${{ matrix.php-version }}-${{ inputs.php-variation }}-${{ steps.latest-stable-version.outputs.LATEST_STABLE_VERSION }}" >> $GITHUB_ENV + - name: "đŸ“Ļ Assemble the Docker Tags" + run: | + chmod +x ./scripts/assemble-docker-tags.sh + ./scripts/assemble-docker-tags.sh + env: + PHP_VERSIONS_FILE: "${{ inputs.php-versions-file }}" + DEFAULT_IMAGE_VARIATION: ${{ inputs.default-image-variation }} + PHP_BUILD_VERSION: ${{ matrix.patch_version }} + PHP_BUILD_VARIATION: ${{ matrix.php_variation }} + PHP_BUILD_BASE_OS: ${{ matrix.base_os }} + DOCKER_TAG_PREFIX: ${{ inputs.tag-prefix }} + + - name: Set REPOSITORY_BUILD_VERSION + id: set_version + run: | + if [ "${{ github.ref_type }}" == "tag" ]; then + echo "🚀 Setting REPOSITORY_BUILD_VERSION to Tag" + echo "REPOSITORY_BUILD_VERSION=${{ github.ref_name }}" >> $GITHUB_ENV + else + echo "👨‍đŸ”Ŧ Setting REPOSITORY_BUILD_VERSION to GIT Short SHA and GitHub Run ID" + SHORT_SHA=$(echo ${{ github.sha }} | cut -c1-7) + echo "REPOSITORY_BUILD_VERSION=git-${SHORT_SHA}-${{ github.run_id }}" >> $GITHUB_ENV + fi - name: Build and push - uses: docker/build-push-action@v3 + uses: docker/build-push-action@v5 with: + file: src/variations/${{ matrix.php_variation }}/Dockerfile build-args: | - UPSTREAM_CHANNEL=${{ inputs.upstream-channel-prefix }} - PHP_VERSION=${{ matrix.php-version }} - context: src/${{ inputs.php-variation }}/. + BASE_OS_VERSION=${{ matrix.base_os }} + PHP_VERSION=${{ matrix.patch_version }} + PHP_VARIATION=${{ matrix.php_variation }} + REPOSITORY_BUILD_VERSION=${{ env.REPOSITORY_BUILD_VERSION }} platforms: | linux/amd64 linux/arm/v7 diff --git a/.github/workflows/site_deploy-static-site.yml b/.github/workflows/site_deploy-static-site.yml deleted file mode 100644 index 49a6e65d..00000000 --- a/.github/workflows/site_deploy-static-site.yml +++ /dev/null @@ -1,43 +0,0 @@ -name: 🚀 Deploy Static Site - -on: - push: - branches: - - main - paths: - - docs/** - -jobs: - deploy-static-site: - runs-on: ubuntu-latest - permissions: - contents: read - deployments: write - steps: - - uses: actions/checkout@v3 - - - name: Set env file - run: | - if [[ -z "$BASE_64_SECRET" ]]; then - echo '🚨🚨🚨 ENV File not set 🚨🚨🚨' 1>&2 - exit 1 - fi - echo $BASE_64_SECRET | base64 -d > .env - working-directory: ./docs - env: - BASE_64_SECRET: ${{ secrets.ENV_FILE_BASE64_PROD }} - - - run: | - yarn install --frozen-lockfile - yarn build - npx nuxi generate - working-directory: ./docs - - - name: Publish to Cloudflare Pages - uses: cloudflare/pages-action@v1 - with: - apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} - accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} - projectName: docker-php - directory: docs/.output/public - gitHubToken: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file diff --git a/.github/workflows/site_preview-setup.yml b/.github/workflows/site_preview-setup.yml deleted file mode 100644 index 86a3d6bd..00000000 --- a/.github/workflows/site_preview-setup.yml +++ /dev/null @@ -1,40 +0,0 @@ -name: 🔂 CloudFlare Pages Preview - -on: - pull_request: - types: [opened, synchronize, reopened] - -jobs: - build-site: - runs-on: ubuntu-latest - permissions: - contents: read - deployments: write - steps: - - uses: actions/checkout@v3 - - - name: Set env file - run: | - if [[ -z "$BASE_64_SECRET" ]]; then - echo '🚨🚨🚨 ENV File not set 🚨🚨🚨' 1>&2 - exit 1 - fi - echo $BASE_64_SECRET | base64 -d > .env - working-directory: ./docs - env: - BASE_64_SECRET: ${{ secrets.ENV_FILE_BASE64 }} - - - run: | - yarn install --frozen-lockfile - yarn build - npx nuxi generate - working-directory: ./docs - - - name: Publish to Cloudflare Pages - uses: cloudflare/pages-action@v1 - with: - apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} - accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} - projectName: docker-php - directory: docs/.output/public - gitHubToken: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file diff --git a/.gitignore b/.gitignore index 50f5a290..cbc1be6a 100644 --- a/.gitignore +++ b/.gitignore @@ -2,4 +2,6 @@ package-lock.json package.json yarn.lock -node_modules \ No newline at end of file +node_modules +php-versions.yml +*.tmp \ No newline at end of file diff --git a/README.md b/README.md index 5c6d59ff..2f4fabc1 100644 --- a/README.md +++ b/README.md @@ -6,13 +6,12 @@ License Support us
- Docker Pulls - Discourse users + Docker Hub Pulls Discord

## Introduction -`PHP Docker Images` is an optimized set of Docker Images for running PHP applications in production. Everything is designed around improving the developer experience with PHP and Docker. Gone are the days of configuring each environment differently, and gone are the days of trying to figure out why your code works in one environment and not the other. +`serversideup/php` is an optimized set of Docker Images for running PHP applications in production. Everything is designed around improving the developer experience with PHP and Docker. Gone are the days of configuring each environment differently, and gone are the days of trying to figure out why your code works in one environment and not the other. These images are highly optimized to run modern PHP applications, no matter where you want your application to run. @@ -25,10 +24,10 @@ Experience the ***true difference*** of using these images vs the other options Features
-|Production-Ready|Native Health Checks|High Performance| +|Production-Ready|Native Health Checks|High Performance| |:---:|:---:|:---:| -|Customizable and Flexible|Built on Ubuntu 22.04|Built with Ondrej PHP| -|NGINX + PHP-FPM|Unified Logging|Built with S6 Overlay| +|Customizable and Flexible|Native CloudFlare Support|Base on Official PHP| +|NGINX Unit|Unified Logging|FPM + S6 Overlay| @@ -86,6 +85,14 @@ All of our software is free an open to the world. None of this can be brought to #### Individual Supporters alexjustesen  GeekDougle   +#### Special thanks +We'd like to specifically thank a few folks for taking the time for being a sound board that deeply influenced the direction of this project. + +Please check out all of their work: +- [Chris Fidao](https://twitter.com/fideloper) +- [Joel Clermont](https://twitter.com/joelclermont) +- [Patricio](https://twitter.com/PatricioOnCode) + ## About Us We're [Dan](https://twitter.com/danpastori) and [Jay](https://twitter.com/jaydrogers) - a two person team with a passion for open source products. We created [Server Side Up](https://serversideup.net) to help share what we learn. @@ -112,6 +119,7 @@ If you appreciate this project, be sure to check out our other projects. ### 📚 Books - **[The Ultimate Guide to Building APIs & SPAs](https://serversideup.net/ultimate-guide-to-building-apis-and-spas-with-laravel-and-nuxt3/)**: Build web & mobile apps from the same codebase. +- **[Building Multi-Platform Browser Extensions](https://serversideup.net/building-multi-platform-browser-extensions/)**: Ship extensions to all browsers from the same codebase. ### 🛠ī¸ Software-as-a-Service - **[Bugflow](https://bugflow.io/)**: Get visual bug reports directly in GitHub, GitLab, and more. diff --git a/dev.sh b/dev.sh deleted file mode 100755 index 411396df..00000000 --- a/dev.sh +++ /dev/null @@ -1,80 +0,0 @@ -#!/bin/bash - -#exit on error -set -e - -########################## -# Environment Settings -DEV_UPSTREAM_CHANNEL="beta-" - -# UI Colors -function ui_set_yellow { - printf $'\033[0;33m' -} - -function ui_set_green { - printf $'\033[0;32m' -} - -function ui_set_red { - printf $'\033[0;31m' -} - -function ui_reset_colors { - printf "\e[0m" -} - -# Script Configurations -SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" - -########################## -# Set versions to build -if [ $# -eq 0 ]; then - # Set versions - phpVersions=() - - echo "Running build for these PHP versions..." - # Loop through each .txt file in the current directory - for file in src/cli/php-version-packages/*.txt; do - # Trim the extension off the filename and add it to the array - phpVersion=$(basename -- "$file") - phpVersion="${phpVersion%.*}" - phpVersions+=("$phpVersion") - - # Print the filename without the extension - echo "$phpVersion" - done -else - phpVersions=$1 -fi - -########################## -# Functions - -function build (){ - label=$(echo $1 | tr '[:lower:]' '[:upper:]') - ui_set_yellow && echo "⚡ī¸ Running build for $label - ${2} ..." && ui_reset_colors - - # Use "docker build" - docker build \ - --build-arg UPSTREAM_CHANNEL="${DEV_UPSTREAM_CHANNEL}" \ - --build-arg PHP_VERSION="${2}" \ - -t "serversideup/php:beta-${2}-$1" \ - $SCRIPT_DIR/src/$1/ - - ui_set_green && echo "✅ Build completed for $label - ${2} (serversideup/php:beta-${2}-$1)" && ui_reset_colors -} - -function build_versions { - # Grab each PHP version defined in `build.sh` and deploy these images to our LOCAL registry - for version in ${phpVersions[@]}; do - build cli ${version[$i]} - build fpm ${version[$i]} - build fpm-apache ${version[$i]} - build fpm-nginx ${version[$i]} - done -} - -########################## -# Main script starts here -build_versions \ No newline at end of file diff --git a/docs/.env.example b/docs/.env.example index 08b6fe36..e2fe96ab 100644 --- a/docs/.env.example +++ b/docs/.env.example @@ -1,5 +1,7 @@ NUXT_APP_BASE_URL=/open-source/docker-php TOP_LEVEL_DOMAIN=http://localhost:3000 +BASE_PATH=http://localhost:3000/open-source/docker-php +TOP_LEVEL_DOMAIN=http://localhost:3000 ALGOLIA_API_KEY=changeme ALGOLIA_APPLICATION_ID=changeme ALGOLIA_INDEX=changeme \ No newline at end of file diff --git a/docs/.nvmrc b/docs/.nvmrc new file mode 100644 index 00000000..2edeafb0 --- /dev/null +++ b/docs/.nvmrc @@ -0,0 +1 @@ +20 \ No newline at end of file diff --git a/docs/components/Global/OgImage/DocsImage.vue b/docs/components/Global/OgImage/DocsImage.vue new file mode 100644 index 00000000..bc5448b8 --- /dev/null +++ b/docs/components/Global/OgImage/DocsImage.vue @@ -0,0 +1,35 @@ + + + \ No newline at end of file diff --git a/docs/components/Global/ServerSideUp.vue b/docs/components/Global/ServerSideUp.vue index de38cde4..e2d83491 100644 --- a/docs/components/Global/ServerSideUp.vue +++ b/docs/components/Global/ServerSideUp.vue @@ -1,5 +1,5 @@