Server Setup

The GoSync server is a standalone binary. You can run it on Linux, Mac, or Windows.

Installation

Download the latest release from our GitHub Releases page.

bash
# Linux / Mac
wget https://github.com/HarshalPatel1972/GoSync/releases/download/v0.1.0/gosync-server
chmod +x gosync-server
./gosync-server

Configuration

By default, the server runs on port 8080 and uses an embedded SQLite database (gosync.db). No setup required.

To customize it, set environment variables:

bash
export PORT=3000
export DB_TYPE=postgres
export DB_DSN="user=postgres password=secret dbname=mydb sslmode=disable"
./gosync-server

Environment Variables

VariableDefaultDescription
PORT8080Server port
DB_TYPEsqliteDatabase type (sqlite, postgres)
DB_DSNgosync.dbDatabase connection string
LOG_LEVELinfoLog verbosity (debug, info, warn, error)

Docker Deployment

For production, we recommend Docker.

yaml
version: '3'
services:
  gosync:
    image: harshalpatel1972/gosync:latest
    ports:
      - "8080:8080"
    volumes:
      - ./data:/app/data
    environment:
      - LOG_LEVEL=info

Run with:

bash
docker-compose up -d

Next: Understand conflict resolution →