VictorMLN/docker-php-nginx-psql-testing

一个项目模板,包含PHP 8.1 + nginx + postgres + 测试环境

8.1 2022-06-18 22:21 UTC

This package is auto-updated.

Last update: 2024-09-18 20:51:14 UTC


README

PHP Version

简介

模板仓库,提供PHP + nginx + PostgreSQL + 测试环境,可通过本地URL访问:http://web-server.test

模板中包含的内容

  • PHP-fpm
  • 已准备好的php.ini,可由您自行编辑
  • Composer
  • Makefile
  • Xdebug
  • PostgreSQL
  • PHPUnit
  • Infection
  • Nginx

安装

  1. 通过Composer
$ composer create-project victormln/docker-php-nginx-psql-testing your-project

或使用git

$ git clone https://github.com/victormln/docker-php-nginx-psql-testing.git your-project
$ cd your-project
$ make install # It will ask you for your sudo password in order to add to your /etc/hosts the domain
  1. 启动web服务器
$ make start

测试网站: https://web-server.test(您将看到所有的phpinfo()信息)

现在您可以在public/index.php文件中编辑,并开始编码!