{"id":1304,"date":"2026-01-10T10:29:33","date_gmt":"2026-01-10T02:29:33","guid":{"rendered":"https:\/\/www.52runoob.com\/?p=1304"},"modified":"2026-01-10T10:29:33","modified_gmt":"2026-01-10T02:29:33","slug":"docker%e9%83%a8%e7%bd%b2jirafeau%e6%96%87%e4%bb%b6%e5%85%b1%e4%ba%ab%e5%b7%a5%e5%85%b7%e7%9a%84%e5%ae%9e%e7%8e%b0%e6%ad%a5%e9%aa%a4","status":"publish","type":"post","link":"https:\/\/www.52runoob.com\/index.php\/2026\/01\/10\/docker%e9%83%a8%e7%bd%b2jirafeau%e6%96%87%e4%bb%b6%e5%85%b1%e4%ba%ab%e5%b7%a5%e5%85%b7%e7%9a%84%e5%ae%9e%e7%8e%b0%e6%ad%a5%e9%aa%a4\/","title":{"rendered":"Docker\u90e8\u7f72Jirafeau\u6587\u4ef6\u5171\u4eab\u5de5\u5177\u7684\u5b9e\u73b0\u6b65\u9aa4"},"content":{"rendered":"\n<p>\u4e0b\u9762\u6211\u7ed9\u4f60\u6574\u7406\u4e00\u4efd<strong>\u5b8c\u6574\u3001\u53ef\u76f4\u63a5\u843d\u5730\u3001Docker \u90e8\u7f72 Jirafeau \u6587\u4ef6\u5171\u4eab\u5de5\u5177\u7684\u6b65\u9aa4<\/strong>\uff0c\u6db5\u76d6 <strong>\u5feb\u901f\u90e8\u7f72\u3001\u6301\u4e45\u5316\u3001\u751f\u4ea7\u4f18\u5316<\/strong>\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">\u4e00\u3001Jirafeau \u7b80\u4ecb<\/h1>\n\n\n\n<p><strong>Jirafeau<\/strong> \u662f\u4e00\u4e2a\u8f7b\u91cf\u7ea7 PHP \u6587\u4ef6\u5206\u4eab\u5de5\u5177\uff1a<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u5355\u6587\u4ef6\u4e0a\u4f20<\/li>\n\n\n\n<li>\u652f\u6301\u5927\u6587\u4ef6<\/li>\n\n\n\n<li>Web \u754c\u9762\u7b80\u5355<\/li>\n\n\n\n<li>\u652f\u6301\u4e34\u65f6 \/ \u6c38\u4e45\u94fe\u63a5<\/li>\n\n\n\n<li>\u53ef\u4ee5\u81ea\u5efa\u79c1\u6709\u6587\u4ef6\u5206\u4eab\u670d\u52a1<\/li>\n<\/ul>\n\n\n\n<p>\u5b98\u7f51\/\u9879\u76ee\u5730\u5740\uff1a<a href=\"https:\/\/gitlab.com\/mojo42\/Jirafeau\">https:\/\/gitlab.com\/mojo42\/Jirafeau<\/a><\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">\u4e8c\u3001\u90e8\u7f72\u524d\u51c6\u5907<\/h1>\n\n\n\n<h2 class=\"wp-block-heading\">1\ufe0f\u20e3 \u7cfb\u7edf\u73af\u5883<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Linux \/ macOS \/ Windows<\/li>\n\n\n\n<li>\u5df2\u5b89\u88c5 Docker \u2265 20.x<\/li>\n\n\n\n<li>\u5df2\u5b89\u88c5 Docker Compose \u2265 v2<\/li>\n<\/ul>\n\n\n\n<p>\u68c0\u67e5\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\ndocker -v\ndocker compose version\n\n<\/pre><\/div>\n\n\n<h2 class=\"wp-block-heading\">2\ufe0f\u20e3 \u7aef\u53e3\u89c4\u5212<\/h2>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th>\u670d\u52a1<\/th><th>\u7aef\u53e3<\/th><\/tr><\/thead><tbody><tr><td>Web \u524d\u7aef<\/td><td>8080\uff08\u9ed8\u8ba4\uff0c\u53ef\u81ea\u5b9a\u4e49\uff09<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">\u4e09\u3001\u65b9\u5f0f\u4e00\uff1a\u5feb\u901f\u4f53\u9a8c\uff08\u5355\u5bb9\u5668\uff09<\/h1>\n\n\n\n<p>\u9002\u5408\u6d4b\u8bd5\u6216\u4e34\u65f6\u4f7f\u7528\u3002<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\ndocker run -d \\\n  --name jirafeau \\\n  -p 8080:80 \\\n  mojo42\/jirafeau\n\n<\/pre><\/div>\n\n\n<p>\u8bbf\u95ee\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nhttp:\/\/\u670d\u52a1\u5668IP:8080\n\n<\/pre><\/div>\n\n\n<p>\u2705 \u5373\u53ef\u770b\u5230 Jirafeau \u6587\u4ef6\u4e0a\u4f20\u754c\u9762<\/p>\n\n\n\n<p>\u26a0\ufe0f \u6ce8\u610f\uff1a\u8fd9\u79cd\u65b9\u5f0f\u6570\u636e<strong>\u5bb9\u5668\u5185\u5b58\u50a8<\/strong>\uff0c\u5bb9\u5668\u5220\u9664\u540e\u6587\u4ef6\u4f1a\u4e22\u5931<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">\u56db\u3001\u65b9\u5f0f\u4e8c\uff1aDocker Compose\uff08\u63a8\u8350\u751f\u4ea7\u73af\u5883\uff09<\/h1>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">1\ufe0f\u20e3 \u521b\u5efa\u76ee\u5f55\u7ed3\u6784<\/h2>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nmkdir -p jirafeau\/{data,config}\ncd jirafeau\n\n<\/pre><\/div>\n\n\n<ul class=\"wp-block-list\">\n<li><code>data<\/code> \u2192 \u4e0a\u4f20\u7684\u6587\u4ef6\u6301\u4e45\u5316<\/li>\n\n\n\n<li><code>config<\/code> \u2192 Jirafeau \u914d\u7f6e\u6587\u4ef6<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">2\ufe0f\u20e3 \u7f16\u5199 <code>docker-compose.yml<\/code><\/h2>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nversion: &quot;3.9&quot;\n\nservices:\n  jirafeau:\n    image: mojo42\/jirafeau\n    container_name: jirafeau\n    restart: unless-stopped\n    ports:\n      - &quot;8080:80&quot;\n    volumes:\n      - .\/data:\/var\/www\/html\/data\n      - .\/config:\/var\/www\/html\/config\n\n<\/pre><\/div>\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">3\ufe0f\u20e3 \u542f\u52a8\u670d\u52a1<\/h2>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\ndocker compose up -d\n\n<\/pre><\/div>\n\n\n<p>\u8bbf\u95ee\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nhttp:\/\/\u670d\u52a1\u5668IP:8080\n\n<\/pre><\/div>\n\n\n<p>\u2705 \u4e0a\u4f20\u6587\u4ef6\u3001\u83b7\u53d6\u94fe\u63a5\u5747\u53ef\u7528<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">\u4e94\u3001\u6301\u4e45\u5316\u4e0e\u5b89\u5168\u5efa\u8bae<\/h1>\n\n\n\n<h2 class=\"wp-block-heading\">1\ufe0f\u20e3 \u6301\u4e45\u5316\u5b58\u50a8<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u6587\u4ef6\uff1a\u6302\u8f7d <code>data<\/code><\/li>\n\n\n\n<li>\u914d\u7f6e\uff1a\u6302\u8f7d <code>config<\/code><\/li>\n<\/ul>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nvolumes:\n  - .\/data:\/var\/www\/html\/data\n  - .\/config:\/var\/www\/html\/config\n\n<\/pre><\/div>\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">2\ufe0f\u20e3 \u8bbe\u7f6e\u8bbf\u95ee\u5bc6\u7801<\/h2>\n\n\n\n<p>\u5728 <code>config\/config.php<\/code> \u4e2d\u8bbe\u7f6e\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\n$usePass = true;\n$password = &quot;yourpassword&quot;;\n\n<\/pre><\/div>\n\n\n<p>\u6216\u8005\u5728 Web \u754c\u9762\u9996\u6b21\u8bbf\u95ee\u65f6\u8bbe\u7f6e<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">3\ufe0f\u20e3 \u5efa\u8bae\u914d\u7f6e\u53cd\u5411\u4ee3\u7406 + HTTPS<\/h2>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nserver {\n    listen 80;\n    server_name files.example.com;\n\n    location \/ {\n        proxy_pass http:\/\/127.0.0.1:8080;\n        proxy_set_header Host $host;\n        proxy_set_header X-Real-IP $remote_addr;\n    }\n}\n\n<\/pre><\/div>\n\n\n<ul class=\"wp-block-list\">\n<li>\u4f7f\u7528 Let\u2019s Encrypt \/ Certbot \u542f\u7528 HTTPS<\/li>\n\n\n\n<li>\u907f\u514d\u660e\u6587\u6587\u4ef6\u5206\u4eab<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">\u516d\u3001\u5347\u7ea7\u4e0e\u7ef4\u62a4<\/h1>\n\n\n\n<h3 class=\"wp-block-heading\">\u5347\u7ea7\u955c\u50cf<\/h3>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\ndocker compose pull\ndocker compose down\ndocker compose up -d\n\n<\/pre><\/div>\n\n\n<ul class=\"wp-block-list\">\n<li>\u6570\u636e\u4e0d\u4f1a\u4e22\u5931\uff08\u56e0\u4e3a volume \u5df2\u6302\u8f7d\uff09<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">\u4e03\u3001\u751f\u4ea7\u73af\u5883\u4f18\u5316\u5efa\u8bae<\/h1>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th>\u4f18\u5316\u70b9<\/th><th>\u65b9\u6cd5<\/th><\/tr><\/thead><tbody><tr><td>\u5927\u6587\u4ef6\u4e0a\u4f20<\/td><td>\u8c03\u6574 PHP <code>upload_max_filesize<\/code> &amp; <code>post_max_size<\/code><\/td><\/tr><tr><td>\u591a\u7528\u6237 \/ \u6743\u9650<\/td><td>\u4f7f\u7528\u53cd\u5411\u4ee3\u7406 + \u57fa\u7840\u8ba4\u8bc1<\/td><\/tr><tr><td>\u5b89\u5168<\/td><td>\u5f3a\u5236 HTTPS + \u914d\u7f6e\u8bbf\u95ee\u5bc6\u7801<\/td><\/tr><tr><td>\u65e5\u5fd7\u7ba1\u7406<\/td><td>\u6302\u8f7d\u65e5\u5fd7\u76ee\u5f55\uff0c\u4fbf\u4e8e\u76d1\u63a7<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">\u516b\u3001\u5feb\u901f\u547d\u4ee4\u603b\u7ed3<\/h1>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\n# 1. \u62c9\u53d6\u955c\u50cf\ndocker pull mojo42\/jirafeau\n\n# 2. \u5355\u5bb9\u5668\u8fd0\u884c\ndocker run -d --name jirafeau -p 8080:80 mojo42\/jirafeau\n\n# 3. Docker Compose \u90e8\u7f72\ndocker compose up -d\n\n# 4. \u67e5\u770b\u65e5\u5fd7\ndocker compose logs -f\n\n# 5. \u5347\u7ea7\ndocker compose pull\ndocker compose up -d\n\n<\/pre><\/div>\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h1 class=\"wp-block-heading\">\u4e5d\u3001\u4e00\u53e5\u8bdd\u603b\u7ed3\uff08\u5fc5\u8bb0\uff09<\/h1>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p><strong>Jirafeau \u662f\u8f7b\u91cf PHP \u6587\u4ef6\u5206\u4eab\u5de5\u5177\uff0c<br>Docker Compose \u53ef\u6301\u4e45\u5316\u5b58\u50a8\u6587\u4ef6\u4e0e\u914d\u7f6e\uff0c<br>\u63a8\u8350\u914d\u5408 Nginx + HTTPS \u63d0\u4f9b\u5b89\u5168\u751f\u4ea7\u73af\u5883\u3002<\/strong><\/p>\n<\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>\u4e0b\u9762\u6211\u7ed9\u4f60\u6574\u7406\u4e00\u4efd\u5b8c\u6574\u3001\u53ef\u76f4\u63a5\u843d\u5730\u3001Docker \u90e8\u7f72 Jirafeau \u6587\u4ef6\u5171&#8230; <a class=\"more-link\" href=\"https:\/\/www.52runoob.com\/index.php\/2026\/01\/10\/docker%e9%83%a8%e7%bd%b2jirafeau%e6%96%87%e4%bb%b6%e5%85%b1%e4%ba%ab%e5%b7%a5%e5%85%b7%e7%9a%84%e5%ae%9e%e7%8e%b0%e6%ad%a5%e9%aa%a4\/\">Continue Reading &rarr;<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[55],"tags":[],"class_list":["post-1304","post","type-post","status-publish","format-standard","hentry","category-55"],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/posts\/1304","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/comments?post=1304"}],"version-history":[{"count":1,"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/posts\/1304\/revisions"}],"predecessor-version":[{"id":1305,"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/posts\/1304\/revisions\/1305"}],"wp:attachment":[{"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/media?parent=1304"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/categories?post=1304"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.52runoob.com\/index.php\/wp-json\/wp\/v2\/tags?post=1304"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}