Ref: http://mmenozzi.github.io/2016/01/22/php-web-development-with-docker/
1. docker run -p 80:80 webgriffe/php-apache-base
2. Test w3school php tutorials
3-1 prepare ex5.php and upload.php
3-2 login container
docker exec -it #ID /bin/bash
mkdir uploads (@ /var/www/html)
chmod 777 upload
3-3 test ex5.php
<!DOCTYPE html>
<html>
<body>
<form action="upload.php" method="post" enctype="multipart/form-data">
Select image to upload:
<input type="file" name="fileToUpload" id="fileToUpload">
<input type="submit" value="Upload Image" name="submit">
</form>
</body>
</html>
Fail---
Ref: https://github.com/rmuch/docker-php-hello-world
1, git clone https://github.com/rmuch/docker-php-hello-world.git
2. docker build -t docker-php-hello-world .
3.
沒有留言:
張貼留言