Several scripts have been provided for podman use, both in a manual interaction capacity as well as an option for utilizing systemd user units, including
podman auto-update functionality, for a completely unprivileged user.
All of the remaining command blocks expect to be executed from the root of the project, as you would be in after executing the following:
git clone https://git.jharmison.com/jharmison/akaunting cd akaunting
Much like the docker-compose method, env files are used for the DB and application to reduce command line clutter. You should copy the env file examples and update them according to their comments.
cp env/db.env.example env/db.env vi env/db.env # and set things cp env/run.env.example env/run.env vi env/run.env # and set things
Other variables used in the scripts for managing the Akaunting containers are shown in
podman/common.sh. You can override the default behavior by exporting the appropriate variables. This might make sense if you want to host multiple instances or have some other conflict, for example with ports, on a given host. For example, to override the port published on the host for the web application, you could
export AKAUNTING_PORT=8081 before execution of any of the following.
Initial setup is required to populate the database and build the directory structure for the application out.
It will take around 5, but up to 30, seconds for the interface to be available. Visit the host over HTTP at port 8080 and finish configuring your Akaunting company through the interactive wizard. After setup is complete, bring the containers down.
There are two ways to run Akaunting from these images with podman. The first is simple and will run the containers, but not update the images automatically, and not start automatically on a reboot.
The second method will automatically update the containers, and restart them on boot. As a user who can sudo, you should run the following:
sudo loginctl enable-linger $user # Where $user here is replaced with the username you expect to be running Akaunting as.
The user you run Akaunting with, and therefore specify on the line above, doesn't need to be the same user executing that command, but they need to have read access to the env files and scripts. They don't need the privilege to
sudo at all. That command simply lets them have systemd user sessions at system boot time, rather than login time.
After that, you can safely run:
This will create the same pods as
start.sh, except it will also label them for automatic updating based on image tag updates, generate systemd units to start them (at boot if you enabled systemd linger), and enable the
podman-auto-update.timer that will check for image tag updates for appropriately labelled containers at midnight.
If you want to clean up a deployment, removing all containers, pods, volumes, and systemd units, also provided is clean.sh. It will completely remove any data saved in your existing Akaunting installations, so be sure that's what you want to do.