Installation
Get the code
Pull the code from the official GitHub repository:
This is made to work with docker and docker-compose, so they both need to be installed. If docker is not installed on your ubuntu machine, you can use the ./install_docker_ubuntu.sh
script to install it for you.
Configure your installation
/Apfell/apfell-docker/app/__init__.py
contains all of the pieces for you to configure:
A few important notes here. server_ip
is used to tell your browser where to send RESTful requests to and where to connect for websockets. listen_port
and listen_ip
are what will actually be used on the server where you're running Apfell. The whitelisted_ip_blocks
allow you to restrict access to the login
and register
pages of Apfell.
Once you’re ready to finally install, simply run the setup script sudo ./setup_apfell.sh
and you should be good to go! Apfell will use the information you provided to set up the postgresql instance, create and start all of the necessary docker containers. and start the web server.
The setup script will also create a default user
apfell_admin
with a default passwordapfell_password
that can be used. It’s recommended to change this user’s password after installing though.
Start Apfell
If you came here right from the previous section, your Apfell instance should already be up and running. Check out the next section to confirm that's the case. If at any time you wish to stop Apfell, simply run sudo ./stop_apfell.sh
and if you want to start it again run sudo ./start_apfell.sh
. If Apfell is currently running and you need to make a change, you can run sudo ./start_apfell.sh
again without any issue, that script will automatically stop things and then restart them.
Troubleshooting installation and connection
If something seems off, here's a few places to check:
Run
sudo ./status_check.sh
to give a status update on all of the docker containers. They should all be up and running. If one is exited or has only been up for less than 30 seconds, that container might be your issue.Your output will be similar to the following. Notice out the
apfell_apfell
docker container shows a status ofExited
? That looks like an issue
To check the logs of any container, run
sudo ./display_output.sh [container_name]
. For example, to see the output of our stopped container, runsudo ./display_output.sh apfell_apfell
. This will help track down if the last thing that happened was an error of some kind.If you don't supply any container names, the script will iterate through all of the containers and dump their output to a file called
display_output.txt
that you can then grep or browse through.
If all of that looks ok, but something still seems off, it's time to check the browser.
If you're seeing "Session Expired, Please Refresh", "Socked errored, please refresh", or "Socked closed, please refresh", then there's an issue with your websocket connections.
First open up the developer tools for your browser and see if there are any errors that might indicate what's wrong. If there's no error though, check the network tab to see if there are any 404 errors. The most likely cause is that there is an issue with the
listen_ip
in your configuration file such that your browser cannot reach it.If that's not the case, make sure you've selected a current operation (more on this in the Quick Usage section). Apfell uses websockets that pull information about your current operation to provide data. If you're not currently in an active operation (indicated at the top of your screen in big letters), then Apfell cannot provide you any data.
Last updated