Turtl Server: an Evernote alternative

I stubled upon this project and it looks so nice! If you ever used Evernote, this is as close as you can get to that closed piece of software.
By having a private cloud for all your notes, links, passwords etc, you have all your info available at all times.

It would be great if Turtl could get a spot as a NethServer module.
More info: https://turtlapp.com/

1 Like

For sure @Fred will second your proposal :wink:

If you are looking for projects to move away the gafam, then take a look to https://degooglisons-internet.org/

It is a french project with a lot of free services, but the goal is not that you use their services because it will be the same than with google…they want that you install these services on your server and they offer the howto to do it. For example they provide a howto for turtl

I dont know if the presentation can be read in english…i’m not at home :slight_smile:

Sorry french inside

1 Like

Oh, I love turtl!!! I have hosted on another server and it’s been up for a few months without any issue.

The installation is not straightforward at all (I’ve written a short tutorial to install the server on Debian on their google groups) and the project is still in early development, missing some important features (most notably the ability to export/import notes to migrate servers) but It does a great job at keeping my important notes or reminders private.

I think the project needs to mature to be incorporated in NS at this time but let me know if I can be of help installing the server - I have the process well documented with https proxy and auto-restart script (server has a tendency to shut down frequently).

1 Like

Please do share your notes so we can create a howto here. If it is a workable option we can move the howto to the wiki. Then if someone can put some weight on it, it can grow towards a community module.!

Ok, this is an evolution of the tutorial I posted on turtl google groups, with a step-by-step approach and some things corrected (I couldn’t be bothered to revisit the goggle groups post as you can’t edit it); The steps bellow are for installation of the turtl server on a debian minimal install with Apache:

			===== Install Turtl in Debian 8 =====

# In Debian 8 i386 with Lamp:

# Start by installing required packages:

apt-get install git wget curl libtool subversion gcc make automake

# 1. Install libuv:

cd /usr/local/src
wget http://dist.libuv.org/dist/v1.9.1/libuv-v1.9.1.tar.gz
tar -xf libuv-v1.9.1.tar.gz
rm libuv-v1.9.1.tar.gz
cd libuv-v1.9.1
sh autogen.sh
make install

# 2. Install RethinkDB

# Add the repo to your list and install via apt-get:

cd ~
echo “deb http://download.rethinkdb.com/apt lsb_release -cs main” | sudo tee /etc/apt/sources.list.d/rethinkdb.list
wget -qO- https://download.rethinkdb.com/apt/pubkey.gpg | sudo apt-key add -
apt-get update
apt-get install rethinkdb

# Now configure the default instance:

cp /etc/rethinkdb/default.conf.sample /etc/rethinkdb/instances.d/default.conf

# Restart rethinkdb:

systemctl restart rethinkdb

# 3. Install Common Lisp (ccl or sbcl)

# Move into the directory to host lisp:

cd /usr/local/src

# and download the package (http://ccl.clozure.com/download.html):

svn co http://svn.clozure.com/publicsvn/openmcl/release/1.11/linuxx86/ccl

# Copy the files to the system folder:

cp /usr/local/src/ccl/scripts/ccl /usr/local/bin


cp /usr/local/src/ccl/scripts/ccl64 /usr/local/bin

# Can test by starting lisp with the command:





cd ~

# 4. Install quickLisp

# Create new unpriviledged user for Turtl:

adduser turtl

Create a Data directory to store files:

mkdir -p /var/turtl/data
chown turtl:turtl /var/turtl/data
chmod 0755 /var/turtl/data

# Log in as turtl user:

su turtl
cd ~

# Download and install Quicklisp

wget https://common-lisp.net/project/asdf/asdf.lisp
curl -O https://beta.quicklisp.org/quicklisp.lisp

ccl --load quicklisp.lisp


ccl64 --load quicklisp.lisp

# Within the Lisp sheel install quicklisp:


(load (compile-file “asdf.lisp”))


# Cleanup:

rm asdf.lisp quicklisp.lisp

# 5. Download and Install Turtl

git clone https://github.com/turtl/api.git
cd /home/turtl/api

# Create a file to host lisp commands:

vi launch.lisp

# and copy the bellow:

