Skip to content

Instantly share code, notes, and snippets.

@pastleo
Created April 10, 2017 05:35
Show Gist options
  • Save pastleo/25c0d05270e2efa89d9ce14b6e457027 to your computer and use it in GitHub Desktop.
Save pastleo/25c0d05270e2efa89d9ce14b6e457027 to your computer and use it in GitHub Desktop.
docker-compose.yml for php7 built-in server
version: '3.1'
services:
server:
image: php:7
working_dir: /var/www/html
ports:
- 8002:8002
volumes:
- .:/var/www/html
command: php -S 0.0.0.0:8002
@pastleo
Copy link
Author

pastleo commented Apr 10, 2017

把這個 docker-compose.yml 放到專案資料夾,然後用在專案資料夾內下 docker-compose up 就可以跑起來了,然後用 Ctrl+c 關掉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment