Skip to Content
🚀 Getting StartedSetup With Docker

Last Updated: 3/13/2026


Setup with Docker

Docker is the recommended way to install and run LinkAce. This guide will walk you through setting up LinkAce using Docker Compose.

Prerequisites

Before you begin, ensure you have:

  • Docker installed (version 20.10 or higher)
  • Docker Compose installed (version 2.0 or higher)
  • At least 512 MB RAM available
  • A domain name (optional, but recommended for production)

Quick Start

  1. Download the Docker Compose file
wget https://raw.githubusercontent.com/Kovah/LinkAce/2.x/docker-compose.production.yml mv docker-compose.production.yml docker-compose.yml
  1. Configure environment variables

Create a .env file in the same directory:

# Application APP_NAME=LinkAce APP_ENV=production APP_KEY= APP_DEBUG=false APP_URL=http://localhost # Database DB_CONNECTION=mysql DB_HOST=db DB_PORT=3306 DB_DATABASE=linkace DB_USERNAME=linkace DB_PASSWORD=ChangeThisToASecurePassword # Redis REDIS_HOST=redis REDIS_PASSWORD=null REDIS_PORT=6379
  1. Generate an application key
docker-compose run --rm linkace php artisan key:generate
  1. Start the containers
docker-compose up -d
  1. Run database migrations
docker-compose exec linkace php artisan migrate --force
  1. Access LinkAce

Open your browser and navigate to http://localhost. You should see the LinkAce setup wizard.

Configuration Options

Using PostgreSQL

To use PostgreSQL instead of MySQL, update your .env file:

DB_CONNECTION=pgsql DB_HOST=db DB_PORT=5432

And modify the docker-compose.yml to use a PostgreSQL image instead of MySQL.

Using a Reverse Proxy

If you’re using a reverse proxy like Nginx or Traefik, you’ll need to:

  1. Remove the port mapping from the LinkAce service
  2. Add appropriate labels for your reverse proxy
  3. Update APP_URL to match your domain

Example for Traefik:

services: linkace: labels: - "traefik.enable=true" - "traefik.http.routers.linkace.rule=Host(`linkace.example.com`)" - "traefik.http.services.linkace.loadbalancer.server.port=80"

Environment Variables

Key environment variables you should configure:

  • APP_URL: Your LinkAce URL (important for proper link generation)
  • DB_PASSWORD: A strong database password
  • MAIL_*: Email configuration for notifications
  • BACKUP_*: Backup configuration for automated backups

Updating LinkAce

To update LinkAce to the latest version:

docker-compose pull docker-compose up -d docker-compose exec linkace php artisan migrate --force docker-compose exec linkace php artisan cache:clear

Troubleshooting

Permission Issues

If you encounter permission issues:

docker-compose exec linkace chown -R www-data:www-data /app/storage

Database Connection Errors

Ensure the database container is fully started before running migrations:

docker-compose logs db

Application Key Missing

If you see an “application key not set” error:

docker-compose run --rm linkace php artisan key:generate

Next Steps