Install AutoFAS.
Vehicles, drivers, fuel, maintenance, documents, costs, GPS tracking and alerts for one company, on your own server.
- Time
- About 15 minutes, most of it waiting for the first build.
- Server
- Linux, Docker 24+, 2 GB RAM, 10 GB disk
- Release file
autofas-selfhosted-<version>.tar.gz- Install folder
/opt/autofas
What you need.
- A Linux server (a VPS is fine) with at least 2 GB of RAM, 1 vCPU and 10 GB of free disk to start with, plus room for your files and backups. Debian and Ubuntu are the usual choice.
- Docker 24 or newer with the Compose plugin:
docker compose versionmust print a version. - A domain name whose DNS record already points at the server, for example
fleet.example.com. An IP address does not work: the licence is bound to the domain. - Ports 80 and 443 open to the internet and not used by another program. The install gets and renews its HTTPS certificate by itself (Let's Encrypt).
- Outbound HTTPS to
licence.sophario.com(activation, checks, updates), Docker's image registry and Let's Encrypt. - Your licence key (
SOPH-…) and the release archive, both on your buyer page. - An SMTP account for outgoing email. You can add it during setup or later.
- For SMS and WhatsApp alerts (optional): your own account on a gateway such as Zajelo.
Install.
As root, in a folder you keep for this install (the archive has no enclosing folder):
mkdir -p /opt/autofas
tar -xzf autofas-selfhosted-<version>.tar.gz -C /opt/autofas
cd /opt/autofas
./install.sh --domain fleet.example.com --email [email protected]The script asks you to confirm (--yes skips the question), writes .env, builds and starts the application, creates the database, runs the migrations and waits until it answers. This is what a real install printed:
$ ./install.sh --domain fleet.example.com --email [email protected] --yes
Starting AutoFAS ...
Image autofas:local Building
… image download and build steps (51 lines)
Image autofas:local Built
… 26 containers, volumes and networks created and started
Running database migrations ...
INFO Preparing database.
Creating migration table ...................................... 11.22ms DONE
INFO Running migrations.
0001_01_01_000000_create_users_table .......................... 12.86ms DONE
… 80 migrations, each DONE
Waiting for the app to answer (up to 120 seconds) ...
Waiting for the TLS certificate (up to 60 seconds) ...
AutoFAS is running.
Setup URL: https://fleet.example.com/setup
Setup token: 3f9c1e7a52b84d06a1c9e2f4b7d8a650
Open the setup URL and enter the token to finish. The token is also stored in .env
(SELFHOST_SETUP_TOKEN). Keep .env private: it holds your database password.Until setup is finished, https://fleet.example.com/ also leads to the wizard. Never delete .env: it holds your database password and the key that encrypts stored secrets.
The setup wizard.
The wizard runs once and shows seven steps along the top.
Token
Enter the setup token the install script printed.

Requirements
PHP version and extensions, writable storage, database, licence verification key: each must read OK. After a fix, use Check again.

Licence
Enter your key on the public domain name. If the page warns that
APP_URLdoes not match, correct it in.envas it says and open the wizard again.
Company
Name, country profile (International first and preselected), currency, country, starting language (English, Français or العربية) and time zone (Europe/London preselected).

Administrator
Name, email and a password of at least 12 characters, typed twice. Created only when you finish.

Email
SMTP host, port, encryption, user, password, From address and name. Send test email and continue, or Skip for now: until mail works, password links and invitations cannot be sent.

Finish
A summary, then Finish setup. The wizard closes for good and
https://fleet.example.com/opens the application.

After setup.
- Users. Administration, "Users" invites managers and drivers by email.
- Company country. Administration, "Settings": an International company can change country, currency (only while no amount is recorded) and time zone.
- Outgoing e-mail and SMS and WhatsApp gateway are under Administration. Connect your own gateway: its
https://address and an API key allowed to send, then switch each channel to "Send through the gateway" and use Check the connection. - GPS trackers. Administration, "Settings", "Vehicle tracking": confirm drivers have been informed and switch tracking on. On a vehicle, attach a tracker by its identifier and copy the server address it shows (
https://fleet.example.com/api/telematics/osmand/<key>) into the tracker or the Traccar Client app, about every 30 seconds. Positions keep arriving while the install is locked. - Licence. Administration, "Licence" opens the licence screen in a new tab: state, activation, Check licence now, the buyer page and Download data export.

Licence and locking.
A network failure, a timeout or an error from the licence server never locks the install: it confirms its licence at least every 7 days, and each success keeps it unlocked for 30 days. Only a clear refusal (revoked, not recognised, wrong domain) locks it at once. When locked, every screen shows "This workspace is paused"; sign-in, the licence screen, the data export, GPS positions, scheduled alerts and backups keep working, and drivers' entries wait on their phones.
| Message on the licence screen | What to do |
|---|---|
| No licence has been activated on this install | Paste your key on the licence screen and choose Activate. |
| This licence key is not recognised | Copy the key again from your purchase email or your buyer page. |
| This licence key is for a different product | Use the key you received for AutoFAS. |
| This licence is activated for a different domain | Open the install on its licensed domain, or move the licence to the new domain on your buyer page. |
| This install is no longer activated on the licence server | It was freed on the buyer page: activate it again with your key. |
| The licence file on this server was issued to a different install | The licence files were copied from another server: activate this install with your key. |
| This version was released after your update period ended | Renew on your buyer page, then update; or reinstall the last release your licence covers. |
| This install has not been able to confirm its licence for 30 days | Check the server's internet access, DNS and clock, then choose Check licence now. |
| This install cannot read its licence files | Run the scripts as root and do not start containers as another user (see Troubleshooting). |
| All installs on this licence are in use (when activating) | Free an install you no longer use on your buyer page, then activate again. |
| The licence server could not use this request (when activating) | Open the page on your domain name, not the server's IP address, and activate again. |
Updates.
cd /opt/autofas
./update.shAsks the licence server for the newest release you are entitled to, downloads and checks it, makes a backup, replaces the code, rebuilds, migrates and checks the licence. If anything fails, or the script is interrupted, the previous version is put back. Keep your own changes in compose.override.yml and product.env.local.
Backups and moving.
./backup.sh
./restore.sh backups/<UTC date and time>A backup holds the database dump, storage/ (uploads, logo, licence files) and a copy of .env; the newest 14 are kept. Treat backups/ as secret and copy it to another place regularly. Nightly at 03:00:
0 3 * * * cd /opt/autofas && ./backup.shNew server: point the domain at it, install the same release without running the wizard, copy the backup over, ./restore.sh it, then activate your key on the licence screen. Never run docker compose down -v: it deletes the database volume.
Troubleshooting.
- What is running:
docker compose ps(caddy,app,scheduler,postgres). - Errors:
docker compose logs --tail 200 app; licence checks and jobs:… scheduler; certificates:… caddy. - The token is refused.
grep SELFHOST_SETUP_TOKEN .env. Once the wizard is finished its address no longer exists. - Locked, reason
unreadable.chown -R -h 33:33 storage, thendocker compose exec -u 33:33 app php artisan selfhost:licence-check --force. - Disk full.
docker image prune -fanddocker builder prune -f; move old backups off the server.
Support.
Your buyer page holds your key, your activations, your downloads and the way to reach Sophario Ltd. Send a short description of the problem and the output of docker compose logs --tail 200 app (remove anything private first).
You can also write to [email protected] or call +44 7537 131614.