Perma is a Python application built on the Django web framework.
Perma has a lot of moving pieces. We recommend using Docker for local development. If you are new to Docker, it may take some time before you are comfortable with its vocabulary and commands, but it allows you to jump right into coding instead of spending a lot of time getting all the services running on your machine.
If you prefer to install Perma locally, see our legacy installation instructions.
For advice about production deployments, send us a note!
Be sure to check out the developer documentation for a list of command commands and other tips and tricks for working with Perma.
Perma serves content at several hosts. To ensure that URLs resolve correctly, add the following domains to your computer's hosts file:
127.0.0.1 perma.test api.perma.test perma-archives.test
For additional information on modifying your hosts file, try this help doc.
Docker commands can be lengthy. To cut down on keystrokes, we recommend
adding the following to your .bash_profile
.
alias d="docker-compose exec web"
Then check out the code:
$ git clone https://github.com/harvard-lil/perma.git
$ cd perma
Start up the Docker containers in the background:
$ docker-compose up -d
The first time this runs, it will build the 1.4GB Docker image, which may take several minutes. (After the first time, it should only take 1-3 seconds.)
Finally, initialize the databases:
$ bash init_perma.sh
$ bash init_wr.sh
You should now have a working installation of Perma! See common commands to explore what you can do, like running the application and running the tests.
When you are finished, spin down Docker containers by running:
$ docker-compose down