]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/blob - doc/forum/laptop_wiki_with_git_-_but_the_other_way_around__63__.mdwn
(no commit message)
[git.ikiwiki.info.git] / doc / forum / laptop_wiki_with_git_-_but_the_other_way_around__63__.mdwn
1 Hey everyone, I have a local "laptop" wiki which uses git as it's version control system. I would like my wiki to be mirrored by my hoster (nearlyfreespeech) so I can browse and edit it on the go as well as have an offsite backup of it if my laptop should ever die. In the last three hours I figured out that:
3 1. I need to install ikiwiki on my nearlyfreespeech site
4 2. I need to create a remote for my local repository on my nfs site.
5 3. I need to setup ikiwiki on nfs
6 4. I need to mirror/sync continously my local laptop repo with the main repo on my server (probably through the remote)
8 So far I figured out parts of this plan. My status quo is the following:
10 - laptop:
11     - srcdir: ~/wiki
12     - destdir: ~/sites/wiki (this shouldn't matter since it points to my local webserver setup)
13     - repository: ~/wiki.git
14 - nfs:
15     - srcdir: /home/private/wiki
16     - destdir: /home/public
17     - repository: /home/private/2wiki.git
18     - remote repository: /home/private/wiki.git (configured as a remote named "nfswiki" on my laptop)
20 On my laptop I can now go into ~/wiki, edit some files and afterwards can invoke ikiwiki --setup ~/wiki.setup which will generate a local version of my site for me. If I want to update my server copy, I can go into ~/wiki do git add ., git commit -m "Update", git push nfswiki master (which I hope is the correct way of doing things???). Afterwards I should have a (bare) repo on my nfs server with the same contents as my local (bare) repo, since I setup my remote with my local (bare) repo, which gets updated whenever I update my working copy (= srcdir).
22 On my server I have installed ikiwiki more or less as described [here](https://ikiwiki.info/tips/nearlyfreespeech/). I setup this wiki by using the auto.setup method. It works. I basically have an empty wiki waiting to be filled.
24 But how do I now create the plumbing necessary to let me…
26 - connect the remote of my laptop repo to the nfs repo?
27 - connect the nfs repo to the laptop repo through my remote?
28 - edit either wiki (local/nfs) and the changes get synced to both wikis?
30 Here my sparse understanding (which is still a generous way to put it) of git is simply not enough.
32 Pages I have checked out:
34 - [nearlyfreespeech](https://ikiwiki.info/tips/nearlyfreespeech/)
35 - [distributed wikis](https://ikiwiki.info/tips/distributed_wikis/)
36 - [laptop wiki with git](https://ikiwiki.info/tips/laptop_wiki_with_git/)
37 - [byhand](https://ikiwiki.info/setup/byhand/)
38 - [setup](https://ikiwiki.info/setup/)
40 I'm very very thankful for any suggestions, since I have myself commited to solve any problems (and at least kinda understand what is involved here) to make this work at least to a degree that I can replicate the results in similar situations.
42 Thanks for reading and for any tips that you can offer towards making me understand this admittedly complicated and involved question.