There are many ways to help you backup the tasks, using subversion control is one of those. I've used git for a while to keep track them, now I would like to show you how to keep track the tasks by the traditional way - Taskserver
brew install taskd
brew
is available on either macos or ubuntu. If you are using another OS, please refer to 1
-
Configuration
You might already see some of guidelines using
$TASKDDATA
to point to taskd data dir. In my case, I explicitly point to the default/var/taskd
, you can have another as you wishtaskd init --data /var/taskd
When you're done, you can see a file named
config
in that dir, now you need to update this file with another valueslog=/var/taskd/taskd.log pid.file=/var/taskd/taskd.pid client.cert=/var/taskd/api.cert.pem client.key=/var/taskd/api.key.pem server.cert=/var/taskd/server.cert.pem server.key=/var/taskd/server.key.pem server.crl=/var/taskd/server.crl.pem ca.cert=/var/taskd/ca.cert.pem
log
andpid.file
can be created bytouch
command. For the keys, somehow I could not see the dirpki
on local, so I used an alternative as below# Clone this repo git clone git@github.com:GothenburgBitFactory/taskserver.git cd taskserver/pki # Generate keys for you server ./generate # Then, copy the keys to `/var/taskd` dir
-
Start the taskserver
taskdctl start # Check the server status taskdctl status # For more info, you might refer to the log tail -f /var/taskd/taskd.log
-
Create user
taskd add org <org> taskd add user <org> <user> # cd the `pki` dir as above cd taskserver/pki # Generate cert / key for the beloved user ./generate.client <user>
fyi, Org / User is managed in the dir
/var/taskd/orgs
. Each user has an uuid, i.e:36102155-5be6-4da0-afca-6d1a7b86b696
The infomation that you need to provide to the user
- The taskserver address, i.e:
localhost:53589
- The generated certificate file with format
<user>.cert.pem
- The generated key file with format
<user>.key.pem
- User credential
<uuid
which can be found after user created, or in the dir<org>/<user>/<uuid>
- The taskserver address, i.e:
-
At the client side
Update your own
taskrc
with the provided info as abovetaskd.trust=allow all taskd.server=localhost:53589 taskd.certificate=~/.task/foo.cert.pem taskd.key=~/.task/foo.key.pem taskd.credentials=Public/foo/36102155-5be6-4da0-afca-6d1a7b86b696
Try to sync your tasks by
task sync init