The server's config file at $HOME/.camlistore/server-config.json is JSON. It can either be in simple mode (for basic configurations), or in low-level mode (for any sort of crazy configuration).
This page documents the simple configuration mode.
If you visit your Camlistore server's /setup page (by default, at http://localhost:3179/setup) you can modify the config file from your web browser and restart the server.
auth
: the authentication mechanism to use. Example values include:
none | No authentication. |
localhost | Accept connections coming from localhost. On Linux, this means connections from localhost that are also from the same user as the user running the server. |
userpass:alice:secret | HTTP basic authentication. Username "alice", password "secret". Only recommended if using HTTPS. |
userpass:alice:secret:+localhost | Same as above, but also accept localhost auth |
userpass:alice:secret:vivify=othersecret | Alice has password "secret", but her Android phone can use password "othersecret" to do a minimal set of operations (upload new things, but not access anything)r |
baseURL
: Optional. If non-empty, this is the root of your URL prefix for your Camlistore server. Useful for when running behind a reverse proxy. Should not end in a slash. e.g. https://yourserver.example.com
https
: if "true", HTTPS is used
HTTPSCertFile
: if using httpsHTTPSKeyFile
: if using httpsidentity
: your GPG fingerprint. A keypair is created for new users on start, but this may be changed if you know what you're doing.identitySecretRing
: your GnuPG secret keyring file. A new keyring is created on start for new users, but may be changed if you know what you're doing.listen
: The port (like "80" or ":80") or IP & port (like "10.0.0.2:8080") to listen for HTTP(s) connections on.shareHandler
: if "true", the server's sharing functionality is enabled, letting your friends have access to any content you've specifically shared.runIndex
: defaults to true. If "false", no search, no UI, no indexing. (These can be controlled at a more granular level by writing a low-level config file)Exactly one of these must be set:
blobPath
: local disk path to store blobss3
: "key:secret:bucket
" (with colons, but no quotes).Others aren't yet supported by the simple config mode. Patches
to pkg/genconfig
welcome.
Unless runIndex
is set to false
, exactly one of these must be set:
sqlite
: path to SQLite database file to use for indexingmongo
: user@host:passwordmysql
: user@host:passwordpostgres
: user@host:passwordAdditionally, mongo, mysql, and postgres require the dbname
value set. Initialize your database with camtool dbinit.
There's also an in-memory index type, but only in the low-level config, as used by the dev-server script.
Most configuration doesn't apply on App Engine as it's pre-configured to use the App Engine Blobstore and Datastore, as well as App Engine's user auth mechanisms. But as of 2013-06-12 we don't yet recommend running on App Engine; there are still some sharp corners.