Coevolving Innovations

… in Business Organizations and Information Technologies

A federated wiki site on cPanel

Since my cPanel shared hosting provider supports node.js hosting, installing a federated wiki site beside the usual Softaculous packages is an option. The app requires node.js, and there is a variety of ways to deploy that.

In 2014, I had installed a federated wiki site on Openshift, but then didn’t maintain it as other priorities surfaced.  The site is now available at http://wiki.coevolving.com, and the prior content has been restored.

The installation isn’t a one-button procedure.  However, an administator comfortable with opening an SSH terminal onto your shared hosting account should be able to follow the steps below.  (If you have problems, the federated wiki community hangs out in a room on matrix.org).

A. Creating a Subdomain

(1) Through your browser, from cPanel … Domains … , create a Subdomain.

  • As an example, I can create a Subdomain wiki in the Domain coevolving.com, that will actually be stored in my Home (Document Root) as a wiki.coevolving.com directory.

Subdomain_CreateASubdomain

B. Installing Federated Wiki

(2) From cPanel … Software … Setup Node.js App.

  • In the Web Applications list, Create Application.  As an example, set:
      • Node.js version: 10.11.0
      • Application mode: Production
      • Application root: wiki.coevolving.com
      • Application URL: wiki.coevolving.com
      • Application startup: app.js
  • (If you leave the Application startup field blank, app.js automatically fills in as the default)

NodeJs_CreateApplication

  • At this point, the node.js environment is not yet activated, as the package.json has not yet been downloaded, and the Run NPM Install button is greyed out.

WebApplications_EnterToTheVirtualEnvironment
(3) Open a terminal to your account.  Through a browser you could navigate to cPanel … Advanced … Terminal ; the more technically proficient will already know how to log in via SSH.

cPanel_Advanced_Terminal

(4) Download the current version of the federated wiki code, unzip it, and place it into a directory so that it can be installed with npm.

  • Change into the directory.  Transfer the current version of the fedwiki repository from the Github site to your host (curl option-L will redo the request if the location has changed; -o specifies the output file name).
cd wiki.coevolving.com 
curl -L https://github.com/fedwiki/wiki/archive/master.zip -o wiki-master.zip
  • List the file to ensure it’s downloaded (ls -lh gives a long, human-readable list).  Unzip it into a directory (unzip options -uo extracts newer versions of files already in the current directory and creates any files not already there; -d . specifies the target directory as the current directory) .
ls -lh wiki-master.zip 
unzip -uo wiki-master.zip -d .
  • List the directory to ensure that the wiki-master directory was created properly (and the package.json is in place).  Copy the contents from that now-unpacked directory up one level into the current direction (cp  -r recurses directories, -f forces overwrites; -p preserves datestamps; -v gives verbose information;).