(pushnew “./” asdf:central-registry :test #'equal)
(load “start”)

# Install a few missing dependencies in quicklisp:

cd /home/turtl/quicklisp/local-projects

git clone git://github.com/orthecreedence/cl-hash-util
git clone git://github.com/orthecreedence/vom
git clone git://github.com/orthecreedence/cl-async
git clone git://github.com/orthecreedence/cffi
git clone git://github.com/orthecreedence/wookie
git clone git://github.com/orthecreedence/cl-rethinkdb
git clone git://github.com/orthecreedence/cl-libuv
git clone git://github.com/orthecreedence/drakma-async
git clone https://github.com/Inaimathi/cl-cwd.git

# edit the ccl init conf file:

vi /home/turtl/.ccl-init.lisp

# and add the bellow at the end:

(cwd “/home/turtl/api”)
(load “/home/turtl/api/launch”)

# create the default turtl config file:

cp /home/turtl/api/config/config.default.lisp /home/turtl/api/config/config.lisp

# edit as needed:

vi /home/turtl/api/config/config.lisp

# Configure to bind to local host:

(defvar *server-bind* ""
  "The address to bind Turtl to (nil is the same as")

# Also change the *site-url*, *admin-email*, and others - PLACE EVERYTHING BETWEEN " " )

# Change the Storage place to local

(defvar local-upload “/var/turtl/data”

# Start Lisp which should load turtl automatically:




# turtl will build and creat db schema and launch - you should be able to access the server through a client by pointing it to http://turtl.yourdomain.com:8181

# ctrl + C to leave and (quit) to end lisp; 

# Go back to root/sudo user by exiting turtl


# 6. Start Turtl at boot:

# Create an systemd service:

vi /lib/systemd/system/turtl.service

# Copy/Paste the bellow:

After=network.target mysql.service postgresql.service



# Save and Close; 

# Give correct permissions:

chmod 0644 /lib/systemd/system/turtl.service

# Enable the service on boot:

systemctl enable turtl

# reboot

# 7. Configure Apache as reverse proxy serving https:

# Start by installing the required mods for apache:

apt-get install -y libapache2-mod-proxy-html libxml2-dev

# Enable with:


# Once you are prompted with the choice of modules, pass the below line listing the module names:

proxy proxy_ajp proxy_http rewrite deflate headers proxy_balancer proxy_connect proxy_html

# Configure the Virtual Host in Apache:

vi /etc/apache2/sites-available/turtl.conf

# Paste the bellow:

<VirtualHost *:80>

ServerName turtl.yourdomain.com
Redirect / https://turtl.yourdomain.com/
ServerAdmin webmaster@yourdomain.com

CustomLog ${APACHE_LOG_DIR}/turtl.log combined

<VirtualHost *:443>

ServerName turtl.yourdomain.com
ServerAdmin webmaster@yourdomain.com

SSLEngine on
SSLProtocol all -SSLv2 -SSLv3
SSLHonorCipherOrder     on
SSLCompression          off
SSLOptions +StrictRequire

If you’re using let’s encrypt

SSLCertificateFile /etc/letsencrypt/live/turtl.yourdomain.com/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/turtl.yourdomain.com/privkey.pem
SSLCertificateChainFile /etc/letsencrypt/live/turtl.yourdomain.com/fullchain.pem

ProxyPreserveHost On
ProxyRequests off
ProxyPass / Keepalive=On timeout=1600
ProxyPassReverse /

LogLevel info

CustomLog ${APACHE_LOG_DIR}/turtl.log combined
# Save and enable the site:

a2ensite turtl

# Restart apache

systemctl restart apache2

# Reboot and check that you can connect to turtl through any client (there is no webgui at this point) on your server's address:



You’re right looks very interesting but a bit tricky :frowning: does anyone make an rpm for that yet?

1 Like

Hey Fred it’s me again, I just ran across this in my email and I look forward to trying this on my Ubuntu 16.04 server. I will hit you back and let you know how it work. Like you I thinks Turtl is assume program, and for some strong reason I just want to make it work. What I am hoping that the maker of the project can see the big picture with turtl. I hope he can see it as bring something that could compete with ever-note. I see this as a big project that can work, It’s open sources , and it work with Linux. This is one of the reason I left Evernote. They don’t see want to incorporate this with Linux, and if they do anytime soon it because of a project like this one.

1 Like

Ehi Earnest, welcome here! Did you see this app for NextCloud

/cc @Fred @robb @dnutan

Hi I followed the instructions laid out by Fred, which by the way were really simple and helpfull, but when I tried to run the turtl server using ccl I got the following error on my terminal:

Error: Reader error: No external symbol named "CENTRAL-REGISTRY" in package #<Package "ASDF/INTERFACE"> .

While executing: CCL::%PARSE-TOKEN, in process listener(1).
Type :GO to continue, :POP to abort, :R for a list of available restarts.
If continued: Create and use the internal symbol ASDF/INTERFACE::CENTRAL-REGISTRY

The problem is probably related to the config.lisp file. Any help to solve the error is welcomed. Thanks in advance

1 Like

I managed to solve the problem, there were asterisks missing in the launch.lisp files.
So instead of:

(pushnew "./" asdf:central-registry :test #'equal)
(load "start")

Paste the following in the launch.lisp file:

(pushnew "./" asdf:*central-registry* :test #'equal)
(load "start")
1 Like

Thanks for the heads-up on this one, @Fred can you update your guide thanks to @Guyi_Li suggestions?

Thanks for noting that error, I missed it when I went over it. I notice that the text is in italic so it may have interpreted the asterisks that way?

@alefattorini How do I edit a post?

p.s. I can edit this post but I can’t edit the guide - unable to edit old posts?

p.s.2 double asterisk does indeed convert to italic…

I missed this request sorry, you can now edit it.

I following the procedure several time but it doesn’t work. I have these errors:

turtl@mx:~$ ccl64
To load "turtl":
  Load 1 ASDF system:
; Loading "turtl"
  <INFO> [1505127532] turtl - Applying DB schema...
 <ERROR> [1505127532] turtl - wrapping (CREATE-TURTL-DB): #<SOCKET-REFUSED #<TCP-SOCKET #x302002CC2C4D>: -111: connection refused #x302002CFD75D>
 <ERROR> [1505127532] turtl - server caught error: (defafun: CREATE-TURTL-DB): #<SOCKET-REFUSED #<TCP-SOCKET #x302002CC2C4D>: -111: connection refused #x302002CFD75D>
<NOTICE> [1505127532] turtl - *a :: {"event":"log","data":{"data":{"line":"0","url":"defafun: CREATE-TURTL-DB","msg":"#<SOCKET-REFUSED #<TCP-SOCKET #x302002CC2C4D>: -111: connection refused #x302002CFD75D>","version":"api"},"hash":"c26d5f4513946305b66c36fbeaf6fac5"}}
 <ERROR> [1505127532] turtl - wrapping (APPLY-DB-SCHEMA): Turtl wrapped error: CREATE-TURTL-DB: #<SOCKET-REFUSED #<TCP-SOCKET #x302002CC2C4D>: -111: connection refused #x302002CFD75D>
 <ERROR> [1505127532] turtl - server caught error: (defafun: APPLY-DB-SCHEMA): Turtl wrapped error: CREATE-TURTL-DB: #<SOCKET-REFUSED #<TCP-SOCKET #x302002CC2C4D>: -111: connection refused #x302002CFD75D>
<NOTICE> [1505127532] turtl - *a :: {"event":"log","data":{"data":{"line":"0","url":"defafun: APPLY-DB-SCHEMA","msg":"Turtl wrapped error: CREATE-TURTL-DB: #<SOCKET-REFUSED #<TCP-SOCKET #x302002CC2C4D>: -111: connection refused #x302002CFD75D>","version":"api"},"hash":"5e73738c1b1ad1dc2fd42976852e2039"}}
 <ERROR> [1505127532] turtl - Error initializing: Turtl wrapped error: APPLY-DB-SCHEMA: Turtl wrapped error: CREATE-TURTL-DB: #<SOCKET-REFUSED #<TCP-SOCKET #x302002CC2C4D>: -111: connection refused #x302002CFD75D>
Welcome to Clozure Common Lisp Version 1.11-r16635  (LinuxX8664)!

Can you help me please ?

@fred can you help Damien?

Sorry I found the solution. I have a Zimbra instance on my own server and port 8181 are used by him.
So I resolved my problem wimply in change port used by rethinkdb with another.


1 Like