-
Notifications
You must be signed in to change notification settings - Fork 136
Tip: Running Local Crypton Server
Using a public crypton server is a hassle for development, because e.g. you don't have the option to clear it at will. Running a local crypton server used to be more complicated, but still has deserves some guidance. Here's some tips on getting it going:
- Local crypton clone, fetched and built - follow the instructions in the README.md
- Redis installed locally (or remote access to a redis server, but then you're depending again)
- Postgresql installed locally (or remote access to a postgresql server, but...)
- Start the redis server:
/usr/local/bin/redis-server &
- Start postegresql. (I use it on the mac, start it using spotlight.)
- To start the crypton server:
-
You should first install the
crypton-server
command in /usr/local/bin, via:make install
-
Then:
crypton-server run
- run the server as a foreground commandAlternately,
crypton-server start
- launches server as a daemonThen,
crypton-server tail
tails the logs, usecrypton-server logs
to review the accumulated logs... Usecrypton-server --help
to see the list of all available commands.
-
- Stop the crypton server process - cleaning the test db fails if the crypton server is running
- Make sure the postgresql server is running
- From the crypton clone root dir, clear the test db:
make reset
(At time of writing, this doesn't clear the redis db, but that's not necessary. At time of writing, use of the redis is half-implemented, and it's intended just for the peer messaging feature. If it ever becomes useful/necessary, you can clear those keys using the redis-cli, like this: redis-cli keys "crypton.*" | xargs redis-cli del
.)