1.0 release branch. The last release with the original darcsden UI style
darcsden is a darcs repository hosting platform, providing a web application for browsing and managing repos, users, and issues, and a SSH server for push/pull and quick repository creation.
"cabal install darcsden" will install darcsden and darcsden-ssh executables with generic settings. In particular, the web app's base url will be "http://localhost:8900", and multi-user features will be enabled.
For more control, get the darcsden source, adjust src/DarcsDen/Settings.hs, and run "cabal install" in the top source directory. There are also several optional build flags in darcsden.cabal, mainly to assist with building on windows.
To run darcsden you also need:
- Redis (for storing web session data)
- CouchDB (for storing user/repo/repository data)
Both should be running on their default port, or you can change that in Settings.hs. You should configure them by running:
You should have a "darcsden" user account (for running the app and owning the files), with a ssh key:
adduser --system --home /home/darcsden --shell /bin/bash --group --gecos DarcsDen darcsden sudo -u darcsden ssh-keygen
To avoid obscure errors due to mixed file ownership in ~/.darcs/cache, always run darcsden as the darcsden user, with $HOME set properly. So if using sudo, include the -H flag, like this:
sudo -Hu darcsden COMMAND...
The directory where you start the web app should contain darcsden's public/ directory. Or you can run it behind a web server that'll serve /public/* requests from that directory.
For a quick test, run:
sudo -Hu darcsden darcsden
and visit http://localhost:8900 (or other url configured in Settings.hs) in your web browser.
This package provides separate executables for the web and SSH servers,
darcsden-ssh respectively. You could run them manually while logged in as the
darcsden user via screen or dtach. Or, configure them as daemons. See
darcsden.god, or these sample supervisord.conf entries:
[program:darcsden] command=sudo -Hu darcsden /path/to/darcsden --port 8900 directory=/home/darcsden priority=3 redirect_stderr=true autostart=true autorestart=true environment=LANG="en_US.UTF-8" [program:darcsden-ssh] command=sudo -Hu darcsden /path/to/darcsden-ssh 22 directory=/home/darcsden priority=3 redirect_stderr=true autostart=true autorestart=true environment=LANG="en_US.UTF-8"
Here's a sample apache vhost config:
<VirtualHost *:80> ServerName my.host.name RewriteEngine on ProxyPreserveHost On ProxyErrorOverride On RewriteRule ^/(.*) http://127.0.0.1:8900/$1 [P] </VirtualHost>
darcsden has a small, clean codebase and is fun to hack on. As an example, here's how to contribute a patch to hub.darcs.net's darcsden branch:
- register at hub.darcs.net, add your ssh key in settings
- fork http://hub.darcs.net/simon/darcsden
- darcs get http://hub.darcs.net/yourname/darcsden
- (edit, record)
- darcs push firstname.lastname@example.org:darcsden
- your change appears at http://hub.darcs.net/simon/darcsden/patches and will be merged, or discussed via email or IRC.
We hope to see you on #darcs, and many patches in the queue !
Alex Suraci created darcsden. Simon Michael led this release, with help from Ganesh Sittampalam, Guillaume Hoffmann, Niklas Haas, Daniel Patterson and Scott Lawrence. darcsden depends on Darcs, Snap, GHC, and the rest of the Haskell ecosystem.