CINXE.COM
DokuWiki - Alpine Linux
<!DOCTYPE html> <html class="client-nojs vector-feature-language-in-header-enabled vector-feature-language-in-main-page-header-disabled vector-feature-language-alert-in-sidebar-enabled vector-feature-sticky-header-disabled vector-feature-page-tools-disabled vector-feature-page-tools-pinned-disabled vector-feature-toc-pinned-enabled vector-feature-main-menu-pinned-disabled vector-feature-limited-width-enabled vector-feature-limited-width-content-enabled" lang="en" dir="ltr"> <head> <meta charset="UTF-8"/> <title>DokuWiki - Alpine Linux</title> <script>document.documentElement.className="client-js vector-feature-language-in-header-enabled vector-feature-language-in-main-page-header-disabled vector-feature-language-alert-in-sidebar-enabled vector-feature-sticky-header-disabled vector-feature-page-tools-disabled vector-feature-page-tools-pinned-disabled vector-feature-toc-pinned-enabled vector-feature-main-menu-pinned-disabled vector-feature-limited-width-enabled vector-feature-limited-width-content-enabled";RLCONF={"wgBreakFrames":false,"wgSeparatorTransformTable":["",""],"wgDigitTransformTable":["",""],"wgDefaultDateFormat":"dmy","wgMonthNames":["","January","February","March","April","May","June","July","August","September","October","November","December"],"wgRequestId":"b9f9666c45ced3a5cba0d7ab","wgCSPNonce":false,"wgCanonicalNamespace":"","wgCanonicalSpecialPageName":false,"wgNamespaceNumber":0,"wgPageName":"DokuWiki","wgTitle":"DokuWiki","wgCurRevisionId":26615,"wgRevisionId":26615,"wgArticleId":1925,"wgIsArticle":true, "wgIsRedirect":false,"wgAction":"view","wgUserName":null,"wgUserGroups":["*"],"wgCategories":["Server","PHP"],"wgPageContentLanguage":"en","wgPageContentModel":"wikitext","wgRelevantPageName":"DokuWiki","wgRelevantArticleId":1925,"wgIsProbablyEditable":false,"wgRelevantPageIsProbablyEditable":false,"wgRestrictionEdit":[],"wgRestrictionMove":[],"wgVector2022PreviewPages":[]};RLSTATE={"skins.vector.user.styles":"ready","site.styles":"ready","user.styles":"ready","skins.vector.user":"ready","user":"ready","user.options":"loading","mediawiki.ui.button":"ready","skins.vector.styles":"ready","skins.vector.icons":"ready","mediawiki.ui.icon":"ready"};RLPAGEMODULES=["site","mediawiki.page.ready","mediawiki.toc","skins.vector.js","skins.vector.es6"];</script> <script>(RLQ=window.RLQ||[]).push(function(){mw.loader.implement("user.options@12s5i",function($,jQuery,require,module){mw.user.tokens.set({"patrolToken":"+\\","watchToken":"+\\","csrfToken":"+\\"});});});</script> <link rel="stylesheet" href="/w/load.php?lang=en&modules=mediawiki.ui.button%2Cicon%7Cskins.vector.icons%2Cstyles&only=styles&skin=vector-2022"/> <script async="" src="/w/load.php?lang=en&modules=startup&only=scripts&raw=1&skin=vector-2022"></script> <meta name="generator" content="MediaWiki 1.40.0"/> <meta name="robots" content="max-image-preview:standard"/> <meta name="format-detection" content="telephone=no"/> <meta name="viewport" content="width=1000"/> <link rel="icon" href="/w/images/favicon.png"/> <link rel="search" type="application/opensearchdescription+xml" href="/w/opensearch_desc.php" title="Alpine Linux (en)"/> <link rel="EditURI" type="application/rsd+xml" href="https://wiki.alpinelinux.org/w/api.php?action=rsd"/> <link rel="license" href="/wiki/MediaWiki:Copyright"/> <link rel="alternate" type="application/atom+xml" title="Alpine Linux Atom feed" href="/w/index.php?title=Special:RecentChanges&feed=atom"/> </head> <body class="skin-vector skin-vector-search-vue mediawiki ltr sitedir-ltr mw-hide-empty-elt ns-0 ns-subject page-DokuWiki rootpage-DokuWiki skin-vector-2022 action-view"><div class="mw-page-container"> <a class="mw-jump-link" href="#bodyContent">Jump to content</a> <div class="mw-page-container-inner"> <input type="checkbox" id="mw-sidebar-checkbox" class="mw-checkbox-hack-checkbox" > <header class="mw-header mw-ui-icon-flush-left mw-ui-icon-flush-right"> <div class="vector-header-start"> <label id="mw-sidebar-button" class="mw-checkbox-hack-button mw-ui-icon mw-ui-button mw-ui-quiet mw-ui-icon-element mw-ui-icon-flush-right" for="mw-sidebar-checkbox" role="button" aria-controls="mw-panel" data-event-name="ui.sidebar" tabindex="0" title="Main menu"> <span>Toggle sidebar</span> </label> <a href="/wiki/Main_Page" class="mw-logo"> <span class="mw-logo-container"> <strong class="mw-logo-wordmark">Alpine Linux</strong> </span> </a> </div> <div class="vector-header-end"> <div id="p-search" role="search" class="vector-search-box-vue vector-search-box-collapses vector-search-box-show-thumbnail vector-search-box-auto-expand-width vector-search-box"> <a href="/wiki/Special:Search" title="Search Alpine Linux [f]" accesskey="f" class="mw-ui-button mw-ui-quiet mw-ui-icon mw-ui-icon-element mw-ui-icon-wikimedia-search search-toggle"> <span>Search</span> </a> <div> <form action="/w/index.php" id="searchform" class="vector-search-box-form"> <div id="simpleSearch" class="vector-search-box-inner" data-search-loc="header-moved"> <input class="vector-search-box-input" type="search" name="search" placeholder="Search Alpine Linux" aria-label="Search Alpine Linux" autocapitalize="sentences" title="Search Alpine Linux [f]" accesskey="f" id="searchInput" > <input type="hidden" name="title" value="Special:Search"> <input id="mw-searchButton" class="searchButton mw-fallbackSearchButton" type="submit" name="fulltext" title="Search the pages for this text" value="Search"> <input id="searchButton" class="searchButton" type="submit" name="go" title="Go to a page with this exact name if it exists" value="Go"> </div> </form> </div> </div> <nav class="vector-user-links" aria-label="Personal tools" role="navigation" > <div id="p-vector-user-menu-overflow" class="vector-menu mw-portlet mw-portlet-vector-user-menu-overflow" > <div class="vector-menu-content"> <ul class="vector-menu-content-list"><li id="pt-createaccount-2" class="user-links-collapsible-item mw-list-item"><a href="/w/index.php?title=Special:CreateAccount&returnto=DokuWiki" title="You are encouraged to create an account and log in; however, it is not mandatory"><span>Create account</span></a></li><li id="pt-login-2" class="user-links-collapsible-item mw-list-item"><a href="/w/index.php?title=Special:UserLogin&returnto=DokuWiki" title="You are encouraged to log in; however, it is not mandatory [o]" accesskey="o"><span>Log in</span></a></li></ul> </div> </div> <div id="vector-user-links-dropdown" class="vector-menu vector-dropdown vector-menu-dropdown vector-user-menu vector-user-menu-logged-out user-links-collapsible-item" title="More options" > <input type="checkbox" id="vector-user-links-dropdown-checkbox" role="button" aria-haspopup="true" data-event-name="ui.dropdown-vector-user-links-dropdown" class="vector-menu-checkbox " aria-label="Personal tools" /> <label id="vector-user-links-dropdown-label" for="vector-user-links-dropdown-checkbox" class="vector-menu-heading mw-checkbox-hack-button mw-ui-button mw-ui-quiet mw-ui-icon-element " aria-hidden="true" > <span class="mw-ui-icon mw-ui-icon-ellipsis mw-ui-icon-wikimedia-ellipsis"></span> <span class="vector-menu-heading-label">Personal tools</span> </label> <div class="vector-menu-content vector-dropdown-content"> <div id="p-personal" class="vector-menu mw-portlet mw-portlet-personal user-links-collapsible-item" title="User menu" > <div class="vector-menu-content"> <ul class="vector-menu-content-list"><li id="pt-createaccount" class="user-links-collapsible-item mw-list-item"><a href="/w/index.php?title=Special:CreateAccount&returnto=DokuWiki" title="You are encouraged to create an account and log in; however, it is not mandatory"><span class="mw-ui-icon mw-ui-icon-userAdd mw-ui-icon-wikimedia-userAdd"></span> <span>Create account</span></a></li><li id="pt-login" class="user-links-collapsible-item mw-list-item"><a href="/w/index.php?title=Special:UserLogin&returnto=DokuWiki" title="You are encouraged to log in; however, it is not mandatory [o]" accesskey="o"><span class="mw-ui-icon mw-ui-icon-logIn mw-ui-icon-wikimedia-logIn"></span> <span>Log in</span></a></li></ul> </div> </div> </div> </div> </nav> </div> </header> <div class="vector-main-menu-container "> <div id="mw-navigation"> <nav id="mw-panel" class="vector-main-menu-landmark" aria-label="Site" role="navigation"> <div id="vector-main-menu" class="vector-main-menu vector-pinnable-element"> <div id="p-Welcome" class="vector-main-menu-group vector-menu mw-portlet mw-portlet-Welcome" > <div id="p-Welcome-label" class="vector-menu-heading " > <span class="vector-menu-heading-label">Welcome</span> </div> <div class="vector-menu-content"> <ul class="vector-menu-content-list"><li id="n-Installation" class="mw-list-item"><a href="/wiki/Installation"><span>Installation</span></a></li><li id="n-FAQ" class="mw-list-item"><a href="/wiki/FAQ"><span>FAQ</span></a></li><li id="n-Tutorials-and-Howtos" class="mw-list-item"><a href="/wiki/Tutorials_and_Howtos"><span>Tutorials and Howtos</span></a></li><li id="n-Contribute" class="mw-list-item"><a href="/wiki/Contribute"><span>Contribute</span></a></li><li id="n-Developer-Documentation" class="mw-list-item"><a href="/wiki/Developer_Documentation"><span>Developer Documentation</span></a></li><li id="n-Glossary" class="mw-list-item"><a href="/wiki/Glossary"><span>Glossary</span></a></li></ul> </div> </div> <div id="p-Services" class="vector-main-menu-group vector-menu mw-portlet mw-portlet-Services" > <div id="p-Services-label" class="vector-menu-heading " > <span class="vector-menu-heading-label">Services</span> </div> <div class="vector-menu-content"> <ul class="vector-menu-content-list"><li id="n-Main-Site" class="mw-list-item"><a href="https://alpinelinux.org" rel="nofollow"><span>Main Site</span></a></li><li id="n-Git-Repositories" class="mw-list-item"><a href="https://git.alpinelinux.org" rel="nofollow"><span>Git Repositories</span></a></li><li id="n-Bug-Tracker" class="mw-list-item"><a href="https://gitlab.alpinelinux.org/alpine/aports/-/issues" rel="nofollow"><span>Bug Tracker</span></a></li><li id="n-Mailing-Lists" class="mw-list-item"><a href="/wiki/Alpine_Linux:Mailing_lists"><span>Mailing Lists</span></a></li><li id="n-IRC-Channels" class="mw-list-item"><a href="/wiki/IRC"><span>IRC Channels</span></a></li><li id="n-Downloads" class="mw-list-item"><a href="https://alpinelinux.org/downloads" rel="nofollow"><span>Downloads</span></a></li><li id="n-Package-Database" class="mw-list-item"><a href="https://pkgs.alpinelinux.org/packages" rel="nofollow"><span>Package Database</span></a></li></ul> </div> </div> <div id="p-Wiki" class="vector-main-menu-group vector-menu mw-portlet mw-portlet-Wiki" > <div id="p-Wiki-label" class="vector-menu-heading " > <span class="vector-menu-heading-label">Wiki</span> </div> <div class="vector-menu-content"> <ul class="vector-menu-content-list"><li id="n-Recent-Changes" class="mw-list-item"><a href="/wiki/Special:RecentChanges"><span>Recent Changes</span></a></li><li id="n-Site-Index" class="mw-list-item"><a href="/wiki/Special:PrefixIndex"><span>Site Index</span></a></li><li id="n-Categories" class="mw-list-item"><a href="/wiki/Special:Categories"><span>Categories</span></a></li><li id="n-Help" class="mw-list-item"><a href="/wiki/Category:Wiki"><span>Help</span></a></li><li id="n-Maintenance" class="mw-list-item"><a href="/wiki/Alpine_Linux:Wiki_maintenance"><span>Maintenance</span></a></li></ul> </div> </div> <div id="p-tb" class="vector-main-menu-group vector-menu mw-portlet mw-portlet-tb" > <div id="p-tb-label" class="vector-menu-heading " > <span class="vector-menu-heading-label">Toolbox</span> </div> <div class="vector-menu-content"> <ul class="vector-menu-content-list"><li id="t-whatlinkshere" class="mw-list-item"><a href="/wiki/Special:WhatLinksHere/DokuWiki" title="A list of all wiki pages that link here [j]" accesskey="j"><span>What links here</span></a></li><li id="t-recentchangeslinked" class="mw-list-item"><a href="/wiki/Special:RecentChangesLinked/DokuWiki" rel="nofollow" title="Recent changes in pages linked from this page [k]" accesskey="k"><span>Related changes</span></a></li><li id="t-specialpages" class="mw-list-item"><a href="/wiki/Special:SpecialPages" title="A list of all special pages [q]" accesskey="q"><span>Special pages</span></a></li><li id="t-print" class="mw-list-item"><a href="javascript:print();" rel="alternate" title="Printable version of this page [p]" accesskey="p"><span>Printable version</span></a></li><li id="t-permalink" class="mw-list-item"><a href="/w/index.php?title=DokuWiki&oldid=26615" title="Permanent link to this revision of this page"><span>Permanent link</span></a></li><li id="t-info" class="mw-list-item"><a href="/w/index.php?title=DokuWiki&action=info" title="More information about this page"><span>Page information</span></a></li></ul> </div> </div> </div> </nav> </div> </div> <div class="vector-sitenotice-container"> <div id="siteNotice"></div> </div> <input type="checkbox" id="vector-toc-collapsed-checkbox" class="mw-checkbox-hack-checkbox"> <nav id="mw-panel-toc" role="navigation" aria-label="Contents" data-event-name="ui.sidebar-toc" class="mw-table-of-contents-container vector-toc-landmark"> <div id="vector-toc-pinned-container" class="vector-pinned-container"> <div id="vector-toc" class="vector-toc vector-pinnable-element"> <div class="vector-pinnable-header vector-toc-pinnable-header vector-pinnable-header-pinned" data-feature-name="toc-pinned" data-pinnable-element-id="vector-toc" > <h2 class="vector-pinnable-header-label">Contents</h2> <button class="vector-pinnable-header-toggle-button vector-pinnable-header-pin-button" data-event-name="pinnable-header.vector-toc.pin">move to sidebar</button> <button class="vector-pinnable-header-toggle-button vector-pinnable-header-unpin-button" data-event-name="pinnable-header.vector-toc.unpin">hide</button> </div> <ul class="vector-toc-contents" id="mw-panel-toc-list"> <li id="toc-mw-content-text" class="vector-toc-list-item vector-toc-level-1"> <a href="#" class="vector-toc-link"> <div class="vector-toc-text">Beginning</div> </a> </li> <li id="toc-Install_lighttpd_and_PHP" class="vector-toc-list-item vector-toc-level-1 vector-toc-list-item-expanded"> <a class="vector-toc-link" href="#Install_lighttpd_and_PHP"> <div class="vector-toc-text"> <span class="vector-toc-numb">1</span>Install lighttpd and PHP</div> </a> <button aria-controls="toc-Install_lighttpd_and_PHP-sublist" class="mw-ui-icon mw-ui-icon-wikimedia-expand mw-ui-icon-small vector-toc-toggle"> Toggle Install lighttpd and PHP subsection </button> <ul id="toc-Install_lighttpd_and_PHP-sublist" class="vector-toc-list"> <li id="toc-Basic_Installation" class="vector-toc-list-item vector-toc-level-2"> <a class="vector-toc-link" href="#Basic_Installation"> <div class="vector-toc-text"> <span class="vector-toc-numb">1.1</span>Basic Installation</div> </a> <ul id="toc-Basic_Installation-sublist" class="vector-toc-list"> </ul> </li> <li id="toc-Configure_Lighttpd" class="vector-toc-list-item vector-toc-level-2"> <a class="vector-toc-link" href="#Configure_Lighttpd"> <div class="vector-toc-text"> <span class="vector-toc-numb">1.2</span>Configure Lighttpd</div> </a> <ul id="toc-Configure_Lighttpd-sublist" class="vector-toc-list"> </ul> </li> <li id="toc-Start_lighttpd_service_and_add_it_to_default_runlevel" class="vector-toc-list-item vector-toc-level-2"> <a class="vector-toc-link" href="#Start_lighttpd_service_and_add_it_to_default_runlevel"> <div class="vector-toc-text"> <span class="vector-toc-numb">1.3</span>Start lighttpd service and add it to default runlevel</div> </a> <ul id="toc-Start_lighttpd_service_and_add_it_to_default_runlevel-sublist" class="vector-toc-list"> </ul> </li> </ul> </li> <li id="toc-Install_nginx_and_PHP" class="vector-toc-list-item vector-toc-level-1 vector-toc-list-item-expanded"> <a class="vector-toc-link" href="#Install_nginx_and_PHP"> <div class="vector-toc-text"> <span class="vector-toc-numb">2</span>Install nginx and PHP</div> </a> <button aria-controls="toc-Install_nginx_and_PHP-sublist" class="mw-ui-icon mw-ui-icon-wikimedia-expand mw-ui-icon-small vector-toc-toggle"> Toggle Install nginx and PHP subsection </button> <ul id="toc-Install_nginx_and_PHP-sublist" class="vector-toc-list"> <li id="toc-Installing_DokuWiki" class="vector-toc-list-item vector-toc-level-2"> <a class="vector-toc-link" href="#Installing_DokuWiki"> <div class="vector-toc-text"> <span class="vector-toc-numb">2.1</span>Installing DokuWiki</div> </a> <ul id="toc-Installing_DokuWiki-sublist" class="vector-toc-list"> </ul> </li> </ul> </li> </ul> </div> </div> </nav> <div class="mw-content-container"> <main id="content" class="mw-body" role="main"> <header class="mw-body-header vector-page-titlebar"> <label id="vector-toc-collapsed-button" class="mw-ui-button mw-ui-quiet mw-ui-icon mw-ui-icon-flush-left mw-ui-icon-element mw-ui-icon-wikimedia-listBullet mw-checkbox-hack-button" for="vector-toc-collapsed-checkbox" role="button" aria-controls="toc-toggle-list" data-event-name="vector.toc-toggle-list" tabindex="0" title="Table of Contents"> Toggle the table of contents </label> <nav role="navigation" aria-label="Contents" class="vector-toc-landmark"> <div id="vector-page-titlebar-toc" class="vector-menu vector-dropdown vector-menu-dropdown vector-page-titlebar-toc mw-ui-icon-flush-left" > <input type="checkbox" id="vector-page-titlebar-toc-checkbox" role="button" aria-haspopup="true" data-event-name="ui.dropdown-vector-page-titlebar-toc" class="vector-menu-checkbox " aria-label="Toggle the table of contents" /> <label id="vector-page-titlebar-toc-label" for="vector-page-titlebar-toc-checkbox" class="vector-menu-heading mw-checkbox-hack-button mw-ui-button mw-ui-quiet mw-ui-icon-element " aria-hidden="true" > <span class="mw-ui-icon mw-ui-icon-listBullet mw-ui-icon-wikimedia-listBullet"></span> <span class="vector-menu-heading-label">Toggle the table of contents</span> </label> <div class="vector-menu-content vector-dropdown-content"> <div id="vector-page-titlebar-toc-unpinned-container" class="vector-unpinned-container"> </div> </div> </div> </nav> <h1 id="firstHeading" class="firstHeading mw-first-heading"><span class="mw-page-title-main">DokuWiki</span></h1> </header> <div class="vector-page-toolbar"> <div class="vector-page-toolbar-container"> <div id="left-navigation"> <nav aria-label="Namespaces"> <div id="p-associated-pages" class="vector-menu vector-menu-tabs mw-portlet mw-portlet-associated-pages" > <div class="vector-menu-content"> <ul class="vector-menu-content-list"> <li id="ca-nstab-main" class="selected vector-tab-noicon mw-list-item"><a data-mw="interface" href="/wiki/DokuWiki" title="View the content page [c]" accesskey="c" class=""><span>Page</span></a> </li> <li id="ca-talk" class="new vector-tab-noicon mw-list-item"><a data-mw="interface" href="/w/index.php?title=Talk:DokuWiki&action=edit&redlink=1" rel="discussion" title="Discussion about the content page (page does not exist) [t]" accesskey="t" class=""><span>Discussion</span></a> </li> </ul> </div> </div> <div id="p-variants" class="vector-menu vector-dropdown vector-menu-dropdown mw-portlet mw-portlet-variants emptyPortlet" > <input type="checkbox" id="p-variants-checkbox" role="button" aria-haspopup="true" data-event-name="ui.dropdown-p-variants" class="vector-menu-checkbox" aria-label="Change language variant" /> <label id="p-variants-label" for="p-variants-checkbox" class="vector-menu-heading " aria-hidden="true" > <span class="vector-menu-heading-label">English</span> </label> <div class="vector-menu-content vector-dropdown-content"> <div class="vector-menu-content"> <ul class="vector-menu-content-list"></ul> </div> </div> </div> </nav> </div> <div id="right-navigation" class="vector-collapsible"> <nav aria-label="Views"> <div id="p-views" class="vector-menu vector-menu-tabs mw-portlet mw-portlet-views" > <div class="vector-menu-content"> <ul class="vector-menu-content-list"> <li id="ca-view" class="selected vector-tab-noicon mw-list-item"><a data-mw="interface" href="/wiki/DokuWiki" class=""><span>Read</span></a> </li> <li id="ca-viewsource" class="vector-tab-noicon mw-list-item"><a data-mw="interface" href="/w/index.php?title=DokuWiki&action=edit" title="This page is protected. You can view its source [e]" accesskey="e" class=""><span>View source</span></a> </li> <li id="ca-history" class="vector-tab-noicon mw-list-item"><a data-mw="interface" href="/w/index.php?title=DokuWiki&action=history" title="Past revisions of this page [h]" accesskey="h" class=""><span>View history</span></a> </li> </ul> </div> </div> </nav> <nav class="vector-page-tools-landmark" aria-label="More options"> <div id="p-cactions" class="vector-menu vector-dropdown vector-menu-dropdown mw-portlet mw-portlet-cactions emptyPortlet vector-has-collapsible-items" title="More options" > <input type="checkbox" id="p-cactions-checkbox" role="button" aria-haspopup="true" data-event-name="ui.dropdown-p-cactions" class="vector-menu-checkbox" aria-label="More" /> <label id="p-cactions-label" for="p-cactions-checkbox" class="vector-menu-heading" aria-hidden="true" > <span class="vector-menu-heading-label">More</span> </label> <div class="vector-menu-content vector-dropdown-content"> <div class="vector-menu-content"> <ul class="vector-menu-content-list"><li id="ca-more-view" class="selected vector-more-collapsible-item mw-list-item"><a href="/wiki/DokuWiki"><span>Read</span></a></li><li id="ca-more-viewsource" class="vector-more-collapsible-item mw-list-item"><a href="/w/index.php?title=DokuWiki&action=edit"><span>View source</span></a></li><li id="ca-more-history" class="vector-more-collapsible-item mw-list-item"><a href="/w/index.php?title=DokuWiki&action=history"><span>View history</span></a></li></ul> </div> </div> </div> </nav> </div> </div> </div> <div id="bodyContent" class="vector-body" aria-labelledby="firstHeading" data-mw-ve-target-container> <div class="vector-body-before-content"> <div class="mw-indicators"> </div> <div id="siteSub" class="noprint">From Alpine Linux</div> </div> <div id="contentSub"><div id="mw-content-subtitle"></div></div> <div id="mw-content-text" class="mw-body-content mw-content-ltr" lang="en" dir="ltr"><div class="mw-parser-output"><p><a rel="nofollow" class="external text" href="https://www.dokuwiki.org/dokuwiki">DokuWiki</a> is a standards compliant, simple to use Wiki, mainly aimed at creating documentation of any kind. This page covers installation with either lighttpd or nginx. </p> <meta property="mw:PageProp/toc" /> <h1><span class="mw-headline" id="Install_lighttpd_and_PHP">Install lighttpd and PHP</span></h1> <h2><span class="mw-headline" id="Basic_Installation">Basic Installation</span></h2> <p>For installing the additional packages first <b><a href="/wiki/Repositories#Managing_repositories" title="Repositories">activate community packages</a></b> and update the package index </p><p>Install the required packages: </p> <p style="background-color:#eeeeee; border:1px dashed #bbbbbb; line-height:1.1em; padding:1em; font-family:monospace, Courier; font-size:10pt; white-space:pre; overflow:auto;"># apk add <span class="plainlinks" style="font-family: monospace, Courier;font-size:10pt;"><a rel="nofollow" class="external text" href="https://pkgs.alpinelinux.org/packages?name=lighttpd&branch=edge&repo=&arch=x86_64&maintainer=">lighttpd</a></span> <span class="plainlinks" style="font-family: monospace, Courier;font-size:10pt;"><a rel="nofollow" class="external text" href="https://pkgs.alpinelinux.org/packages?name=php82&branch=edge&repo=&arch=x86_64&maintainer=">php82</a></span> <span class="plainlinks" style="font-family: monospace, Courier;font-size:10pt;"><a rel="nofollow" class="external text" href="https://pkgs.alpinelinux.org/packages?name=fcgi&branch=edge&repo=&arch=x86_64&maintainer=">fcgi</a></span> <span class="plainlinks" style="font-family: monospace, Courier;font-size:10pt;"><a rel="nofollow" class="external text" href="https://pkgs.alpinelinux.org/packages?name=php82-cgi&branch=edge&repo=&arch=x86_64&maintainer=">php82-cgi</a></span></p> <h2><span class="mw-headline" id="Configure_Lighttpd">Configure Lighttpd</span></h2> <p>Edit lighttpd.conf (<span style="font-family: monospace, Courier; font-size:10pt; color: #000055; white-space: nowrap">/etc/lighttpd/lighttpd.conf</span>) and uncomment the line: </p> <div><p style="background-color:#f9f9f9; border:1px solid #2f6fab; border-bottom:0; padding:.2em 1.2em; display:inline;"><strong>Contents of </strong><span style="font-family: monospace, Courier; font-size:10pt; color: #000055; white-space: nowrap">/etc/lighttpd/lighttpd.conf</span></p><div style="background-color:#f9f9f9; border:1px dashed #2f6fab; border-left:1px solid #2f6fab; margin-top:-.2em; line-height:1.1em; padding:1em; font-family:monospace; font-size:10pt; white-space:pre; overflow:auto;">... include "mod_fastcgi.conf" ...</div></div> <p>Edit mod_fastcgi.conf (<span style="font-family: monospace, Courier; font-size:10pt; color: #000055; white-space: nowrap">/etc/lighttpd/mod_fastcgi.conf</span>), find and change <span style="font-family: monospace, Courier; font-size:10pt; color: #000055; white-space: nowrap">/usr/bin/php-cgi</span> to <span style="font-family: monospace, Courier; font-size:10pt; color: #000055; white-space: nowrap">/usr/bin/php-cgi82</span>. </p> <div><p style="background-color:#f9f9f9; border:1px solid #2f6fab; border-bottom:0; padding:.2em 1.2em; display:inline;"><strong>Contents of </strong><span style="font-family: monospace, Courier; font-size:10pt; color: #000055; white-space: nowrap">/etc/lighttpd/mod_fastcgi.conf</span></p><div style="background-color:#f9f9f9; border:1px dashed #2f6fab; border-left:1px solid #2f6fab; margin-top:-.2em; line-height:1.1em; padding:1em; font-family:monospace; font-size:10pt; white-space:pre; overflow:auto;">... "bin-path" => "/usr/bin/php-cgi82" # php-cgi ...</div></div> <h2><span class="mw-headline" id="Start_lighttpd_service_and_add_it_to_default_runlevel">Start <code>lighttpd</code> service and add it to default runlevel</span></h2> <p style="background-color:#eeeeee; border:1px dashed #bbbbbb; line-height:1.1em; padding:1em; font-family:monospace, Courier; font-size:10pt; white-space:pre; overflow:auto;"># rc-service lighttpd start # rc-update add lighttpd default </p> <h1><span class="mw-headline" id="Install_nginx_and_PHP">Install nginx and PHP</span></h1> <p>Continue with <a rel="nofollow" class="external text" href="https://wiki.alpinelinux.org/wiki/Nginx_with_PHP#PHP7_Installation">this tutorial</a>, however please note that only these packages are required: </p> <p style="background-color:#eeeeee; border:1px dashed #bbbbbb; line-height:1.1em; padding:1em; font-family:monospace, Courier; font-size:10pt; white-space:pre; overflow:auto;">apk add nginx php7 php7-gd php7-fpm php7-xml php7-session php7-json</p> <p>Make sure that the PHP user and group match those for nginx (the outputs should be the same): </p> <p style="background-color:#eeeeee; border:1px dashed #bbbbbb; line-height:1.1em; padding:1em; font-family:monospace, Courier; font-size:10pt; white-space:pre; overflow:auto;">grep listen.owner /etc/php7/php-fpm.d/www.conf grep listen.group /etc/php7/php-fpm.d/www.conf grep user /etc/php7/php-fpm.d/www.conf grep group /etc/php7/php-fpm.d/www.conf grep user /etc/nginx/nginx.conf</p> <p>Afterwards, <a rel="nofollow" class="external text" href="https://www.dokuwiki.org/install:nginx">configure nginx</a> and, optionally, <a rel="nofollow" class="external text" href="https://www.dokuwiki.org/rewrite">enable URL rewrites</a> </p><p>Alternatively, you can call PHP from nginx via unix socket: </p> <p style="background-color:#eeeeee; border:1px dashed #bbbbbb; line-height:1.1em; padding:1em; font-family:monospace, Courier; font-size:10pt; white-space:pre; overflow:auto;">sed -i "s|listen\s*=\s*127.0.0.1:9000|listen = /var/run/php.sock|g" /etc/php7/php-fpm.d/www.conf</p> <p>To define unix socket in nginx configuration, add following section to server: </p> <pre> location ~ \.php$ { try_files $uri $uri/ /doku.php; include fastcgi_params; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_param REDIRECT_STATUS 200; fastcgi_pass unix:/var/run/php.sock; } </pre> <h2><span class="mw-headline" id="Installing_DokuWiki">Installing DokuWiki</span></h2> <p>Install required php modules </p> <p style="background-color:#eeeeee; border:1px dashed #bbbbbb; line-height:1.1em; padding:1em; font-family:monospace, Courier; font-size:10pt; white-space:pre; overflow:auto;"># apk add <span class="plainlinks" style="font-family: monospace, Courier;font-size:10pt;"><a rel="nofollow" class="external text" href="https://pkgs.alpinelinux.org/packages?name=php82-session&branch=edge&repo=&arch=x86_64&maintainer=">php82-session</a></span> <span class="plainlinks" style="font-family: monospace, Courier;font-size:10pt;"><a rel="nofollow" class="external text" href="https://pkgs.alpinelinux.org/packages?name=php82-xml&branch=edge&repo=&arch=x86_64&maintainer=">php82-xml</a></span> </p> <p>Create webroot </p> <p style="background-color:#eeeeee; border:1px dashed #bbbbbb; line-height:1.1em; padding:1em; font-family:monospace, Courier; font-size:10pt; white-space:pre; overflow:auto;">mkdir -p /var/www/localhost/htdocs/</p> <p>Download the source code archive </p> <p style="background-color:#eeeeee; border:1px dashed #bbbbbb; line-height:1.1em; padding:1em; font-family:monospace, Courier; font-size:10pt; white-space:pre; overflow:auto;">cd /var/www/localhost/htdocs/ wget <a rel="nofollow" class="external free" href="https://download.dokuwiki.org/src/dokuwiki/dokuwiki-stable.tgz">https://download.dokuwiki.org/src/dokuwiki/dokuwiki-stable.tgz</a></p> <p>Unpack and delete tar file </p> <p style="background-color:#eeeeee; border:1px dashed #bbbbbb; line-height:1.1em; padding:1em; font-family:monospace, Courier; font-size:10pt; white-space:pre; overflow:auto;">tar zxvf dokuwiki-stable.tgz rm dokuwiki-stable.tgz</p> <p>Rename the dokuwiki folder </p> <p style="background-color:#eeeeee; border:1px dashed #bbbbbb; line-height:1.1em; padding:1em; font-family:monospace, Courier; font-size:10pt; white-space:pre; overflow:auto;">mv dokuwiki-2018-04-22c dokuwiki</p> <p>Change the folder permissions (change the www user/group to the one that is used by both web server and PHP) </p> <p style="background-color:#eeeeee; border:1px dashed #bbbbbb; line-height:1.1em; padding:1em; font-family:monospace, Courier; font-size:10pt; white-space:pre; overflow:auto;">chown -R www:www dokuwiki chmod -R 700 dokuwiki/</p> <p>for lighttpd use </p> <p style="background-color:#eeeeee; border:1px dashed #bbbbbb; line-height:1.1em; padding:1em; font-family:monospace, Courier; font-size:10pt; white-space:pre; overflow:auto;">chown -R lighttpd:lighttpd dokuwiki chmod -R 700 dokuwiki/</p> <p>Browse to http://WEB_IP_ADDRESS/dokuwiki/install.php </p> <!-- NewPP limit report Cached time: 20241123131435 Cache expiry: 86400 Reduced expiry: false Complications: [show鈥恡oc, no鈥恡oc鈥恈onversion] CPU time usage: 0.018 seconds Real time usage: 0.022 seconds Preprocessor visited node count: 301/1000000 Post鈥恊xpand include size: 11555/2097152 bytes Template argument size: 2102/2097152 bytes Highest expansion depth: 9/100 Expensive parser function count: 0/100 Unstrip recursion depth: 0/20 Unstrip post鈥恊xpand size: 493/5000000 bytes --> <!-- Transclusion expansion time report (%,ms,calls,template) 100.00% 13.778 1 -total 88.45% 12.186 1 Setting_Up_Lighttpd_With_FastCGI 46.42% 6.395 12 Template:Cmd 27.71% 3.818 6 Template:Pkg 17.10% 2.356 2 Template:Cat 15.01% 2.069 6 Template:Path --> <!-- Saved in parser cache with key wikidb:pcache:idhash:1925-0!canonical and timestamp 20241123131435 and revision id 26615. Rendering was triggered because: page-view --> </div> <div class="printfooter" data-nosnippet="">Retrieved from "<a dir="ltr" href="https://wiki.alpinelinux.org/w/index.php?title=DokuWiki&oldid=26615">https://wiki.alpinelinux.org/w/index.php?title=DokuWiki&oldid=26615</a>"</div></div> <div id="catlinks" class="catlinks" data-mw="interface"><div id="mw-normal-catlinks" class="mw-normal-catlinks"><a href="/wiki/Special:Categories" title="Special:Categories">Categories</a>: <ul><li><a href="/wiki/Category:Server" title="Category:Server">Server</a></li><li><a href="/wiki/Category:PHP" title="Category:PHP">PHP</a></li></ul></div></div> </div> </main> </div> <div class="mw-footer-container"> <footer id="footer" class="mw-footer" role="contentinfo" > <ul id="footer-info"> <li id="footer-info-lastmod"> This page was last edited on 26 March 2024, at 13:06.</li> <li id="footer-info-copyright"><div align="right"><div id="footer-inner"> <p><a href="https://wiki.alpinelinux.org/wiki/Alpine_Linux:Privacy_policy#License">© Original authors / CC-BY-SA-4.0</a> </div></div></li> </ul> <ul id="footer-places"> <li id="footer-places-privacy"><a href="/wiki/Alpine_Linux:Privacy_policy">Privacy policy</a></li> <li id="footer-places-about"><a href="/wiki/Alpine_Linux:About">About</a></li> <li id="footer-places-disclaimers"><a href="/wiki/Alpine_Linux:General_disclaimer">Disclaimers</a></li> </ul> <ul id="footer-icons" class="noprint"> <li id="footer-poweredbyico"><a href="https://www.mediawiki.org/"><img src="/w/resources/assets/poweredby_mediawiki_88x31.png" alt="Powered by MediaWiki" srcset="/w/resources/assets/poweredby_mediawiki_132x47.png 1.5x, /w/resources/assets/poweredby_mediawiki_176x62.png 2x" width="88" height="31" loading="lazy"/></a></li> </ul> </footer> </div> </div> </div> <script>(RLQ=window.RLQ||[]).push(function(){mw.config.set({"wgBackendResponseTime":103,"wgPageParseReport":{"limitreport":{"cputime":"0.018","walltime":"0.022","ppvisitednodes":{"value":301,"limit":1000000},"postexpandincludesize":{"value":11555,"limit":2097152},"templateargumentsize":{"value":2102,"limit":2097152},"expansiondepth":{"value":9,"limit":100},"expensivefunctioncount":{"value":0,"limit":100},"unstrip-depth":{"value":0,"limit":20},"unstrip-size":{"value":493,"limit":5000000},"timingprofile":["100.00% 13.778 1 -total"," 88.45% 12.186 1 Setting_Up_Lighttpd_With_FastCGI"," 46.42% 6.395 12 Template:Cmd"," 27.71% 3.818 6 Template:Pkg"," 17.10% 2.356 2 Template:Cat"," 15.01% 2.069 6 Template:Path"]},"cachereport":{"timestamp":"20241123131435","ttl":86400,"transientcontent":false}}});});</script> </body> </html>