{"schema":"libjg2-1",
"vpath":"/git/",
"avatar":"/git/avatar/",
"alang":"",
"gen_ut":1750313831,
"reponame":"gitohashi",
"desc":"Git web frontend with clientside rendering",
"owner": { "name": "Andy Green", "email": "andy@warmcat.com", "md5": "c50933ca2aa61e0fe2c43d46bb6b59cb" },"url":"https://warmcat.com/repo/gitohashi",
"f":3,
"items": [
{"schema":"libjg2-1",
"cid":"306803551dddb4d1fe2ab7f45e7575c4",
"commit": {"type":"commit",
"time": 1580284775,
"time_ofs": 0,
"oid_tree": { "oid": "b561e5ab28fcfeeb8d4e48453ab6c16a2e03255a", "alias": []},
"oid":{ "oid": "38fa7e59282e5d6b0ee06c74c1f4c60ba5a2892f", "alias": []},
"msg": "docs: clarify some setup issues and remove lingering references to libjsongit2",
"sig_commit": { "git_time": { "time": 1580284775, "offset": 0 }, "name": "Andy Green", "email": "andy@warmcat.com", "md5": "c50933ca2aa61e0fe2c43d46bb6b59cb" },
"sig_author": { "git_time": { "time": 1580284775, "offset": 0 }, "name": "Andy Green", "email": "andy@warmcat.com", "md5": "c50933ca2aa61e0fe2c43d46bb6b59cb" }},
"body": "docs: clarify some setup issues and remove lingering references to libjsongit2"
,
"diff": "diff --git a/README.md b/README.md\nindex 12eb370..84122df 100644\n--- a/README.md\n+++ b/README.md\n@@ -1,12 +1,17 @@\n [](https://travis-ci.org/warmcat/gitohashi) [](https://scan.coverity.com/projects/gitohashi) [](https://www.codacy.com/app/lws-team/gitohashi?utm_source\u003dgithub.com\u0026amp;utm_medium\u003dreferral\u0026amp;utm_content\u003dwarmcat/gitohashi\u0026amp;utm_campaign\u003dBadge_Grade)\n \n-gitohashi\n----------\n+gitohashi Gitweb daemon\n+-----------------------\n \n Lightweight C Daemon that provides HTTP network transport and HTML presentation\n-via a JSON representation of bare git repositories discovered via gitolite.\n-Supports http/1, http/2 and unix socket (proxiable by, eg, apache \u0026 lighttpd)\n-serving, avatar proxy caching and many other features.\n+via a JSON representation of bare git repositories discovered via gitolite and\n+accessed via libgit2.\n+\n+Supports http/1, http/2 and unix socket (proxiable by, eg, apache, lighttpd or\n+libwebsocket's own lwsws) serving, avatar proxy caching and many other features.\n+\n+You can find real deployments at, eg, https://libwebsockets.org/git and\n+https://warmcat.com/git .\n \n \n \n@@ -23,13 +28,13 @@ serving, avatar proxy caching and many other features.\n serve locally on per-vhost unix socket for integration with existing Apache /\n lighttpd etc server + mod_proxy\n \n- - Only configuration per-vhost needed, the repo configuration is controlled\n- from gitolite config.\n+ - Only needs configuration per-vhost in JSON, the repo configuration and\n+ access control is taken from gitolite config.\n \n - Clientside JS, CSS and HTML are provided, along with Markdown parsing\n- and syntax highlighting JS to present the JSON + HTML from libjsongit2 in\n- a modern and responsive way. SVG icons provided. Customizing the css and\n- HTML template encouraged.\n+ and syntax highlighting JS to present the JSON + HTML in a modern and\n+ responsive way. SVG icons provided. Customizing the css and HTML\n+ template encouraged.\n \n - Transparent caching at JSON block level, keyed using global repository ref\n state... cache invalidated when any ref updated. ETAG browser cache\n@@ -39,7 +44,7 @@ serving, avatar proxy caching and many other features.\n - Multiple vhosts natively supported; each can have their own template html /\n css and gitolite ACL \u0022user\u0022 name for automatic repo permissions\n \n- - Safe gravatar proxy cache, no referrer leaks\n+ - Safe gravatar proxy cache, served locally, no referrer leaks\n \n - Very modest on memory, Valgrind-clean, Coverity-clean, works great on a\n Raspberry Pi 3\n@@ -51,7 +56,7 @@ serving, avatar proxy caching and many other features.\n - Strict Content-Security-Policy out of the box, default-deny, 'self' and\n whitelisted img sources only (travis status etc). \n \n- - Dynamically linked - binds to distro system libs\n+ - Dynamically linked - binds to distro system libs to stay up to date\n \n # Getting Started\n \n@@ -74,6 +79,22 @@ This contains JSON configuration files for two example gitohashi vhosts, one\n directly serving on :443 over https and the other serving on a unix domain\n socket for integration with another server.\n \n+You'll need to amend, eg, the path to the gitolite repository base dir.\n+\n+If you are setting that up too, don't forget to create a bare test repo **and\n+push content to it so gitohashi has something to display**.\n+\n+You'll need to ensure the gitohashi daemon runs with permissions that allow it\n+at least read access to the directories and files in the gitolite repository.\n+\n+For example if the repository is owned by a user 'git', you can choose to run\n+gitohashi under the same user. If that makes problems due to, eg, selinux,\n+another more complex way is run gitohashi as apache, and set the repositor\n+base dir and underneath to be git:apache and set the \u0022sticky bit\u0022 so the\n+group is inherited. This also requires `git config` to be set up to have\n+`sharedRepository \u003d group`, gitolite config is able to force this in the\n+bare repo config it manages using `config core.sharedRepository \u003d group`\n+\n ### Startup\n \n The gitohashi `make install` adds a systemd service file, so you can manage it\n@@ -137,7 +158,7 @@ gitohashi installs its `./assets` directory into\n asset|function\n ---|---\n inconsolata.ttf|Web font for nice monospaced content\n-jg2.js|The clientside part of libjsongit2 that turns the JSON into HTML\n+jg2.js|The clientside part that turns the JSON into HTML\n jg2.css|Helper CSS for formatting jg2.js output\n logo.css|CSS SVG Image included by the example template HTML\n gitohashi-custom.css|CSS overrides related to the custom HTML template (normally served from wherever the HTML template is served from)\n@@ -160,10 +181,10 @@ path:\n \n - you must serve that dir somehow over HTTP so the client browser can get at\n the rest of the assets mentioned in the HTML. (The HTML is provided\n- directly by libjsongit2 in sandwich mode, but the other assets are collected\n+ directly by gitohashi in sandwich mode, but the other assets are collected\n by the client browser over HTTP). The provided HTTP template\n assumes it's served from the same server at the virtual path\n- \u0022/git/_gitohashi\u0022, but you can change that as needed.\n+ `/git/_gitohashi`, but you can change that as needed.\n \n Caching policy in your HTTP server for the assets can be relaxed, since they\n will normally only change when gitohashi it updated.\n@@ -171,11 +192,11 @@ will normally only change when gitohashi it updated.\n ### Integration with gitolite v3\n \n Gitohashi tries to require as little configuration as possible. One big help\n-with that is it can use libjsongit2's ability to parse gitolite ACLs from the\n-same repo base directory. That allows you to use gitolite config to control\n-which repos gitohashi can access and set information about them.\n+with that is it can use parse gitolite ACLs from the same repo base directory.\n+That allows you to use gitolite config to control which repos gitohashi can\n+access and set information about them.\n \n-Full details: [README-gitolite.md](https://warmcat.com/git/libjsongit2/tree/doc/README-gitolite.md) \n+Full details: [README-gitolite.md](./doc/README-gitolite.md) \n \n ## Caching in gitohashi\n \n@@ -202,7 +223,7 @@ directly.\n \n For these reasons gitohashi includes a smart server-side avatar cache.\n \n-It's not a generic proxy cache, libjsongit2 informs gitohashi when it generates\n+It's not a generic proxy cache, gitohashi knows when it specifically generates\n JSON mentioning an identity, and the avatar cache fetches the related avatar if\n it's not already in the cache. The avatar cache is exposed in a mount serving\n static files with a user-controllable cache policy (which you can set to days\n@@ -215,13 +236,10 @@ the third-party avatar provider and so no privacy issues.\n \n ### Transparent JSON Cache\n \n-libjsongit2 has a sophisticated transparent JSON cache described in detail in\n-its README\n-\n-https://warmcat.com/git/libjsongit2\n+Gitohashi has a sophisticated transparent JSON cache.\n \n Cache entries are invalidated when the related repo's refs\n-change; libjsongit2 maintains a hash of all refs in a repo for this purpose.\n+change; gitohashi maintains a hash of all refs in a repo for this purpose.\n \n It means that deprecated repos nobody pushes to will keep their caches\n unless the size limit is reached and the cache content is reaped according to\n@@ -249,8 +267,6 @@ understands ETAGs and will reply with a HTTP response code indicating the\n cached object is unchanged, renewing the clientside cache copy without having\n to resend any content.\n \n-Gitohashi understands etags, \n-\n ## Notes on developing with gitohashi\n \n 1. You can run gitohashi from the commandline with sudo, but you must\n@@ -268,6 +284,12 @@ $ sudo HOME\u003d/tmp valgrind --leak-check\u003dfull --show-leak-kinds\u003dall /usr/local/bin\n $ sudo HOME\u003d/tmp valgrind gdb --ex r --args /usr/local/bin/gitohashi\n ```\n \n+## Serving git protocol over https\n+\n+Gitohashi only does gitweb, which is unrelated to git's optional read-only\n+https protocol access. Git's own `git-http-backend` should be used as a\n+CGI to serve git https protocol.\n+\n ## XSS mitigation\n \n ### Making the most of Content-Security-Policy\n@@ -321,12 +343,6 @@ See https://warmcat.com/git/gitohashi/tree/xss/xss.c\n \n ## Upstreams and licenses\n \n-### libjsongit2\n-\n-LGPL2.1+SLE\n-\n-https://warmcat.com/git/libjsongit2\n-\n ### libwebsockets\n \n LGPL2.1+SLE\ndiff --git a/lib/README.md b/lib/README.md\nindex 8dbf649..da848bf 100644\n--- a/lib/README.md\n+++ b/lib/README.md\n@@ -1,8 +1,7 @@\n-## libjsongit2 library sources\n+## gitohashi library sources\n \n Dir|Function\n ---|---\n conf|Sources related to parsing configuration from git config or gitolite\n email|Sources related to md5 and email avatar handling\n job|Sources related to generating JSON for different types of URL\n-lac|Linear Alloc Chunk helpers\n","s":{"c":1750313831,"u": 963}}
],"g": 3031,"chitpc": 0,"ehitpc": 0,"indexed":0
,
"ab": 0, "si": 0, "db":0, "di":0, "sat":0, "lfc": "0000"}