{"id":8823,"date":"2017-03-10T13:10:11","date_gmt":"2017-03-10T04:10:11","guid":{"rendered":"http:\/\/sitest.jp\/blog\/?p=8823"},"modified":"2017-03-10T13:04:43","modified_gmt":"2017-03-10T04:04:43","slug":"1%e3%82%b3%e3%83%9e%e3%83%b3%e3%83%89%e3%81%a7%e4%bd%9c%e3%81%a3%e3%81%9f%e3%80%82docker%e3%81%a7%e9%96%8b%e7%99%ba%e7%92%b0%e5%a2%83%e3%82%92%e6%a7%8b%e7%af%89%e3%81%99%e3%82%8b%e6%96%b9%e6%b3%95","status":"publish","type":"post","link":"https:\/\/sitest.jp\/blog\/?p=8823","title":{"rendered":"1\u30b3\u30de\u30f3\u30c9\u3067\u4f5c\u3063\u305f\u3002Docker\u3067\u958b\u767a\u74b0\u5883\u3092\u69cb\u7bc9\u3059\u308b\u65b9\u6cd5"},"content":{"rendered":"<p>\u6700\u7d42\u7684\u306b\u305f\u3063\u305f1\u30b3\u30de\u30f3\u30c9\u3067\u958b\u767a\u74b0\u5883\u3092\u4f5c\u308a\u4e0a\u3052\u3066\u3057\u307e\u3046\u4e8b\u3092\u30b4\u30fc\u30eb\u306b\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u4f5c\u6210\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<p><a href=\"http:\/\/sitest.jp\/blog\/?p=8529\" title=\"null\" rel=\"nofollow\" target=\"_blank\">\u524d\u56de\u306e\u8a18\u4e8b<\/a>\u3067\u306fVagrant\u3068Docker\u306e\u9055\u3044\u306b\u95a2\u3057\u3066\u958b\u8a2d\u3057\u307e\u3057\u305f\u304c\u3001\u5b9f\u969b\u306bLAMP\u30b5\u30fc\u30d0\u30fc\u30921\u30b3\u30de\u30f3\u30c9\u3067\u7acb\u3061\u4e0a\u3052\u3066\u884c\u304d\u305f\u3044\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<p><!--more--><\/p>\n<div class=\"frame_headding\">\n<h3 style=\"text-align: left;\">\u305d\u3082\u305d\u3082Docker\u306f\u4f55\u3092\u7f6e\u304d\u63db\u3048\u308b\u3082\u306e\u306a\u306e\u304b<\/h3>\n<\/div>\n<p><a href=\"https:\/\/www.vagrantup.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Vagrant<\/a>\u306f\u4eee\u60f3\u30de\u30b7\u30f3\u81ea\u4f53\u3092\u7ba1\u7406\u3057\u307e\u3059\u3002<br \/>\u7d30\u304b\u3044\u30a2\u30d7\u30ea\u3084\u30b7\u30b9\u30c6\u30e0\u69cb\u6210\u306f<a href=\"http:\/\/yteraoka.github.io\/ansible-tutorial\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Ansible<\/a>\u3067\u6574\u3048\u3066\u3001\u5168\u304f\u540c\u3058\u30de\u30b7\u30f3\u3092\u7528\u610f\u3059\u308b\u3053\u3068\u304c\u76ee\u7684\u3067\u3057\u305f\u3002<\/p>\n<p>\u5bfe\u3059\u308b<a href=\"https:\/\/www.docker.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker<\/a>\u306f\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306e\u4eee\u60f3\u5316\u3068\u3044\u3046\u6982\u5ff5\u3067\u516c\u958b\u3055\u308c\u3066\u3044\u307e\u3059\u3002<br \/>\u306a\u306e\u3067\u3001\u7f6e\u304d\u63db\u3048\u308b\u5bfe\u8c61\u306f\u3042\u304f\u307e\u3067<a href=\"https:\/\/httpd.apache.org\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Apache<\/a>\u3084<a href=\"https:\/\/www-jp.mysql.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">MySQL<\/a>\u7b49\u306e\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u3084\u305d\u306e\u4f9d\u5b58\u30e9\u30a4\u30d6\u30e9\u30ea\u306b\u306a\u308a\u307e\u3059\u3002<br \/>\u4e0a\u304cVagrant+Ansible\u3067\u3001\u4e0b\u304cDocker\u3092\u542b\u3081\u305f\u69cb\u6210\u56f3\u3067\u3059\u3002<\/p>\n<p><img loading=\"lazy\" src=\"https:\/\/storage.googleapis.com\/sitest-wp\/blog\/wp-content\/uploads\/2017\/02\/1_vagrant-ansible.png\" alt=\"1_vagrant-ansible\" width=\"765\" height=\"440\" class=\"alignnone size-full wp-image-8825\" \/><\/p>\n<p><img loading=\"lazy\" src=\"https:\/\/storage.googleapis.com\/sitest-wp\/blog\/wp-content\/uploads\/2017\/02\/2_vagrant-docker.png\" alt=\"2_vagrant-docker\" width=\"710\" height=\"562\" class=\"alignnone size-full wp-image-8826\" \/><\/p>\n<p>\u3061\u3087\u3063\u3068\u5f85\u3063\u3066\u3001\u5185\u5bb9\u304c\u5897\u3048\u305f\u3060\u3051\u3067\u5168\u7136\u697d\u306b\u306a\u3063\u3066\u306a\u3044\u3058\u3083\u3093\uff01<br \/>\u305d\u3046\u306a\u306e\u3067\u3059\u3002<br \/>\u30ed\u30fc\u30ab\u30eb\u306e\u958b\u767a\u74b0\u5883\u306b\u7740\u76ee\u3057\u305f\u5834\u5408\u3001\u4f7f\u3046\u30c4\u30fc\u30eb\u304c\u5897\u3048\u305f\u5206\u74b0\u5883\u3092\u69cb\u7bc9\u3059\u308b\u30b3\u30b9\u30c8\u306f\u5897\u3048\u307e\u3059\u3002<\/p>\n<p>\u3057\u304b\u3057\u3001\u7121\u99c4\u306b\u8907\u96d1\u306b\u306a\u3063\u305f\u308f\u3051\u3067\u306f\u3042\u308a\u307e\u305b\u3093\u3002<br \/><a href=\"https:\/\/www.docker.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker<\/a>\u306f\u672c\u756a\u74b0\u5883\u3078\u306e\u30c7\u30d7\u30ed\u30a4\u3092\u898b\u8d8a\u3057\u3066\u63a1\u7528\u3057\u307e\u3059\u3002<\/p>\n<p><img loading=\"lazy\" src=\"https:\/\/storage.googleapis.com\/sitest-wp\/blog\/wp-content\/uploads\/2017\/02\/9537db8a7fbe04d6d005e9ee0b16dede.png\" alt=\"\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8 2017-02-13 11.41.54\" width=\"988\" height=\"718\" class=\"alignnone size-full wp-image-8536\" \/><\/p>\n<p>\u601d\u308f\u306c\u826f\u3044\u52b9\u679c\u3082\u3042\u308a\u307e\u3059\u3002<br \/>\u4eca\u307e\u3067\u306f\u30b7\u30b9\u30c6\u30e0\u69cb\u7bc9\u3059\u308b\u4e0a\u3067\u306e\u30a2\u30d7\u30ea\u3084\u4f9d\u5b58\u30e9\u30a4\u30d6\u30e9\u30ea\u306f\u5168\u3066<a href=\"http:\/\/yteraoka.github.io\/ansible-tutorial\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Ansible<\/a>\u3067\u7528\u610f\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3057\u305f\u304c\u3001\u5168\u3066<a href=\"https:\/\/www.docker.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker<\/a>\u306b\u9003\u304c\u305b\u307e\u3059\u3002<br \/><a href=\"http:\/\/yteraoka.github.io\/ansible-tutorial\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Ansible<\/a>\u306f<a href=\"https:\/\/www.docker.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker<\/a>\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u306b\u96c6\u4e2d\u3059\u308b\u3060\u3051\u3067\u826f\u304f\u306a\u3063\u305f\u306e\u3067\u3059\u3002<\/p>\n<p>\u3082\u3046\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u5ea6\u306bVagrantfile\u3084Playbook\u3092\u5207\u308a\u8cbc\u308a\u3057\u3066\u4f3c\u305f\u3088\u3046\u306a\u30d5\u30a1\u30a4\u30eb\u3092\u5927\u91cf\u306b\u751f\u6210\u3059\u308b\u3053\u3068\u306f\u3042\u308a\u307e\u305b\u3093\u3002<\/p>\n<div class=\"frame_headding\">\n<h3 style=\"text-align: left;\">Vagrant\u3082Ansible\u3082Docker\u306b\u7f6e\u304d\u63db\u308f\u308a\u307e\u3057\u305f<\/h3>\n<\/div>\n<p>Vagrant\u306b\u95a2\u3059\u308b\u8a18\u4e8b\u306e\u57f7\u7b46\u5f53\u521d\u306f<a href=\"https:\/\/www.vagrantup.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Vagrant<\/a>+<a href=\"http:\/\/yteraoka.github.io\/ansible-tutorial\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Ansible<\/a>+<a href=\"https:\/\/www.docker.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker<\/a>\u3092\u7d44\u307f\u5408\u308f\u305b\u3066\u6700\u5f37\u306e\u958b\u767a\u74b0\u5883\u3092\u4f5c\u308b\u4e8b\u3092\u30b4\u30fc\u30eb\u306b\u3057\u3066\u3044\u307e\u3057\u305f\u3002<br \/>\u65e2\u306b<a href=\"https:\/\/docs.docker.com\/docker-for-windows\/install\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker for Windows<\/a>\u3084<a href=\"https:\/\/docs.docker.com\/docker-for-mac\/install\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker for Mac<\/a>\u304c\u6b63\u5f0f\u7248\u306b\u306a\u3063\u3066\u65e2\u306b\u534a\u5e74\u304c\u7d4c\u904e\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p><img loading=\"lazy\" src=\"https:\/\/storage.googleapis.com\/sitest-wp\/blog\/wp-content\/uploads\/2017\/02\/3_docker-for-mac.png\" alt=\"3_docker-for-mac\" width=\"709\" height=\"405\" class=\"alignnone size-full wp-image-8827\" \/><\/p>\n<p>\u3082\u3046<a href=\"https:\/\/www.vagrantup.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Vagrant<\/a>+<a href=\"http:\/\/yteraoka.github.io\/ansible-tutorial\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Ansible<\/a>\u306b\u6b8b\u3063\u3066\u3044\u308b\u30e1\u30ea\u30c3\u30c8\u306f\u30af\u30e9\u30a6\u30c9\u30de\u30b7\u30f3\u306e\u64cd\u4f5c\u3068\u8907\u6570\u74b0\u5883\u3092\u7acb\u3061\u4e0a\u3052\u308b\u304f\u3089\u3044\u3057\u304b\u6b8b\u3063\u3066\u3044\u307e\u305b\u3093\u3002<br \/>\u7279\u6b8a\u306a\u7528\u9014\u3067<a href=\"https:\/\/www.vagrantup.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Vagrant<\/a>\u3092\u6d3b\u7528\u3059\u308b\u30b1\u30fc\u30b9\u4ee5\u5916\u3001<a href=\"https:\/\/www.docker.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker<\/a>\u306e\u307f\u3067\u958b\u767a\u74b0\u5883\u3092\u69cb\u7bc9\u3057\u3066\u3044\u304f\u30b9\u30bf\u30a4\u30eb\u304c\u4e3b\u6d41\u306b\u306a\u308b\u3053\u3068\u3067\u3057\u3087\u3046\u3002<\/p>\n<p>\u3088\u3063\u3066\u3001\u6b21\u306e\u7ae0\u304b\u3089\u306f<a href=\"https:\/\/docs.docker.com\/docker-for-windows\/install\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker for Windows<\/a>\u3068<a href=\"https:\/\/docs.docker.com\/docker-for-mac\/install\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker for Mac<\/a>\u3092\u30d9\u30fc\u30b9\u306b\u3059\u3059\u3081\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<div class=\"frame_headding\">\n<h3 style=\"text-align: left;\">LAMP\u74b0\u5883\u3092\u7acb\u3061\u4e0a\u3052\u3066\u307f\u308b<\/h3>\n<\/div>\n<p>\u307e\u305a\u306f<a href=\"https:\/\/docs.docker.com\/docker-for-windows\/install\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker for Windows<\/a>\u3001\u3082\u3057\u304f\u306f<a href=\"https:\/\/docs.docker.com\/docker-for-mac\/install\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker for Mac<\/a>\u3092\u516c\u5f0f\u30b5\u30a4\u30c8\u304b\u3089\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3057\u3087\u3046\u3002<br \/>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u304c\u5b8c\u4e86\u3057\u305f\u3089\u3001\u30bf\u30fc\u30df\u30ca\u30eb\u30a8\u30df\u30e5\u30ec\u30fc\u30bf\u3092\u958b\u304d\u3001docker\u30b3\u30de\u30f3\u30c9\u304c\u5229\u7528\u51fa\u6765\u308b\u3053\u3068\u3092\u78ba\u8a8d\u3057\u307e\u3059\u3002<br \/>\u78ba\u8a8d\u306b\u306f<code>docker version<\/code>\u30b3\u30de\u30f3\u30c9\u304c\u5229\u7528\u3067\u304d\u307e\u3059\u3002<\/p>\n<pre><code class=\"lang-Bash\">$ docker version\nClient:\n Version:      1.13.1\n API version:  1.26\n Go version:   go1.7.5\n Git commit:   092cba3\n Built:        Wed Feb  8 08:47:51 2017\n OS\/Arch:      darwin\/amd64\n\nServer:\n Version:      1.13.1\n API version:  1.26 (minimum version 1.12)\n Go version:   go1.7.5\n Git commit:   092cba3\n Built:        Wed Feb  8 08:47:51 2017\n OS\/Arch:      linux\/amd64\n Experimental: true\n\n\/\/ Docker for xxx\u304c\u7acb\u3061\u4e0a\u304c\u3063\u3066\u3044\u306a\u3044\u5834\u5408\n$ docker version\nClient:\n Version:      1.13.1\n API version:  1.26\n Go version:   go1.7.5\n Git commit:   092cba3\n Built:        Wed Feb  8 08:47:51 2017\n OS\/Arch:      darwin\/amd64\nCannot connect to the Docker daemon at unix:\/\/\/var\/run\/docker.sock. Is the docker daemon running?\n<\/code><\/pre>\n<p>\u305d\u308c\u3067\u306fHelloWorld\u3092\u51fa\u529b\u3059\u308bPHP\u30d5\u30a1\u30a4\u30eb\u3092\u751f\u6210\u3057\u3001<br \/>Docker\u3067\u4f5c\u3063\u305fWeb\u30b5\u30fc\u30d0\u30fc\u3067\u78ba\u8a8d\u3059\u308b\u3068\u3044\u3046\u4e8b\u3092\u3084\u3063\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<pre><code class=\"lang-Bash\">$ cat &lt;&lt; EOF &gt; index.php\n&lt;?php\necho &quot;Hello&quot;, &quot;World&quot;;\nEOF\n\n$ docker run -d -p &quot;80:80&quot; -v &quot;$PWD:\/var\/www\/html&quot; php:apache\n8e7374e208e40776fa8b14742e054a7074ee6d0e815af15590aaff968f1a6c6f\n\n$ curl localhost\nHelloWorld\n\n$ docker ps\nCONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS              PORTS                NAMES\n8e7374e208e4        php:apache          &quot;docker-php-entryp...&quot;   31 seconds ago      Up 30 seconds       0.0.0.0:80-&gt;80\/tcp   condescending_goldwasser\n<\/code><\/pre>\n<p>\u3053\u306e<code>docker run<\/code>\u30b3\u30de\u30f3\u30c9\u304c\u5c11\u3005\u9577\u304f\u3066\u3084\u3084\u3053\u3057\u3044\u4ee5\u5916\u306f\u3068\u3066\u3082\u697d\u3067\u3059\u306d\u3002<br \/>\u672c\u8a18\u4e8b\u306e\u76ee\u7684\u3067\u3042\u308b1\u30b3\u30de\u30f3\u30c9\u306b\u3050\u3063\u3068\u8fd1\u3065\u3044\u305f\u3088\u3046\u306b\u601d\u3048\u307e\u3059\u3002<\/p>\n<p>\u3067\u306f\u3001\u540c\u69d8\u306b\u521d\u671f\u72b6\u614b\u306eMySQL\u30b5\u30fc\u30d0\u30fc\u3092\u7acb\u3061\u4e0a\u3052\u3066\u63a5\u7d9a\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<br \/>(mysql\u30b3\u30de\u30f3\u30c9\u306elocalhost\u306f\u901a\u4fe1\u3092\u884c\u308f\u305a\u306b\u30d7\u30ed\u30bb\u30b9\u3092\u76f4\u63a5\u53e9\u304d\u306b\u884c\u304d\u307e\u3059\u306e\u3067\u3002\u63a5\u7d9a\u3067\u304d\u306a\u3051\u308c\u3070127.0.0.1\u30840.0.0.0\u7b49\u3092\u8a66\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002)<\/p>\n<pre><code class=\"lang-Bash\">$ docker run -d -p &quot;3306:3306&quot; -e MYSQL_ROOT_PASSWORD=test mysql:latest\ne5b3f76eb6f393185010326c9c324063abe4d61b3633d5555b097a77f3569118\n\n$ mysql -h 127.0.0.1 -uroot -ptest -e &quot;show databases;&quot;\n+--------------------+\n| Database           |\n+--------------------+\n| information_schema |\n| mysql              |\n| performance_schema |\n| sys                |\n+--------------------+\n\n$ docker ps\nCONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS              PORTS                    NAMES\nf6ecc6d0c10c        mysql:latest        &quot;docker-entrypoint...&quot;   24 minutes ago      Up 24 minutes       0.0.0.0:3306-&gt;3306\/tcp   clever_euler\n8e7374e208e4        php:apache          &quot;docker-php-entryp...&quot;   41 minutes ago      Up 41 minutes       0.0.0.0:80-&gt;80\/tcp       condescending_goldwasser\n<\/code><\/pre>\n<p>\u3053\u3061\u3089\u30821\u30b3\u30de\u30f3\u30c9\u3067MySQL\u30b5\u30fc\u30d0\u30fc\u304c\u7acb\u3061\u4e0a\u304c\u308a\u307e\u3057\u305f\u3002<\/p>\n<div class=\"frame_headding\">\n<h3 style=\"text-align: left;\">\u3053\u308c\u3089\u306e\u30b5\u30fc\u30d0\u30fc\u306f\u4f55\u8005\uff1fDocker Hub\u3068\u306e\u95a2\u4fc2<\/h3>\n<\/div>\n<p>\u5c11\u3057\u8107\u9053\u306b\u9038\u308c\u307e\u3059\u304c\u3001\u30b3\u30f3\u30c6\u30ca\u306e\u4e2d\u8eab\u306b\u8feb\u3063\u3066\u3044\u304d\u307e\u3059\u3002<br \/>1\u30b3\u30de\u30f3\u30c9\u3067\u52d5\u4f5c\u3059\u308b\u3053\u308c\u3089\u306e\u30b5\u30fc\u30d0\u30fc\u306f\u4e00\u4f53\u4f55\u8005\u306a\u306e\u3067\u3057\u3087\u3046\u304b\uff1f<\/p>\n<p>\u4ee5\u964d\u306e\u6d41\u308c\u306f\u30c9\u30c3\u30c8\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3055\u3093\u306e\u52d5\u753b\u304c\u53c2\u8003\u306b\u306a\u308b\u306e\u3067\u3001\u30a4\u30e1\u30fc\u30b8\u306e\u6e67\u304b\u306a\u3044\u7b87\u6240\u304c\u51fa\u3066\u304d\u307e\u3057\u305f\u3089\u3001\u90fd\u5ea6\u53c2\u8003\u306b\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<br \/><a href=\"http:\/\/dotinstall.com\/lessons\/basic_docker\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker\u5165\u9580 &#8211; \u30c9\u30c3\u30c8\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/a><\/p>\n<p><img loading=\"lazy\" src=\"https:\/\/storage.googleapis.com\/sitest-wp\/blog\/wp-content\/uploads\/2017\/02\/4_dockerfile.png\" alt=\"4_dockerfile\" width=\"726\" height=\"454\" class=\"alignnone size-full wp-image-8828\" \/><\/p>\n<p><a href=\"https:\/\/www.docker.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker<\/a>\u306f\u30a4\u30e1\u30fc\u30b8\u3068\u3044\u3046OS\u306e\u96db\u5f62\u3068\u3001\u30a4\u30e1\u30fc\u30b8\u3092\u5b9f\u4f53\u5316\u3057\u305f\u30b3\u30f3\u30c6\u30ca\u306e2\u3064\u3067\u69cb\u6210\u3055\u308c\u3066\u3044\u307e\u3059\u3002<br \/>\u5b9f\u4f53\u5316\u3057\u305f\u30b3\u30f3\u30c6\u30ca\u306f\u3001\u4f55\u6642\u3067\u3082<code>docker commit<\/code>\u30b3\u30de\u30f3\u30c9\u3092\u4f7f\u3063\u3066\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u3092\u53d6\u308b\u304b\u306e\u3088\u3046\u306b\u30a4\u30e1\u30fc\u30b8\u306b\u623b\u3059\u4e8b\u304c\u51fa\u6765\u307e\u3059\u3002<br \/>\u4f8b\u3048\u3070\u30b7\u30b9\u30c6\u30e0\u3092\u69cb\u7bc9\u3059\u308b\u305f\u3081\u306b\u5fc5\u8981\u306a\u4f9d\u5b58\u30e2\u30b8\u30e5\u30fc\u30eb\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u305f\u30b3\u30f3\u30c6\u30ca\u3092<code>docker commit<\/code>\u3067\u518d\u5ea6\u30a4\u30e1\u30fc\u30b8\u306b\u3057\u3066\u914d\u5e03\u3057\u3001\u672c\u756a\u74b0\u5883\u3084\u540c\u50da\u304c\u5229\u7528\u3067\u304d\u307e\u3059\u3002<\/p>\n<p><a href=\"https:\/\/www.docker.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker<\/a>\u306f<a href=\"https:\/\/hub.docker.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker Hub<\/a>\u3068\u3044\u3046\u30db\u30b9\u30c6\u30a3\u30f3\u30b0\u30b5\u30fc\u30d3\u30b9\u3082\u30bb\u30c3\u30c8\u3067\u3059\u3002<br \/>\u30e6\u30fc\u30b6\u30fc\u306f<a href=\"https:\/\/hub.docker.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker Hub<\/a>\u4e0a\u306b\u7121\u6599\u3067\u516c\u958b\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u4f5c\u6210\u3057\u3001\u65b0\u305f\u306b\u30c1\u30e5\u30fc\u30cb\u30f3\u30b0\u3092\u65bd\u3057\u305f\u30a4\u30e1\u30fc\u30b8\u3092\u9810\u3051\u308b\u4e8b\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>\u3057\u304b\u3057\u3001\u624b\u4f5c\u696d\u3067\u30bd\u30d5\u30c8\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u304b\u3089\u300cdocker commit\u300d\u3067\u30a4\u30e1\u30fc\u30b8\u3092\u4f5c\u3063\u3066\u3044\u3066\u306f\u30d6\u30e9\u30c3\u30af\u30dc\u30c3\u30af\u30b9\u306b\u5165\u3063\u305f\u307e\u307e\u3068\u3044\u3046\u554f\u984c\u304c\u6b8b\u308a\u307e\u3059\u3002<br \/>\u3053\u308c\u306e\u5bfe\u5fdc\u7b56\u3068\u3057\u3066\u3001<a href=\"http:\/\/docs.docker.jp\/engine\/reference\/builder.html\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Dockerfile<\/a>\u304c\u7528\u610f\u3055\u308c\u3066\u3044\u307e\u3059\u3002<br \/><a href=\"http:\/\/docs.docker.jp\/engine\/reference\/builder.html\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Dockerfile<\/a>\u3092\u6307\u5b9a\u3057\u3066<code>docker build<\/code>\u30b3\u30de\u30f3\u30c9\u767a\u884c\u3059\u308b\u3068\u3001\u30d7\u30ed\u30d3\u30b8\u30e7\u30cb\u30f3\u30b0\u30c4\u30fc\u30eb\u3067\u69cb\u7bc9\u3059\u308b\u304b\u306e\u5982\u304f\u65b0\u3057\u3044\u30a4\u30e1\u30fc\u30b8\u3092\u751f\u6210\u3059\u308b\u3053\u3068\u304c\u51fa\u6765\u307e\u3059\u3002<\/p>\n<div class=\"frame_headding\">\n<h3 style=\"text-align: left;\">\u4f55\u8005\u304b\u5206\u304b\u3089\u306a\u3044\u30a4\u30e1\u30fc\u30b8\u3092\u4f7f\u3046\u306e\u306f\u6016\u3044\u3001\u898b\u5206\u3051\u65b9\u306f\uff1f<\/h3>\n<\/div>\n<p><a href=\"https:\/\/www.vagrantup.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Vagrant<\/a>\u3067\u306f\u8ab0\u304c\u4f5c\u3063\u305f\u304b\u5206\u304b\u3089\u306a\u3044\u602a\u3057\u3044\u30dc\u30c3\u30af\u30b9\u304c\u96d1\u591a\u306b\u914d\u7f6e\u3055\u308c\u3001\u6016\u304f\u3066\u4f7f\u3048\u306a\u3044\u3068\u3044\u3046\u30e6\u30fc\u30b6\u30fc\u304c\u7d9a\u51fa\u3057\u307e\u3057\u305f\u3002<br \/>(\u305d\u306e\u5f8c\u516c\u5f0f\u30a4\u30e1\u30fc\u30b8\u3092\u30e6\u30fc\u30b6\u30fc\u304c\u898b\u5206\u3051\u3084\u3059\u3044\u3088\u3046\u306b\u6574\u5099\u304c\u9032\u3093\u3067\u3044\u304d\u307e\u3057\u305f)<\/p>\n<p><a href=\"https:\/\/hub.docker.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker Hub<\/a>\u3067\u306f\u3001\u30e6\u30fc\u30b6\u30fc\u304c\u30a2\u30ab\u30a6\u30f3\u30c8\u3092\u958b\u8a2d\u3057\u3066\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u4f5c\u6210\u3057\u305f\u5834\u5408\u3001\u300cgladcube\/php-apahce\u300d\u3068\u3044\u3046\u98a8\u306b\u300c\u30e6\u30fc\u30b6\u30fc\u540d\/\u30a4\u30e1\u30fc\u30b8\u540d\u300d\u3068\u3044\u3046\u5f62\u5f0f\u3067\u767b\u9332\u3055\u308c\u307e\u3059\u3002<br \/>\u516c\u5f0f\u306e\u30a4\u30e1\u30fc\u30b8\u306f\u30e6\u30fc\u30b6\u30fc\u90e8\u5206\u304c\u3042\u308a\u307e\u305b\u3093\u3002<br \/>\u300cphp\u300d\u3084\u300cmysql\u300d\u7b49\u306e\u3088\u3046\u306b\u30ea\u30dd\u30b8\u30c8\u30ea\u540d\u306b\/\u304c\u3042\u308a\u307e\u305b\u3093\u306e\u3067\u3001\u30e6\u30fc\u30b6\u30fc\u306f\u516c\u5f0f\u306e\u30a4\u30e1\u30fc\u30b8\u3092\u7c21\u5358\u306b\u307f\u3064\u3051\u3089\u308c\u307e\u3059\u3002<\/p>\n<div class=\"frame_headding\">\n<h3 style=\"text-align: left;\">PHP\u30b3\u30f3\u30c6\u30ca\u306f\u3053\u3046\u3057\u3066\u4f5c\u3089\u308c\u305f<\/h3>\n<\/div>\n<p>\u305d\u308c\u3067\u306f<a href=\"https:\/\/hub.docker.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker Hub<\/a>\u306b\u3042\u308bPHP\u306e\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u78ba\u8a8d\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<br \/><a href=\"https:\/\/hub.docker.com\/_\/php\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">php &#8211; Docker Hub<\/a><\/p>\n<p>\u753b\u9762\u4e0a\u306e\u65b9\u306b\u5927\u304d\u304fOFFICIAL REPOSITORY\u3068\u66f8\u3044\u3066\u3042\u308a\u307e\u3059\u306d\u3002<br \/>\u3053\u308c\u304c\u516c\u5f0f\u30ea\u30dd\u30b8\u30c8\u30ea\u306e\u8a3c\u3067\u3059\u3002<\/p>\n<p>\u305d\u3057\u3066\u300cFull Description\u300d\u306e\u9805\u76ee\u306b\u306f\u300cSupported tags and respective Dockerfile links\u300d\u3068\u8a18\u8f09\u304c\u3042\u308a\u3002<br \/>\u8a73\u7d30\u8aac\u660e\u306e\u4e0a\u90e8\u3067\u3001\u30b5\u30dd\u30fc\u30c8\u3057\u3066\u3044\u308b\u30bf\u30b0\u3068\u305d\u308c\u305e\u308c\u306e<a href=\"http:\/\/docs.docker.jp\/engine\/reference\/builder.html\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Dockerfile<\/a>\u3092\u7d39\u4ecb\u3057\u3066\u3044\u308b\u4e8b\u304c\u8aad\u307f\u53d6\u308c\u307e\u3059\u3002<\/p>\n<p>\u5404\u7a2e\u30ea\u30dd\u30b8\u30c8\u30ea\u306f\u30a4\u30e1\u30fc\u30b8\u3092\u3069\u306e\u3088\u3046\u306a\u6d41\u308c\u3067\u4f5c\u3063\u305f\u304b\u3092\u516c\u958b\u3059\u308b\u76ee\u7684\u3067\u3001\u5229\u7528\u3057\u305f<a href=\"http:\/\/docs.docker.jp\/engine\/reference\/builder.html\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Dockerfile<\/a>\u3092<a href=\"https:\/\/github.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">GitHub<\/a>\u306e\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u4f7f\u3063\u3066\u516c\u958b\u3059\u308b\u3053\u3068\u304c\u6163\u7fd2\u3068\u306a\u3063\u3066\u3044\u307e\u3059\u3002<br \/>(\u305f\u3060\u3057\u3001\u3053\u308c\u306f\u3042\u304f\u307e\u3067\u81ea\u5df1\u5ba3\u544a\u3067\u3059\u306e\u3067\u516c\u5f0f\u4ee5\u5916\u306e\u30a4\u30e1\u30fc\u30b8\u3092\u5229\u7528\u3059\u308b\u969b\u306f\u6ce8\u610f\u3057\u3066\u304f\u3060\u3055\u3044)<\/p>\n<div class=\"frame_headding\">\n<h3 style=\"text-align: left;\">Dockerfile\u306e\u6d41\u308c\u3092\u8ffd\u3063\u3066\u307f\u3088\u3046<\/h3>\n<\/div>\n<p>\u3067\u306f\u3001\u65e9\u901fPHP(with Apache)\u306eDockerfile\u306e\u6d41\u308c\u3092\u8ffd\u3063\u3066\u3044\u304d\u307e\u3057\u3087\u3046\u3002<br \/><a href=\"https:\/\/github.com\/docker-library\/php\/blob\/738fcd0bdaed0b27e56b4975be94abe2dbe0b0b4\/7.1\/apache\/Dockerfile\" title=\"null\" rel=\"nofollow\" target=\"_blank\">php\/7.1\/apache\/Dockerfile &#8211; GitHub<\/a><\/p>\n<p>\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u5927\u578bDockerfile\u306f\u6163\u308c\u308b\u307e\u3067\u8aad\u307f\u3065\u3089\u3044\u306e\u3067\u3001<br \/>\u79c1\u306e\u65b9\u3067\u629c\u7c8b\u3057\u307e\u3057\u305f\u3002<\/p>\n<pre><code class=\"lang-Bash\"># L.7: Debian\u30a4\u30e1\u30fc\u30b8\u3092\u5229\u7528\u3059\u308b\nFROM debian:jessie\n\n# L.19: \u958b\u767a\u7528\u30e2\u30b8\u30e5\u30fc\u30eb\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\nRUN apt-get update\nRUN apt-get install -y autoconf file g++ gcc libc-dev make pkg-config re2c ca-certificates curl libedit2 libsqlite3-0 libxml2 xz-utils --no-install-recommends\n\n# L.33: Apache\u30e2\u30b8\u30e5\u30fc\u30eb\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\nRUN apt-get install -y apache2-bin apache2.2-common --no-install-recommends\n\n# L.140: PHP\u306e\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9\u3092\u30b3\u30f3\u30c6\u30ca\u5185\u306b\u6ce8\u5165\nCOPY docker-php-source \/usr\/local\/bin\/\n\n# L.158: PHP\u306e\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9\u3092\u30d3\u30eb\u30c9\nRUN .\/configure\nRUN make install\n\n# L.192: \u30b3\u30f3\u30c6\u30ca\u8d77\u52d5\u6642\u3001Apache\u3092\u8d77\u52d5\u3057\u306680\u756a\u30dd\u30fc\u30c8\u3092\u958b\u3051\u308b\nEXPOSE 80\nCMD [&quot;apache2-foreground&quot;]\n<\/code><\/pre>\n<p>\u666e\u6bb5\u6211\u3005\u304cPHP\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u6642\u306f\u30d1\u30c3\u30b1\u30fc\u30b8\u7ba1\u7406\u3092\u5229\u7528\u3059\u308b\u30b1\u30fc\u30b9\u304c\u591a\u3044\u306e\u3067\u3059\u304c\u3001<br \/>\u6ca2\u5c71\u306e\u30d0\u30fc\u30b8\u30e7\u30f3\u3092\u4f5c\u308b\u70ba\u306b\u3042\u3048\u3066\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9\u304b\u3089\u30b3\u30f3\u30d1\u30a4\u30eb\u3057\u3066\u3044\u308b\u306e\u3067\u3059\u306d\u3002<br \/>\u4ed6\u306b\u3082Apache\u306bPHP\u3092\u7d44\u307f\u8fbc\u3080\u3042\u305f\u308a\u306e\u8a18\u8ff0\u3082\u3042\u308a\u307e\u3059\u306e\u3067\u3001\u8208\u5473\u304c\u3042\u308c\u3070\u8aad\u3093\u3067\u307f\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<p>\u4e2d\u3067\u3082\u6ce8\u76ee\u306f7\u884c\u76ee\u306e<code>FROM debian:jessie<\/code>\u3067\u3059\u3002<br \/>\u3053\u308c\u306f\u3069\u306e\u30a4\u30e1\u30fc\u30b8\u3092\u5229\u7528\u3059\u308b\u304b\u304c\u8a18\u8f09\u3055\u308c\u3066\u304a\u308a\u3001DockerHub\u306e\u30ea\u30dd\u30b8\u30c8\u30ea\u540d:\u30bf\u30b0\u3067\u8868\u73fe\u3055\u308c\u3066\u3044\u307e\u3059\u3002<br \/>Debian\u306ejessie\u3068\u3044\u3046\u30b3\u30fc\u30c9\u30cd\u30fc\u30e0\u306f<a href=\"https:\/\/ja.wikipedia.org\/wiki\/Debian\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Wikipedia\u306e\u8a18\u4e8b<\/a>\u306b\u3088\u308b\u3068\u3001\u300cDebian 8.0\uff08\u30b3\u30fc\u30c9\u30cd\u30fc\u30e0: jessie\uff09\u300d\u3068\u8868\u8a18\u3055\u308c\u3066\u304a\u308a\u3001<br \/>\u30d0\u30fc\u30b8\u30e7\u30f38.x\u306e\u6700\u65b0\u7248\u3067\u3042\u308b\u4e8b\u304c\u4f3a\u3048\u307e\u3059\u3002<\/p>\n<p><a href=\"https:\/\/hub.docker.com\/_\/debian\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">debian &#8211; Docker Hub<\/a><br \/>debian\u306e\u30ea\u30dd\u30b8\u30c8\u30ea\u306b\u3082\u300c8.7, 8, jessie, latest (jessie\/Dockerfile)\u300d\u3068\u66f8\u3044\u3066\u3042\u308a\u3001<br \/>jessie\u30bf\u30b0\u306f8\u7cfb\u306e\u6700\u65b0\u30d0\u30fc\u30b8\u30e7\u30f3\u3068\u540c\u5217\u3067\u3042\u308b\u3053\u3068\u304c\u308f\u304b\u308a\u307e\u3059\u3002<\/p>\n<pre><code>FROM scratch\nADD rootfs.tar.xz \/\nCMD [&quot;\/bin\/bash&quot;]\n<\/code><\/pre>\n<p>\u56e0\u307f\u306bdebian:jessie\u306e<a href=\"http:\/\/docs.docker.jp\/engine\/reference\/builder.html\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Dockerfile<\/a>\u306fscratch\u3068\u3044\u3046\u30a4\u30e1\u30fc\u30b8\u3092\u5143\u306b\u4f5c\u3089\u308c\u3066\u3044\u307e\u3059\u3002<br \/>\u3053\u308c\u306f\u4f55\u3082\u30d5\u30a1\u30a4\u30eb\u304c\u5165\u3063\u3066\u306a\u3044\u30d6\u30e9\u30f3\u30af\u306e\u30a4\u30e1\u30fc\u30b8\u3092\u6307\u3057\u3001\u30eb\u30fc\u30c8\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306bOS\u306e\u69cb\u6210\u30d5\u30a1\u30a4\u30eb\u3092\u4e38\u3054\u3068\u683c\u7d0d\u3059\u308b\u4f5c\u308a\u306b\u306a\u3063\u3066\u3044\u308b\u3088\u3046\u3067\u3059\u3002<\/p>\n<div class=\"frame_headding\">\n<h3 style=\"text-align: left;\">PHP\u30a4\u30e1\u30fc\u30b8\u3092\u8abf\u6574\u3057\u3066LAMP\u4ed5\u69d8\u306b\u5909\u66f4<\/h3>\n<\/div>\n<p>\u3055\u3066\u3001\u6674\u308c\u3066<a href=\"https:\/\/www-jp.mysql.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">MySQL<\/a>\u306e\u30b3\u30f3\u30c6\u30ca\u3068Web\u30b5\u30fc\u30d0\u306e\u30b3\u30f3\u30c6\u30ca\u3092\u7acb\u3061\u4e0a\u3052\u308b\u4e8b\u304c\u51fa\u6765\u307e\u3057\u305f\u3002<br \/>\u65e9\u901f<a href=\"http:\/\/php.net\/manual\/ja\/class.pdo.php\" title=\"null\" rel=\"nofollow\" target=\"_blank\">PDO<\/a>\u30e2\u30b8\u30e5\u30fc\u30eb\u3092\u5229\u7528\u3057\u3066<a href=\"https:\/\/www-jp.mysql.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">MySQL<\/a>\u306b\u63a5\u7d9a\u3057\u3066\u3044\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n<pre><code class=\"lang-Bash\">$ cat &lt;&lt; EOF &gt; initialize.php\n&lt;?php\n$user = &#39;root&#39;;\n$pass = &#39;test&#39;;\n$dbh = new PDO(&#39;mysql:host=localhost;&#39;, $user, $pass);\n$dbh-&gt;query(&quot;create database hogehoge&quot;);\n$dbh-&gt;query(&quot;use hogehoge&quot;);\n$dbh-&gt;query(&quot;create table users(id int, name text)&quot;);\nEOF\n\n$ curl localhost\/initialize.php\n&lt;br \/&gt;\n&lt;b&gt;Fatal error&lt;\/b&gt;:  Uncaught PDOException: could not find driver in \/var\/www\/html\/initialize.php:4\nStack trace:\n#0 \/var\/www\/html\/initialize.php(4): PDO-&amp;gt;__construct(&#39;mysql:host=loca...&#39;, &#39;root&#39;, &#39;test&#39;)\n#1 {main}\n  thrown in &lt;b&gt;\/var\/www\/html\/initialize.php&lt;\/b&gt; on line &lt;b&gt;4&lt;\/b&gt;&lt;br \/&gt;\n<\/code><\/pre>\n<p>\u6b8b\u5ff5\u3001\u30a8\u30e9\u30fc\u304c\u5e30\u3063\u3066\u304d\u307e\u3057\u305f\u3002<br \/>\u516c\u5f0f\u306ePHP\u30a4\u30e1\u30fc\u30b8\u306f\u6700\u5c0f\u9650\u306e\u30e2\u30b8\u30e5\u30fc\u30eb\u3060\u3051\u7d44\u307f\u8fbc\u307e\u308c\u3066\u3044\u307e\u3059\u3002<br \/>\u300c<a href=\"https:\/\/hub.docker.com\/_\/php\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">PHP\u30ea\u30dd\u30b8\u30c8\u30ea\u306e\u8a73\u7d30\u8aac\u660e<\/a>\u300d\u306b\u306f\u300cPHP Core Extensions\u300d\u3068\u3044\u3046\u9805\u76ee\u304c\u7528\u610f\u3055\u308c\u3066\u304a\u308a\u3001iconv\u3084mcrypt\u7b49\u306e\u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u76db\u308a\u8fbc\u3080\u8a2d\u5b9a\u4f8b\u304c\u8a18\u8f09\u3055\u308c\u3066\u3044\u307e\u3059\u3002<br \/>\u307e\u305f\u3001\u4e0b\u8a18\u306e\u3088\u3046\u306a\u8a18\u4e8b\u3067\u3082\u7d39\u4ecb\u3055\u308c\u3066\u304a\u308a\u3001\u4e01\u5ea6Docker\u3067LAMP\u74b0\u5883\u3092\u69cb\u7bc9\u3059\u308b\u70ba\u306b\u8a2d\u5b9a\u304c\u66f8\u304b\u308c\u3066\u3044\u307e\u3059\u306e\u3067\u8a2d\u5b9a\u5185\u5bb9\u3092\u304a\u501f\u308a\u3057\u307e\u3057\u305f\u3002<br \/><a href=\"http:\/\/qiita.com\/naga3\/items\/be1a062075db9339762d\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker Hub\u306e\u30aa\u30d5\u30a3\u30b7\u30e3\u30eb\u30a4\u30e1\u30fc\u30b8\u3092\u4f7f\u3063\u305fLAMP\u74b0\u5883(Apache+PHP+MySQL)\u69cb\u7bc9 &#8211; Qiita<\/a><\/p>\n<pre><code class=\"lang-Bash\">$ cat &lt;&lt; EOF &gt; Dockerfile\nFROM php:apache\nRUN docker-php-ext-install pdo_mysql mysqli mbstring\nEOF\n\n$ docker build -t myphp .\n\n$ docker images\nREPOSITORY          TAG                 IMAGE ID            CREATED             SIZE\nmyphp               latest              3efc7867dc9f        2 minutes ago      391 MB\nphp                 apache              a05317fca519        6 days ago          389 MB\nmysql               latest              7666f75adb6b        4 weeks ago         406 MB\n\n$ docker run -d -p &quot;80:80&quot; -v &quot;$PWD\/public:\/var\/www\/html&quot; myphp\n5a8971798f1adc01fda296c711b86b152a1af7f53e52766999601a4c20a34dc0\n\n$ curl localhost\/initialize.php\n&lt;br \/&gt;\n&lt;b&gt;Fatal error&lt;\/b&gt;:  Uncaught PDOException: SQLSTATE[HY000] [2002] No such file or directory in \/var\/www\/html\/initialize.php:4\nStack trace:\n#0 \/var\/www\/html\/initialize.php(4): PDO-&amp;gt;__construct(&#39;mysql:host=loca...&#39;, &#39;root&#39;, &#39;test&#39;)\n#1 {main}\n  thrown in &lt;b&gt;\/var\/www\/html\/initialize.php&lt;\/b&gt; on line &lt;b&gt;4&lt;\/b&gt;&lt;br \/&gt;\n<\/code><\/pre>\n<p>\u307e\u3060\u30a8\u30e9\u30fc\u304c\u51fa\u307e\u3059\u3002<br \/>\u3053\u308c\u306fPHP\u306e\u4e57\u3063\u3066\u3044\u308bApache\u30b5\u30fc\u30d0\u30fc\u304b\u3089MySQL\u306e\u30b5\u30fc\u30d0\u30fc\u304c\u898b\u3048\u3066\u3044\u306a\u3044\u4e8b\u304c\u539f\u56e0\u3067\u3059\u3002<br \/>\u6b21\u306e\u7ae0\u3067\u306f\u305d\u308c\u305e\u308c\u306e\u30b5\u30fc\u30d0\u30fc\u3092\u7d10\u4ed8\u3051\u308b\u8a2d\u5b9a\u3092\u7d39\u4ecb\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<div class=\"frame_headding\">\n<h3 style=\"text-align: left;\">MySQL\u30b5\u30fc\u30d0\u30fc\u3068PHP\u30b5\u30fc\u30d0\u30fc\u3092\u63a5\u7d9a\u3059\u308b<\/h3>\n<\/div>\n<p>\u7acb\u3061\u4e0a\u3052\u305f\u30b3\u30f3\u30c6\u30ca\u540c\u58eb\u306f\u7570\u306a\u308b\u4eee\u60f3\u30de\u30b7\u30f3\u3068\u3044\u3046\u6271\u3044\u306b\u306a\u308a\u3001<br \/>\u5404\u3005\u306e\u4eee\u60f3\u30de\u30b7\u30f3\u306b\u306f\u7570\u306a\u308bIP\u30a2\u30c9\u30ec\u30b9\u304c\u5272\u308a\u632f\u3089\u308c\u307e\u3059\u3002<br \/>(IP\u30a2\u30c9\u30ec\u30b9\u306e\u78ba\u8a8d\u30b3\u30de\u30f3\u30c9\u306f<a href=\"http:\/\/deeeet.com\/writing\/2014\/05\/11\/docker-network\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u57fa\u790e &#8211; SOTA<\/a>\u3092\u53c2\u8003\u306b\u3055\u305b\u3066\u9802\u304d\u307e\u3057\u305f)<\/p>\n<pre><code class=\"lang-Bash\">$ docker ps\nCONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS              PORTS                    NAMES\ne5b3f76eb6f3        mysql:latest        &quot;docker-entrypoint...&quot;   2 days ago          Up 2 days           0.0.0.0:3306-&gt;3306\/tcp   ecstatic_boyd\n5a8971798f1a        myphp               &quot;docker-php-entryp...&quot;   2 days ago          Up 2 days           0.0.0.0:80-&gt;80\/tcp       condescending_goldwasser\n\n$ docker inspect --format &#39;{{ .NetworkSettings.IPAddress }}&#39; e5b3f76eb6f3\n172.17.0.3\n\n$ docker inspect --format &#39;{{ .NetworkSettings.IPAddress }}&#39; 5a8971798f1a\n172.17.0.2\n<\/code><\/pre>\n<p><code>docker run<\/code>\u306b\u306flink\u3068\u3044\u3046\u30aa\u30d7\u30b7\u30e7\u30f3\u304c\u5b58\u5728\u3057\u307e\u3059\u3002<br \/>link\u30aa\u30d7\u30b7\u30e7\u30f3\u3092\u6307\u5b9a\u3057\u3066\u7acb\u3061\u4e0a\u3052\u308b\u3068\u3001\u305d\u306e\u5bfe\u8c61\u306e\u30de\u30b7\u30f3\u306eIP\u30a2\u30c9\u30ec\u30b9\u304c\/etc\/hosts\u30d5\u30a1\u30a4\u30eb\u306b\u66f8\u304d\u8fbc\u307e\u308c\u307e\u3059\u3002<br \/>\u3053\u3046\u3057\u3066\u4ed6\u306e\u30b3\u30f3\u30c6\u30ca\u306b\u30ea\u30f3\u30af\u540d\u3092\u3059\u308b\u3053\u3068\u3067\u63a5\u7d9a\u3067\u304d\u307e\u3059\u3002<br \/>\u65e9\u901f\u63a5\u7d9a\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<pre><code class=\"lang-Bash\">$ docker ps\nCONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS              PORTS                    NAMES\ne5b3f76eb6f3        mysql:latest        &quot;docker-entrypoint...&quot;   2 days ago          Up 2 days           0.0.0.0:3306-&gt;3306\/tcp   ecstatic_boyd\n5a8971798f1a        myphp               &quot;docker-php-entryp...&quot;   2 days ago          Up 2 days           0.0.0.0:80-&gt;80\/tcp       condescending_goldwasser\n\n\/\/ \u4e00\u5ea6php\u30b3\u30f3\u30c6\u30ca\u306f\u524a\u9664\n$ docker rm -f 5a8971798f1a\n5a8971798f1a\n\n$ docker run -d -p &quot;80:80&quot; -v &quot;$PWD\/public:\/var\/www\/html&quot; --link ecstatic_boyd:mysql myphp\nb79bd2724e7f186fd9a57e5757bdf9285787b8bdf6ee673ade0fec98cee9df4c\n\n$ docker ps\nCONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS              PORTS                    NAMES\nb79bd2724e7f        myphp               &quot;docker-php-entryp...&quot;   19 minutes ago      Up 19 minutes       0.0.0.0:80-&gt;80\/tcp       wizardly_goldwasser\ne5b3f76eb6f3        mysql:latest        &quot;docker-entrypoint...&quot;   3 days ago          Up 3 days           0.0.0.0:3306-&gt;3306\/tcp   ecstatic_boyd\n\n$ docker exec b79bd2724e7f cat \/etc\/hosts | grep mysql\n172.17.0.3    mysql e5b3f76eb6f3 ecstatic_boyd\n\n$ cat &lt;&lt; EOF &gt; initialize.php\n&lt;?php\n$user = &#39;root&#39;;\n$pass = &#39;test&#39;;\n$dbh = new PDO(&#39;mysql:host=mysql;&#39;, $user, $pass);\n$dbh-&gt;query(&quot;create database hogehoge&quot;);\n$dbh-&gt;query(&quot;use hogehoge&quot;);\n$dbh-&gt;query(&quot;create table users(id int, name text)&quot;);\n\n$result = $dbh-&gt;query(&quot;show create table users;&quot;);\nvar_dump($result);\nEOF\n\n$ curl localhost\/initialize.php\nobject(PDOStatement)#2 (1) {\n  [&quot;queryString&quot;]=&gt;\n  string(24) &quot;show create table users;&quot;\n}\n<\/code><\/pre>\n<p>\u304a\u304a\u3001\u9042\u306bPHP\u3068MySQL\u304c\u7e4b\u304c\u308a\u307e\u3057\u305f\u306d\uff01<br \/>\u6982\u5ff5\u306f\u8907\u96d1\u3067\u3059\u304c\u3001\u6163\u308c\u3066\u3057\u307e\u3048\u3070\u6b86\u3069\u30b3\u30fc\u30c9\u3082\u30b3\u30de\u30f3\u30c9\u3082\u6700\u5c0f\u9650\u306b\u30b5\u30fc\u30d0\u30fc\u306e\u5b9a\u7fa9\u304c\u66f8\u3051\u3066\u3057\u307e\u3044\u307e\u3059\u3002<\/p>\n<div class=\"frame_headding\">\n<h3 style=\"text-align: left;\">Docker Compose\u3092\u6d3b\u7528\u3057\u30661\u30b3\u30de\u30f3\u30c9\u904b\u7528\u3092\u5b9f\u73fe\u3059\u308b<\/h3>\n<\/div>\n<p>1\u30b3\u30de\u30f3\u30c9\u3067\u7c21\u5358\u306b\u30b5\u30fc\u30d0\u30fc\u304c\u7acb\u3061\u4e0a\u304c\u308b\u3068\u306f\u3044\u3048run\u30b3\u30de\u30f3\u30c9\u9577\u3059\u304e\u3067\u3059\u306d\u3002<br \/>Shell Script\u306b\u3067\u3082\u307e\u3068\u3081\u3066\u2026\u2026\u3068\u3044\u3046\u306e\u306f\u3061\u3087\u3063\u3068\u5f85\u3063\u3066\u4e0b\u3055\u3044\u3002<br \/>\u516c\u5f0f\u304c<a href=\"https:\/\/docs.docker.com\/compose\/overview\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker Compose<\/a>\u3068\u3044\u3046\u30aa\u30fc\u30b1\u30b9\u30c8\u30ec\u30fc\u30b7\u30e7\u30f3\u30c4\u30fc\u30eb\u3092\u7528\u610f\u3057\u3066\u304f\u3060\u3055\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u305d\u306e<a href=\"https:\/\/docs.docker.com\/compose\/install\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u65b9\u6cd5<\/a>\u3082\u516c\u958b\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<pre><code class=\"lang-Bash\">\/\/ \u30d1\u30b9\u306e\u901a\u3063\u3066\u3044\u308b\u30d5\u30a9\u30eb\u30c0\u306b\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u307e\u3059\u3002\n$ curl -L &quot;https:\/\/github.com\/docker\/compose\/releases\/download\/1.11.1\/docker-compose-$(uname -s)-$(uname -m)&quot; -o \/usr\/local\/bin\/docker-compose\n\n\/\/ \u5b9f\u884c\u6a29\u9650\u3092\u4ed8\u4e0e\n$ chmod +x \/usr\/local\/bin\/docker-compose\n\n$ docker-compose --version\ndocker-compose version 1.11.1, build 7c5d5e4\n<\/code><\/pre>\n<p><a href=\"https:\/\/docs.docker.com\/compose\/overview\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker Compose<\/a>\u306f<a href=\"https:\/\/www.docker.com\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker<\/a>\u30b3\u30de\u30f3\u30c9\u3092\u30e9\u30c3\u30d4\u30f3\u30b0\u3057\u3066\u3044\u308b\u3060\u3051\u3067\u3059\u306e\u3067\u3001<br \/>Docker for xxx\u304b\u3089\u3067\u3082\u3001Docker\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u305fLinux\u30de\u30b7\u30f3\u3067\u3082\u540c\u69d8\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u65b9\u6cd5\u3067\u5c0e\u5165\u3067\u304d\u307e\u3059\u3002<\/p>\n<p><a href=\"https:\/\/docs.docker.com\/compose\/overview\/\" title=\"null\" rel=\"nofollow\" target=\"_blank\">Docker Compose<\/a>\u30b3\u30de\u30f3\u30c9\u306f\u30ab\u30ec\u30f3\u30c8\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306bdocker-compose.yml\u30d5\u30a1\u30a4\u30eb\u304c\u5b58\u5728\u3059\u308b\u3068\u4f7f\u7528\u3067\u304d\u307e\u3059\u3002<\/p>\n<pre><code class=\"lang-Bash\">\/\/ \u524d\u7ae0\u306e2\u3064\u306e\u30b3\u30f3\u30c6\u30ca\u306f\u524a\u9664\n$ docker rm -f b79bd2724e7f e5b3f76eb6f3\nb79bd2724e7f\ne5b3f76eb6f3\n\n$ cat &lt;&lt; EOF &gt; docker-compose.yml\nversion: &quot;2&quot;\nservices:\n  web:\n    build: .\n    container_name: web\n    image: myphp\n    ports:\n      - &quot;80:80&quot;\n    links:\n      - mysql\n    volumes:\n      - .:\/var\/www\/html\n    restart: always\n  mysql:\n    container_name: mysql\n    image: mysql\n    environment:\n      MYSQL_ROOT_PASSWORD: test\n    ports:\n      - &quot;3306:3306&quot;\n    restart: always\nEOF\n\n$ docker-compose up -d\nCreating mysql\nCreating web\n\n$ docker-compose ps\nName               Command               State           Ports\n-----------------------------------------------------------------------\nmysql   docker-entrypoint.sh mysqld      Up      0.0.0.0:3306-&gt;3306\/tcp\nweb     docker-php-entrypoint apac ...   Up      0.0.0.0:80-&gt;80\/tcp\n<\/code><\/pre>\n<p>docker-compose.yml\u306e\u66f8\u304d\u65b9\u306f\u6700\u521d\u306f\u3068\u3063\u3064\u304d\u306b\u304f\u3044\u3067\u3059\u304c\u3001<br \/><code>docker run<\/code>\u30b3\u30de\u30f3\u30c9\u306e\u30aa\u30d7\u30b7\u30e7\u30f3\u306e\u5b9a\u7fa9\u304c\u6b86\u3069\u4f7f\u3048\u307e\u3059\u306e\u3067\u7c21\u5358\u306b\u8a18\u8ff0\u3067\u304d\u307e\u3059\u3002<\/p>\n<div class=\"frame_headding\">\n<h3 style=\"text-align: left;\">\u30b3\u30de\u30f3\u30c9\u3092\u30b7\u30f3\u30d7\u30eb\u306b\u307e\u3068\u3081\u308b<\/h3>\n<\/div>\n<p>docker-compose\u30b3\u30de\u30f3\u30c9\u306b\u6163\u308c\u3066\u3057\u307e\u3048\u3070\u4e0a\u8a18\u30671\u30b3\u30de\u30f3\u30c9\u9054\u6210\u3068\u8a00\u3063\u3066\u3082\u826f\u3044\u304b\u3082\u3057\u308c\u307e\u305b\u3093\u3002<br \/>\u3057\u304b\u3057\u3001\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306b\u306fDocker\u306b\u8a73\u3057\u304f\u306a\u3044\u30e1\u30f3\u30d0\u30fc\u304c\u5c45\u308b\u53ef\u80fd\u6027\u3082\u3042\u308a\u307e\u3059\u306e\u3067\u3001<br \/>\u983b\u51fa\u306e\u30b3\u30de\u30f3\u30c9\u3092\u30c6\u30ad\u30b9\u30c8\u30d5\u30a1\u30a4\u30eb\u3067\u6b8b\u3059\u4e8b\u306b\u3057\u307e\u3057\u305f\u3002<\/p>\n<pre><code class=\"lang-Bash\">$ mkdir bin\n\n$ cat &lt;&lt; EOF &gt; bin\/start\n#!\/bin\/bash\nscript_dir=&quot;$(cd &quot;$(dirname &quot;${BASH_SOURCE:-${(%):-%N}}&quot;)&quot;; pwd)&quot;\ncd &quot;$script_dir\/..\/&quot;\n\ndocker-compose up -d\nEOF\n\n$ chmod +x bin\/*\n\n$ bin\/start\nCreating mysql\nCreating web\n<\/code><\/pre>\n<p>\u3053\u308c\u3067\u65b0\u3057\u304f\u53c2\u5165\u3057\u3066\u304d\u305f\u30e1\u30f3\u30d0\u30fc\u306b\u3082\u7c21\u5358\u306b1\u30b3\u30de\u30f3\u30c9\u3067\u30b5\u30fc\u30d0\u30fc\u3092\u8d77\u52d5\u3059\u308b\u3053\u3068\u304c\u51fa\u6765\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002<br \/>\u65b0\u3057\u304f\u30b8\u30e7\u30a4\u30f3\u3057\u305f\u30e1\u30f3\u30d0\u30fc\u306b\u306f\u3001bin\u914d\u4e0b\u306e\u30b7\u30a7\u30eb\u30b9\u30af\u30ea\u30d7\u30c8\u8aad\u3080\u3088\u3046\u306b\u4f1d\u3048\u308c\u3070\u3059\u3050\u306b\u7406\u89e3\u51fa\u6765\u308b\u304b\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<p>\u4eca\u56de\u306fadd\u30b3\u30de\u30f3\u30c9\u306e\u307f\u4f5c\u6210\u3057\u307e\u3057\u305f\u304c\u3001<br \/>\u5e7e\u3064\u304b\u306e\u983b\u51fa\u30b3\u30de\u30f3\u30c9\u3092\u307e\u3068\u3081\u3066<a href=\"https:\/\/github.com\/m-ohata\/example-docker-lamp\" title=\"null\" rel=\"nofollow\" target=\"_blank\">\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3068\u3057\u3066\u516c\u958b<\/a>\u3057\u307e\u3057\u305f\u3002<br \/>(\u307e\u305f\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3068\u3057\u3066\u6a5f\u80fd\u3057\u6613\u3044\u3088\u3046\u306b\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u5206\u3051\u3082\u884c\u3044\u307e\u3057\u305f)<\/p>\n<p>\u7c21\u5358\u306a\u30b3\u30fc\u30c9\u3070\u304b\u308a\u3067\u3059\u306e\u3067\u662f\u975e\u4e00\u5ea6\u8aad\u3093\u3067\u307f\u3066\u4e0b\u3055\u3044\u3002<\/p>\n<div class=\"frame_headding\">\n<h3 style=\"text-align: left;\">\u307e\u3068\u3081<\/h3>\n<\/div>\n<p>\u3044\u304b\u304c\u3067\u3057\u305f\u3067\u3057\u3087\u3046\u304b\uff1f<\/p>\n<p>\u3064\u3044\u306b\u76ee\u6a19\u3067\u3042\u3063\u305f1\u30b3\u30de\u30f3\u30c9\u3067\u74b0\u5883\u69cb\u7bc9\u3092\u5b9f\u73fe\u3059\u308b\u3053\u3068\u304c\u51fa\u6765\u307e\u3057\u305f\u3002<br \/>\u3082\u3061\u308d\u3093\u3053\u308c\u3067\u5168\u3066\u304c\u89e3\u6c7a\u3057\u305f\u8a33\u3067\u306f\u3042\u308a\u307e\u305b\u3093\u3002<br \/>\u30c7\u30d7\u30ed\u30a4\u3059\u308b\u30d5\u30ed\u30fc\u3092\u8003\u3048\u305f\u308a\u3001\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3084\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9\u306e\u7ba1\u7406\u3057\u3066\u3044\u304f\u306b\u306f\u69d8\u3005\u306a\u6280\u8853\u3068\u306e\u7d44\u307f\u5408\u308f\u305b\u304c\u5fc5\u8981\u306b\u306a\u3063\u3066\u3044\u304f\u3053\u3068\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<p>\u305d\u306e\u4e0a\u3067\u3001\u958b\u767a\u74b0\u5883\u69cb\u7bc9\u3068\u3044\u30461\u5206\u91ce\u306b\u65bc\u3044\u3066\u5c11\u3057\u3067\u3082\u53c2\u8003\u306b\u306a\u308c\u3070\u5e78\u3044\u3067\u3059\u3002<br \/>\u3082\u3057\u826f\u3051\u308c\u3070\u3053\u306e\u65b9\u6cd5\u306b\u3042\u306a\u305f\u306e\u30a2\u30a4\u30c7\u30a2\u3092\u76db\u308a\u8fbc\u3093\u3067\u3044\u305f\u3060\u304d\u3001<br \/>\u3055\u3089\u306b\u30af\u30fc\u30eb\u306a\u958b\u767a\u74b0\u5883\u3092\u69cb\u7bc9\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<p>\u4ee5\u4e0a\u3001\u300c1\u30b3\u30de\u30f3\u30c9\u3067\u4f5c\u3063\u305f\u3002Docker\u3067\u958b\u767a\u74b0\u5883\u3092\u69cb\u7bc9\u3059\u308b\u65b9\u6cd5\u300d\u3067\u3057\u305f\u3002<br \/>\u6700\u5f8c\u307e\u3067\u8aad\u3093\u3067\u3044\u305f\u3060\u304d\u3042\u308a\u304c\u3068\u3046\u3054\u3056\u3044\u307e\u3057\u305f\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6700\u7d42\u7684\u306b\u305f\u3063\u305f1\u30b3\u30de\u30f3\u30c9\u3067\u958b\u767a\u74b0\u5883\u3092\u4f5c\u308a\u4e0a\u3052\u3066\u3057\u307e\u3046\u4e8b\u3092\u30b4\u30fc\u30eb\u306b\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u4f5c\u6210\u3057\u3066\u3044\u304d\u307e\u3059\u3002 \u524d\u56de\u306e\u8a18\u4e8b\u3067\u306fVagrant\u3068Docker\u306e\u9055\u3044\u306b\u95a2\u3057\u3066\u958b\u8a2d\u3057\u307e\u3057\u305f\u304c\u3001\u5b9f\u969b\u306bLAMP\u30b5\u30fc\u30d0\u30fc\u30921\u30b3\u30de\u30f3\u30c9\u3067\u7acb\u3061\u4e0a\u3052\u3066\u884c\u304d\u305f\u3044\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n","protected":false},"author":1,"featured_media":8827,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[27],"tags":[],"acf":false,"_links":{"self":[{"href":"https:\/\/sitest.jp\/blog\/wp-json\/wp\/v2\/posts\/8823"}],"collection":[{"href":"https:\/\/sitest.jp\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/sitest.jp\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/sitest.jp\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/sitest.jp\/blog\/wp-json\/wp\/v2\/comments?post=8823"}],"version-history":[{"count":4,"href":"https:\/\/sitest.jp\/blog\/wp-json\/wp\/v2\/posts\/8823\/revisions"}],"predecessor-version":[{"id":8864,"href":"https:\/\/sitest.jp\/blog\/wp-json\/wp\/v2\/posts\/8823\/revisions\/8864"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/sitest.jp\/blog\/wp-json\/wp\/v2\/media\/8827"}],"wp:attachment":[{"href":"https:\/\/sitest.jp\/blog\/wp-json\/wp\/v2\/media?parent=8823"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/sitest.jp\/blog\/wp-json\/wp\/v2\/categories?post=8823"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/sitest.jp\/blog\/wp-json\/wp\/v2\/tags?post=8823"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}