Aleph requires a couple of services in order to operate. To make it easier for development and deployments it uses Docker containers. Below you will find the installation steps on how to install Aleph locally for development and production environment.
You will also need to edit a configuration file to provide some credentials for the external services. This includes the OAuth credentials to allow Google users to login to Aleph and an email server credentials. Email server support is optional for development purposes.
Inside the same repository you will find a file called
This is a template of the configuration file. Make a copy of this file named
aleph.env and follow the steps below to edit it.
Save the client ID and the client secret as
Finally you will need to provide a value for the
ALEPH_SECRET_KEY. A good
example of a value is the output of
openssl rand -hex 24.
Development installation steps¶
Insider the Aleph repository you will find a
Dockerfile and a
docker-compose.dev.yml files. These are used to build a container with the
application and start the relevant services.
To proceed run:
make buildto start the application and relevant services. You can leave this open to have access to the development logs.
make upgradeto run the latest database migrations and create/update any indexes.
make webto run the web-based API server.
http://localhost:5000/in your browser to visit the API server.
Your repository is mounted inside the docker container under the name
aleph_app. You can access these services anytime by running
Building from a clean state¶
You can also build the Aleph images locally. This could be useful while working on the Dockerfile changes and new dependency upgrades.
Aleph provides two commands to build the images. First one is
make base, this
will build the
alephdata/base image (this is an intermediary image with
system-level dependencies for Aleph). The second one is
make build, this will
alephdata/aleph image (this will generate a production ready image).