ls
cp -rfpv wiki-master/* .

(5) If you had previously backed up a federated wiki, the content could now be restored.  Upload the file, and unpack the archive.

tar -xvpf archive_wiki.tar.gz
  • … with  tar options -x (extract); -v (verbose); -p, (preserve-permissions) ; -f  (file-archive).

(6) Personalizing the federated wiki requires (i) specifying where the data will be stored; (ii) setting up security; and (iii) setting up the site owner name.  For a single (or small number) of users, the friends plugin can invoked with the editing of config.json.

  • If a directory where the content will be stored hasn’t already been defined, create one, e.g. wiki.
mkdir wiki
  • Configure to use friends security, by editing a sample config.json …
cp config.json config-old.json
nano config.json
  • … with an initial config.json template that looks like …
{
"data": "....",
"security_type": "friends",
"cookieSecret": "some long random string (not this!!!!)",
"session_duration": "14"
}
  • … and can be modified to become …
{
"data": "/home/coXXXXXX/wiki.coevolving.com/wiki",
"security_type": "friends",
"cookieSecret": "my_cookieSecret_of_choice",
"session_duration": "14"
}
  • As a precaution, make a backup the new config.json:
cp config.json "$(date '+%Y-%m-%d')_config.json"
  • Configure the site with your own user name, by editing a sample owner.json
cp wiki/status/owner.json /wiki/status/owner-old.json
nano wiki/status/owner.json
  • … with an initial owner.json template that looks like …
{
"name": "Koheni",
"friend": {
"secret": "some long string that you use to reclaim write access"
}
}

… and can be modified to become …

{
"name": "daviding",
"friend": {
"secret": "my_write_access_secret"
}
}
  • As another precaution, backup the new owner.json
cp wiki/status/owner.json "$(date '+%Y-%m-%d')_owner.json"

(7) For the cPanel Web Application, the Application startup file is presumed to be app.js.  The downloaded package from Github assumed index.js, so let’s give the environment the filename it expects.

ls *.js
mv app.js app_old.js
cp index.js app.js

(8) With the federated wiki files now in the right position, the cPanel instruction to “Enter into the virtual environment” can be carried out.

source /home/coXXXXXX/nodevenv/wiki.coevolving.com/10/bin/activate
  • The source command is added to the command specified on the cPanel page, otherwise you’ll get the message “‘activate’ script should be sourced, not run directly”.

(9) Returning to cPanel in the browser, reloading the page should now detected the package.json configuration file, and Run NPM Install button should be available.

Run NPM Install button is available

  • Select the Run NPM Install button.  (Running npm install from the terminal doesn’t seem to give the same results, as loading the Welcome Visitors page in a browser will not be properly formatted).

C. Claiming the Wiki Site

(10) In your browser, navigate to your wiki page (e.g. wiki.coevolving.com).  At the bottom of the page, if you hover over the padlock, you should see a popup to “Reclaim this Wiki”

Reclaim this Wiki

  • Selecting the padlock should surface a panel, saying:

Welcome back <<yourname>>. Please enter your reclaim code to reconnect with your wiki.

  • With the “secret” you had entered in owner.json, the padlock icon should show as open.

(11) Your federated wiki should now be available for collecting pages across the federation, and co-editing.

D. Maintaining the Wiki Site

(12) Periodically, it might be prudent to prepare an offline archive of your federated wiki site.  On a terminal, pack a directory into a single file (tar with options -c (create); -v (verbose); -p (preserve-permissions); -z (compress to gzip); -f (filename)).

ls wiki
tar -cvpzf "$(date '+%Y-%m-%d'_wiki).tar.gz" wiki
  • Download a copy of that tar.gz file to your computer for safekeeping.  That backed up wiki directory will include the owner.json.
  • Download a copy of config.json.

My federated wiki site is at http://wiki.coevolving.com.

4 Comments

  • Interesting! Coincidentally, I’m currently setting up a personal wiki on my server that also is taking quite a bit of configuration to setup. Obviously the intent is very different since it’s completely private, but I’ll probably write a post about that soon.

  • Most of the directions for installing the software are applicable to updating to newer releases. To generalize the commands, I’ve changed …

    mv -v wiki-master/* .

    … to …

    cp -rfpv wiki-master/* .

    … so that some directories over properly overwritten.

  • Hi David!
    Thanks for the write up learned a lot even though I am not using CPanel.


Leave a Reply

Your email address will not be published. Required fields are marked *

  • RSS qoto.org/@daviding (Mastodon)

    • daviding: “Web video on "The Sustainable Development Goals: Origins, Co…” May 25, 2023
      Web video on "The Sustainable Development Goals: Origins, Context, and Perspectives" with Ned #NenadRava from @UN @JointSDGFund in discussion with #SystemsThinking Ontario. https://coevolving.com/blogs/index.php/archive/sdgs-origins-context-perspectives-st-on-2023-05-08/ #SDGs #Sustainability #Development
    • daviding: “> Leading #TVO Today’s Asian Heritage Month lineup for May 2…” May 7, 2023
      > Leading #TVO Today’s Asian Heritage Month lineup for May 2023, TVO Original Big Fight in Little Chinatown premieres on TVO, TVO Today, YouTube and smart TV services on Tuesday, May 9 at 9 pm ET.https://tvo.me/energized-communities-battle-developer-pressure-and-anti-asian-racism-in-tvo-original-big-fight-in-little-chinatown/
    • daviding: “Rereading the introduction to the 1969 _Systems Thinking: Se…” May 3, 2023
      Rereading the introduction to the 1969 _Systems Thinking: Selected Readings_ Penguin paperbook surfaces some choices by the editor #FredEEmery that I hadn&apos;t previously appreciated. https://ingbrief.wordpress.com/2023/05/03/introduction-systems-thinking-selected-readings-edited-by-f-e-emery-1969/ #SystemsThinking #LivingSystems #opensystems
    • daviding: “The "doable dozen" is a phrase that #BjornLomborg picked up …” April 27, 2023
      The "doable dozen" is a phrase that #BjornLomborg picked up from #JordanPeterson on the April 3 interview. The list is now more complete at Halftime for the Sustainable Development Goals microsite at https://www.copenhagenconsensus.com/halftime> The 12 best policies to scale up, that our experts have identified, cover a wide range of areas: tuberculosis, education, maternal and […]
    • daviding: “A series of articles by #BjornLomborg with leading media out…” April 27, 2023
      A series of articles by #BjornLomborg with leading media outlets has been lined up. This article in Forbes sets a direction. > But in 2015, when the world replaced the #MDGs [#MillenniumDevelopmentGoals], things went wrong. World leaders could again have chosen to focus on a few, crucial targets. They could even have kept the same […]
  • RSS on IngBrief

    • Introduction, “Systems Thinking: Selected Readings, volume 2”, edited by F. E. Emery (1981)
      The selection of readings in the “Introduction” to Systems Thinking: Selected Readings, volume 2, Penguin (1981), edited by Fred E. Emery, reflects a turn from 1969 when a general systems theory was more fully entertained, towards an urgency towards changes in the world that were present in 1981. Systems thinking was again emphasized in contrast […]
    • Introduction, “Systems Thinking: Selected Readings”, edited by F. E. Emery (1969)
      In reviewing the original introduction for Systems Thinking: Selected Readings in the 1969 Penguin paperback, there’s a few threads that I only recognize, many years later. The tables of contents (disambiguating various editions) were previously listed as 1969, 1981 Emery, System Thinking: Selected Readings. — begin paste — Introduction In the selection of papers for this […]
    • Concerns with the way systems thinking is used in evaluation | Michael C. Jackson, OBE | 2023-02-27
      In a recording of the debate between Michael Quinn Patton and Michael C. Jackson on “Systems Concepts in Evaluation”, Patton referenced four concepts published in the “Principles for effective use of systems thinking in evaluation” (2018) by the Systems in Evaluation Topical Interest Group (SETIG) of the American Evaluation Society. The four concepts are: (i) […]
    • Quality Criteria for Action Research | Herr, Anderson (2015)
      How might the quality of an action research initiative be evaluated? — begin paste — We have linked our five validity criteria (outcome, process, democratic, catalytic, and dialogic) to the goals of action research. Most traditions of action research agree on the following goals: (a) the generation of new knowledge, (b) the achievement of action-oriented […]
    • Western Union and the canton of Ticino, Switzerland
      After 90 minutes on phone and online chat with WesternUnion, the existence of the canton of Ticino in Switzerland is denied, so I can’t send money from Canada. TicinoTurismo should be unhappy. The IT developers at Western Union should be dissatisfied that customer support agents aren’t sending them legitimate bug reports I initially tried the […]
    • Aesthetics | Encyclopaedia Britannica | 15 edition
      Stephen C. Pepper was a contributor to the Encyclopaedia Britannica, 15th edition, on the entry for Aesthetics.
  • Recent Posts

  • Archives

  • RSS on daviding.com

    • 2023/05 Moments May 2023
      Spring full of cultural and family activities.
    • 2023/04 Moments April 2023
      Sightseeing one day in Vilnius, then variable weather in spring in Toronto.
    • 2023/03 Moments March 2023
      Right ring finger in splint discouraged activities, yet last week of month saw flying through Vienna to an intensive research visit to Kaunas University of Technology in Lithuania.
    • 2023/02 Moments February 2023
      Recovery from bike collision with automobile hit-and-run reduced exercise, while continuing social activities.
    • 2023/01 Moments January 2023
      Family time for solar new year and lunar year, otherwise at home writing a journal manuscript for a deadline, and focused on improving wellness.
    • 2022/12 Moments December 2022
      December was full of birthday, wedding, seasonal holiday events, and then family congregated in town to share time together.
  • RSS on Media Queue

    • 2021/06/17 Keekok Lee | Philosophy of Chinese Medicine 2
      Following the first day lecture on Philosophy of Chinese Medicine 1 for the Global University for Sustainability, Keekok Lee continued on a second day on some topics: * Anatomy as structure; physiology as function (and process); * Process ontology, and thing ontology; * Qi ju as qi-in-concentrating mode, and qi san as qi-in-dissipsating mode; and […]
    • 2021/06/16 Keekok Lee | Philosophy of Chinese Medicine 1
      The philosophy of science underlying Classical Chinese Medicine, in this lecture by Keekok Lee, provides insights into ways in which systems change may be approached, in a process ontology in contrast to the thing ontology underlying Western BioMedicine. Read more ›
    • 2021/02/02 To Understand This Era, You Need to Think in Systems | Zeynep Tufekci with Ezra Klein | New York Times
      In conversation, @zeynep with @ezraklein reveal authentic #SystemsThinking in (i) appreciating that “science” is constructed by human collectives, (ii) the west orients towards individual outcomes rather than population levels; and (iii) there’s an over-emphasis on problems of the moment, and…Read more ›
    • 2019/04/09 Art as a discipline of inquiry | Tim Ingold (web video)
      In the question-answer period after the lecture, #TimIngold proposes art as a discipline of inquiry, rather than ethnography. This refers to his thinking On Human Correspondence. — begin paste — [75m26s question] I am curious to know what art, or…Read more ›
    • 2019/10/16 | “Bubbles, Golden Ages, and Tech Revolutions” | Carlota Perez
      How might our society show value for the long term, over the short term? Could we think about taxation over time, asks @carlotaprzperez in an interview: 92% for 1 day; 80% within 1 month; 50%-60% tax for 1 year; zero tax for 10 years.Read more ›
    • 2020/07/13 “Making Growing Thinking” |Tim Ingold (web video)
      For the @ArchFoundation, #TimIngold distinguishes outcome-oriented making from process-oriented growing, revisiting #MartinHeidegger “Building Dwelling Thinking”. Organisms are made; artefacts grow. The distinction seems obvious, until you stop to ask what assumptions it contains, about the inside and outside of things…Read more ›
  • Meta

  • Creative Commons License
    This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License
    Theme modified from DevDmBootstrap4 by Danny Machal