diff --git a/data/media/howto/getting_started/site-starter-home-page-snapshot.png b/data/media/howto/getting_started/site-starter-home-page-snapshot.png new file mode 100644 index 00000000..cd053d13 Binary files /dev/null and b/data/media/howto/getting_started/site-starter-home-page-snapshot.png differ diff --git a/data/pages/howto/getting_started/1_dokuwiki.txt b/data/pages/howto/getting_started/1_dokuwiki.txt index 2a0162a1..9f9ebe98 100644 --- a/data/pages/howto/getting_started/1_dokuwiki.txt +++ b/data/pages/howto/getting_started/1_dokuwiki.txt @@ -5,36 +5,127 @@ { "path": ":wiki:markup_docs:getting_started:1_dokuwiki" }, { "path": ":wiki:markup_getting_started:1_dokuwiki" } ], - "name": "Dokuwiki Installation", - "page_id": "52gxusbx7sb0v76bgvn9v", - "template": "holy", - "title": "How to install Dokuwiki ?" + "name": "Dokuwiki Up and Running", + "page_id": "52gxusbx7sb0v76bgvn9v" } --- -====== ComboStrap Getting Started - Dokuwiki Instance ====== +====== How to get DokuWiki Up and Running? ====== ===== About ===== -Because [[:combostrap|ComboStrap]] is built on top of the [[doku>|Dokuwiki Engine]], the first step is to have a DokuWiki Installation. +Because [[:combostrap|ComboStrap]] is built on top of the [[doku>|Dokuwiki Engine]], the first step is to have a DokuWiki app up and running. +This article will show you how. -We supports two kind of installation: - * [[#Docker|Docker]] - our image that comes with battery included - * [[#server|Standalone Server]] - on a raw server +===== Docker / Server ===== -===== Type ===== +This tutorial series uses our [[:docs:admin:docker|Docker image]] for consistency +but if you have a standalone server and want to install DokuWiki on it, you can also follow this [[howto:server_installation:start|tutorial series]]. -==== Docker ==== +===== Steps ===== -We recommend greatly to start with [[#docker|Docker]] as: +We recommend greatly to use our [[:docs:admin:docker|DokuWiki in Docker image]] as: * it's the easiest way to get DokuWiki up and running * it contains all performance cache system (php-fpm and opcache) - * a Server DokuWiki installation is not easy and straightforward. + * a Server DokuWiki installation is not easy and straightforward + * and [[:docs:admin:docker#features|more]]. -==== Server ==== +==== Install Docker ==== -To get DokuWiki on a server, you can follow this [[howto:server_installation:start|installation tutorial]] +Download the Docker binary or install a package as explained on this [[https://docs.docker.com/engine/install/|article]]. + + +==== On Windows? ==== + +On Windows, you need to install WSL by following this [[https://learn.microsoft.com/en-us/windows/wsl/install|instructions]]. +Why? Because Php is still a Linux and C technology that is really slow on Windows. This is architectural as explained on [[https://github.com/docker/for-win/issues/6742|this issue]] + +==== Create a data directory ==== + * Create a directory to store the DokuWiki Data + +mkdir -p ~/site-combo-starter + + * And go into it to change the current directory + +cd site-combo-starter + + +==== Start DokuWiki in Docker ==== + +Start a DokuWiki Docker Instance with the following command. + +docker run \ + --name site-combo-starter \ + --rm \ + -p 8080:80 \ + --user 1000:1000 \ + -e DOKU_DOCKER_ACL_POLICY='public' \ + -e DOKU_DOCKER_ADMIN_NAME='admin' \ + -e DOKU_DOCKER_ADMIN_PASSWORD='welcome' \ + -v $PWD:/var/www/html \ + ghcr.io/combostrap/dokuwiki:php8.3-latest + +where: + * ''DOKU_DOCKER_ACL_POLICY='public''' will configure a wiki that can only be seen by the public. You need to login to modify it. + * ''DOKU_DOCKER_ADMIN_NAME='admin''' create a user named ''admin'' with the ''admin'' permission. + * ''DOKU_DOCKER_ADMIN_PASSWORD='welcome''' is the password of the admin user + * ''%%-v $PWD:/var/www/html%%'' mount your current directory ''PWD'' into the image at the HTML server root ''/var/www/html'' + * ''--user 1000:1000'' will create file as if it were you creating them. The user ''1000'' is the UID of your Desktop user (in Windows WSL at least) + + + + + + +==== Check that the instance has started ==== + +The command above will: + * start php, + * install DokuWiki, + * install the [[https://github.com/ComboStrap/site-starter|starter site]] + * and is ready when you see this lines: + +INFO success: caddy entered RUNNING state, process has stayed up for > than 1 seconds (startsecs) +INFO success: php_error_log entered RUNNING state, process has stayed up for > than 1 seconds (startsecs) +INFO success: php_fpm entered RUNNING state, process has stayed up for > than 1 seconds (startsecs) + + * You can then access DokuWiki at http://localhost:8080 + +{{:howto:getting_started:site-starter-home-page-snapshot.png?600|}} + + + +=== How to stop the instance === + +If you want to stop the instance: + * you can press ''Control+C'' with your keyboard in the current terminal + * Or you can open another terminal and stop it with the following command + +docker stop site-combo-starter + + + + +==== Login ==== + + +Go to the [[http://localhost:8080/?do=login|login page]]: http://localhost:8080/?do=login + +And enter the credentials: + * user: ''admin'' + * password: ''welcome'' + + + + +===== Next Step ===== + +In the next step, you will learn to install a ''favicon'' + + \ No newline at end of file diff --git a/data/pages/howto/getting_started/6_favicon.txt b/data/pages/howto/getting_started/6_favicon.txt index e3b52d51..9e85ec3c 100644 --- a/data/pages/howto/getting_started/6_favicon.txt +++ b/data/pages/howto/getting_started/6_favicon.txt @@ -37,7 +37,8 @@ In our case we have chosen an icon directly from https://materialdesignicons.com ==== Upload the favicons ==== - * Then upload the below icon files with the [[doku>media_manager|media manager]] to the root location (ie DOKUWIKI_HOME/data/media/) + * Then upload the below icon files with the [[http://localhost:8080/start?ns=&tab_files=files&do=media|Media Manager]] (([[doku>media_manager|media manager]])) to the root location (ie DOKUWIKI_HOME/data/media/) + * Click on this link [[http://localhost:8080/start?ns=&tab_files=files&do=media]] and upload the following files * ''favicon.ico'' * ''favicon-32x32.png'' * ''favicon-16x16.png'' @@ -80,15 +81,24 @@ The [[docs:social:facebook|facebook page]] will tell your more about the specifi {{strap:favicon_verification.png|}} -==== OpenSearch Favicon ==== - -In the [[docs:app:search|open search]], unfortunately, the icon is the icon of the template and is [[https://github.com/dokuwiki/dokuwiki/blob/master/lib/exe/opensearch.php#L17|hardcoded]], there is nothing we can do to change it at this place. -We still advertise it via [[:docs:type:website#internal_search_engine|sitelinks]] to search engines. -If you want it also at this place, you need to put it manually on the server at ''%%$DOKUWIKI_HOME/lib/tpl/dokuwiki/images/favicon.ico%%''. ==== Next Step ==== -[[7_menu|Create a menu]] +[[7_menu|Create a top navigation menu]] + +\\ +\\ +\\ + +===== Support ===== + +==== OpenSearch Favicon ==== + +In the [[docs:app:search|open search]], unfortunately, the icon is the icon of the template and is [[https://github.com/dokuwiki/dokuwiki/blob/master/lib/exe/opensearch.php#L17|hardcoded]], there is nothing we can do to change it at this place. + +We advertise it via [[:docs:type:website#internal_search_engine|sitelinks]] to search engines. + +Most of the search engine, support it this ways, if you really **really** want it, you need to put it manually at ''%%$DOKUWIKI_HOME/lib/tpl/dokuwiki/images/favicon.ico%%''. diff --git a/data/pages/howto/getting_started/7_menu.txt b/data/pages/howto/getting_started/7_menu.txt index f22dcc27..048f7b9b 100644 --- a/data/pages/howto/getting_started/7_menu.txt +++ b/data/pages/howto/getting_started/7_menu.txt @@ -22,15 +22,12 @@ This is where we will create a [[docs:menubar:menubar|menu bar]]. ===== Steps===== - * Create a page called '':slot_header'' at the [[:docs:page:system:home|home level]] . ie, with the following URL: - -http://yourdomain.com/doku.php?id=slot_header - - * Enter the below [[docs:menubar:menubar|menu bar]] example - + * Go to this URL http://localhost:8080/doku.php?id=slot_header to create a page called '':slot_header'' at the [[:docs:page:system:home|home level]] + * You will see the [[docs:menubar:menubar|menu bar]] of the starter site. - -If you have uploaded a icon in the [[6_favicon|Favicon step]], a minimal ''header slot'' with a [[docs:menubar:menubar|menu bar]] would look like: +You can: + * modify it + * or enter a more complicated example. If you have uploaded a icon in the [[6_favicon|Favicon step]], a minimal ''header slot'' with a [[docs:menubar:menubar|menu bar]] would look like: @@ -57,11 +54,11 @@ My Brand name More ... see the [[docs:menubar:menubar|menu bar page]] ===== Next Steps ===== -In the same way, you can also modify the [[docs:theme:element:page-footer|page footer]]. -Then you can: - * Check the [[docs:component|UI Components]] - * Learn about [[docs:router:router|Routing and redirections]] - * Have a look at the [[docs:seo:seo|SEO page]] +In the same way, you can also modify the [[docs:theme:element:page-footer|page footer]] with the following link: http://localhost:8080/doku.php?id=slot_footer + +In the next step, we will store your site as combo site in Git. -For more tips and tops, you can also [[:newsletter|subscribe to the newsletter]]. + \ No newline at end of file diff --git a/data/pages/howto/getting_started/8_git.txt b/data/pages/howto/getting_started/8_git.txt new file mode 100644 index 00000000..e57f96f0 --- /dev/null +++ b/data/pages/howto/getting_started/8_git.txt @@ -0,0 +1,119 @@ +---json +{ + "aliases": [ + { "path": ":howto:getting_started:5_git" } + ], + "name": "Git Site", + "page_id": "4335hckjomaayfepj2m1v" +} +--- +====== How to store your site in Git? ====== + + +===== About ===== +This page will show you how to store your site as [[:docs:admin:website|combo site]] in a remote Git repository. + + +===== Steps ===== + +==== Create a remote Git Repository ==== +We will be using [[https://github/com|GitHub]] as example but you can use any Git Repository Provider such as [[https://gogs.io/|Gogs]], [[https://gitlab.com|GitLab]] or [[https://gitea.com/|Gitea]]. + +For GitHub, follow this [[https://docs.github.com/en/repositories/creating-and-managing-repositories/creating-a-new-repository|article]] to create your new repository. + + + + + + +==== Create a local Git Repository ==== + +In the directory that was used with the [[howto:getting_started:1_dokuwiki|docker command]], initialize a Git repository + +cd /tmp/site-combo-starter +# Init (ie create ) a local repo +git init + + * Rename the master branch to main + +git branch -M main + + +==== Add the Git remote ==== + + * Add the URL of your repository as origin + +git remote add origin https://github.com/ComboStrap/site-starter.git + + +==== Check the untracked files ==== + + +git status + + +On branch main + +No commits yet + +Untracked files: + (use "git add ..." to include in what will be committed) + .gitattributes + .gitignore + README.md + conf/ + data/ + docs/ + lib/ + robots.txt + +nothing added to commit but untracked files present (use "git add" to track) + +==== Add the combo site files ==== + +Add them all + +git add . + + +==== Create your first commit ==== + + * Create a commit + +git commit -m "First commit" + + +==== Push them to your remote repository ==== + + * Push + +git push -u origin main +# enter your credentials +# or use SSH Keys (https://docs.github.com/en/authentication/connecting-to-github-with-ssh) + + +Enumerating objects: 45, done. +Counting objects: 100% (45/45), done. +Delta compression using up to 16 threads +Compressing objects: 100% (36/36), done. +Writing objects: 100% (45/45), 50.71 KiB | 10.14 MiB/s, done. +Total 45 (delta 1), reused 0 (delta 0), pack-reused 0 +remote: Resolving deltas: 100% (1/1), done. +To github.com:ComboStrap/site-starter.git + * [new branch] main -> main +branch 'main' set up to track 'origin/main'. + + +===== Next ===== + +You can now develop, change your wiki and push your change to your Git Repository. + +Then you can: + * Check the [[docs:component|UI Components]] + * Learn about [[docs:router:router|Routing and redirections]] + * Have a look at the [[docs:seo:seo|SEO page]] + +For more tips and tops, you can also [[:newsletter|subscribe to the newsletter]]. + + + diff --git a/data/pages/howto/getting_started/getting_started.txt b/data/pages/howto/getting_started/getting_started.txt index ccaf5481..fb1a7ea7 100644 --- a/data/pages/howto/getting_started/getting_started.txt +++ b/data/pages/howto/getting_started/getting_started.txt @@ -28,6 +28,7 @@ This ''how-to'' guide regroups a series of article to get you started. - [[1_dokuwiki]] - [[6_favicon]] - [[7_menu]] + - [[5_git]] ===== Start ===== diff --git a/data/pages/howto/getting_started/sidebar.txt b/data/pages/howto/getting_started/sidebar.txt index 6088f6ff..e965e2a5 100644 --- a/data/pages/howto/getting_started/sidebar.txt +++ b/data/pages/howto/getting_started/sidebar.txt @@ -1 +1 @@ - \ No newline at end of file +