{"id":3580,"date":"2016-03-14T08:20:10","date_gmt":"2016-03-13T23:20:10","guid":{"rendered":"https:\/\/160.16.84.155\/wordpress\/?p=3580"},"modified":"2016-03-13T12:10:39","modified_gmt":"2016-03-13T03:10:39","slug":"public%e3%83%87%e3%82%a3%e3%83%ac%e3%82%af%e3%83%88%e3%83%aa%e3%82%92alias%e3%81%a7%e6%8c%87%e5%ae%9a","status":"publish","type":"post","link":"https:\/\/ephemeral-arcadia.jp\/passo_wp\/2016\/03\/public%e3%83%87%e3%82%a3%e3%83%ac%e3%82%af%e3%83%88%e3%83%aa%e3%82%92alias%e3%81%a7%e6%8c%87%e5%ae%9a.html","title":{"rendered":"public\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092Alias\u3067\u6307\u5b9a"},"content":{"rendered":"<p>Laravel\u306f\u3001\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u305f\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306e\u4e2d\u306e<strong>public<\/strong>\u304c\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8\u30eb\u30fc\u30c8\u306b\u306a\u308a\u307e\u3059\u3002<br \/>\nApache\u3067\u3042\u308c\u3070\u3001conf\u30d5\u30a1\u30a4\u30eb\u306e\u4e2d\u3067<strong>DocumentRoot<\/strong>\u30c7\u30a3\u30ec\u30af\u30c6\u30a3\u30d6\u3092\u4f7f\u3063\u3066public\u3092\u6307\u5b9a\u3059\u308b\u3053\u3068\u306b\u306a\u308b\u304b\u3068\u601d\u3044\u307e\u3059\u3002<br \/>\n\u3057\u304b\u3057\u3001\u65e2\u306b\u5225\u306e\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092DocumentRoot\u306b\u6307\u5b9a\u3057\u3066\u3044\u308b\u5834\u5408\u306f\u3069\u3046\u3057\u305f\u3089\u3044\u3044\u306e\u3067\u3057\u3087\u3046\u3002<\/p>\n<p>\u3046\u3061\u306eVPS\u304c\u6b63\u306b\u305d\u306e\u72b6\u6cc1\u3067\u3059\u3002(^^;)<br \/>\nWordPress\u304c\u52d5\u3044\u3066\u3044\u308b\u3057\u3001ownCloud\u304c\u52d5\u3044\u3066\u3044\u308b\u3057\u3001\u4ed6\u306b\u3082\u3044\u308d\u3044\u308d\u3068\u30e6\u30fc\u30c6\u30a3\u30ea\u30c6\u30a3\u7684\u306a\u3082\u306e\u304c\u52d5\u3044\u3066\u3044\u308b\u3057\u3001\u4eca\u66f4DocumentRoot\u3092\u5909\u3048\u308b\u308f\u3051\u306b\u306f\u3044\u304d\u307e\u305b\u3093\u3002<br \/>\nLaravel\u306epublic\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092DocumentRoot\u306e\u4e2d\u306b\u79fb\u52d5\u3059\u308b\u3068\u3044\u3046\u65b9\u6cd5\u3082\u3042\u308b\u3089\u3057\u3044\u306e\u3067\u3059\u304c\u3001\u305d\u3046\u3059\u308b\u3068index.php\u306e\u4e2d\u306b\u30cf\u30fc\u30c9\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u3055\u308c\u3066\u3044\u308b<strong>autoload.php<\/strong>\u306e\u30d1\u30b9\u304c\u305a\u308c\u3066\u3057\u307e\u3046\u308f\u3051\u3067\u2026\u3002<br \/>\nLaravel\u306e\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u69cb\u9020\u3092\u5f04\u3089\u305a\u306b\u3069\u3046\u306b\u304b\u3067\u304d\u306a\u3044\u3082\u306e\u304b\u3002<\/p>\n<p>Laravel\u304c\u5f04\u308c\u306a\u3044\u306a\u3089Apache\u3092\u5f04\u308c\u3070\u3044\u3044\u3058\u3083\u306a\u3044\u3002(^^)<br \/>\n\u4f8b\u3048\u3070\u3001\u300chogehoge.com\u300d\u306b\u30a2\u30af\u30bb\u30b9\u3057\u305f\u5834\u5408\u3001\u73fe\u72b6\u3067\u306fDocumentRoot\u3067\u6307\u5b9a\u3055\u308c\u305f\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306eindex.html\u306a\u308aindex.php\u306a\u308a\u304c\u8868\u793a\u3055\u308c\u308b\u304b\u3068\u601d\u3044\u307e\u3059\u3002<br \/>\n\u305d\u3046\u3044\u3046\u74b0\u5883\u306b\u304a\u3044\u3066\u3001<br \/>\nhogehoge.com\/laravel<br \/>\n\u2191\u3053\u3093\u306a\u611f\u3058\u3067Laravel\u306epublic\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306b\u30a2\u30af\u30bb\u30b9\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u307e\u3059\u3002<\/p>\n<p>\u307e\u305a\u306f<strong>conf<\/strong>\u30d5\u30a1\u30a4\u30eb\u3002<br \/>\n\/etc\/httpd\/conf.d\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306e\u4e2d\u306b\u5206\u304b\u308a\u3084\u3059\u3044\u540d\u524d\u3067conf\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u308a\u307e\u3059\u3002<br \/>\n(\u4eca\u56de\u306flaravel.conf\u306b\u3057\u3066\u307f\u307e\u3057\u305f)<\/p>\n<pre class=\"lang:apache decode:true\" title=\"laravel.conf\">Alias \/laravel \"\/var\/www\/laravel\/public\"\r\n&lt;Directory \"\/var\/www\/laravel\/public\"&gt;\r\n    Options +FollowSymLinks\r\n    AllowOverride All\r\n\r\n    &lt;IfModule mod_dav.c&gt;\r\n        Dav off\r\n    &lt;\/IfModule&gt;\r\n&lt;\/Directory&gt;\r\n<\/pre>\n<p>URL\u306e\u304a\u5c3b\u3068Alias\u306e\u90e8\u5206\u3092\u540c\u3058\u306b\u3057\u307e\u3059\u3002<br \/>\n\/var\/www\u301c\u306e\u90e8\u5206\u306fLaravel\u306epublic\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092\u30d5\u30eb\u30d1\u30b9\u3067\u8a18\u8ff0\u3057\u307e\u3059\u3002<br \/>\nDirectory\u30c7\u30a3\u30ec\u30af\u30c6\u30a3\u30d6\u3082\u540c\u69d8\u306b\u2026\u3002<\/p>\n<p>\u6b21\u306bpublic\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306e<strong>.htaccess<\/strong>\u3067\u3059\u3002<\/p>\n<pre class=\"lang:apache decode:true\" title=\".htaccess\">&lt;IfModule mod_rewrite.c&gt;\r\n    &lt;IfModule mod_negotiation.c&gt;\r\n        Options -MultiViews\r\n    &lt;\/IfModule&gt;\r\n\r\n    RewriteEngine On\r\n\r\n    # Redirect Trailing Slashes...\r\n    RewriteRule ^(.*)\/$ \/laravel\/$1 [L,R=301]\r\n\r\n    RewriteBase \/laravel\r\n    # Handle Front Controller...\r\n    RewriteCond %{REQUEST_FILENAME} !-d\r\n    RewriteCond %{REQUEST_FILENAME} !-f\r\n    RewriteRule ^ index.php [L]\r\n&lt;\/IfModule&gt;<\/pre>\n<p>\u30c8\u30ec\u30a4\u30ea\u30f3\u30b0\u30b9\u30e9\u30c3\u30b7\u30e5\u306e\u51e6\u7406\u90e8\u5206\u306eRewriteRule\u3068\u305d\u306e\u4e0b\u306eRewriteBase\u306b\u3001Alias\u3068\u540c\u3058\u3082\u306e\u3092\u8a18\u8ff0\u3057\u307e\u3059\u3002<\/p>\n<p>\u3042\u3068\u306fApache\u3092restart\u3068\u304bgraceful\u3059\u308c\u3070\u3001hogehoge.com\/laravel\u3067\u30a6\u30a7\u30eb\u30ab\u30e0\u30da\u30fc\u30b8\u304c\u8868\u793a\u3055\u308c\u308b\u306f\u305a\u3067\u3059\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Laravel\u306f\u3001\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u305f\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306e\u4e2d\u306epublic\u304c\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8\u30eb\u30fc\u30c8\u306b\u306a\u308a\u307e\u3059\u3002 Apache\u3067\u3042\u308c\u3070\u3001conf\u30d5\u30a1\u30a4\u30eb\u306e\u4e2d\u3067DocumentRoot\u30c7\u30a3\u30ec\u30af\u30c6\u30a3\u30d6\u3092\u4f7f\u3063\u3066public [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"class_list":["post-3580","post","type-post","status-publish","format-standard","hentry","category-linux"],"_links":{"self":[{"href":"https:\/\/ephemeral-arcadia.jp\/passo_wp\/wp-json\/wp\/v2\/posts\/3580","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ephemeral-arcadia.jp\/passo_wp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ephemeral-arcadia.jp\/passo_wp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ephemeral-arcadia.jp\/passo_wp\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/ephemeral-arcadia.jp\/passo_wp\/wp-json\/wp\/v2\/comments?post=3580"}],"version-history":[{"count":4,"href":"https:\/\/ephemeral-arcadia.jp\/passo_wp\/wp-json\/wp\/v2\/posts\/3580\/revisions"}],"predecessor-version":[{"id":3584,"href":"https:\/\/ephemeral-arcadia.jp\/passo_wp\/wp-json\/wp\/v2\/posts\/3580\/revisions\/3584"}],"wp:attachment":[{"href":"https:\/\/ephemeral-arcadia.jp\/passo_wp\/wp-json\/wp\/v2\/media?parent=3580"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ephemeral-arcadia.jp\/passo_wp\/wp-json\/wp\/v2\/categories?post=3580"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ephemeral-arcadia.jp\/passo_wp\/wp-json\/wp\/v2\/tags?post=3580"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}