Light license-key server in 1 file
[!WARNING] Current major version is zero (
v0.x.x) to accommodate rapid development and fast iteration while getting early feedback from users. Please keep in mind that lime is still under active development and therefore full backward compatibility is not guaranteed before reaching v1.0.0.
Download the latest release for your platform from GitHub Releases:
# Linux
wget https://github.com/werbot/lime/releases/latest/download/lime-linux-amd64
chmod +x lime-linux-amd64
mv lime-linux-amd64 /usr/local/bin/lime
# macOS
wget https://github.com/werbot/lime/releases/latest/download/lime-darwin-amd64
chmod +x lime-darwin-amd64
mv lime-darwin-amd64 /usr/local/bin/lime
docker pull ghcr.io/werbot/lime:latest
# Run with Docker
docker run -d \
-p 8088:8088 \
-v $(pwd)/data:/data \
--name lime \
ghcr.io/werbot/lime:latest
# Clone the repository
git clone https://github.com/werbot/lime.git
cd lime
# Start with Docker Compose
docker compose -f docker/docker-compose.yaml up -d
# Clone the repository
git clone https://github.com/werbot/lime.git
cd lime
# Build frontend
yarn --cwd ./web run build
# Build and run
cd ./cmd
go build -o lime main.go
./lime serve
# Backup your data
cp -r ./lime_base ./lime_base.backup
cp -r ./lime_keys ./lime_keys.backup
# Download and replace binary
wget https://github.com/werbot/lime/releases/latest/download/lime-linux-amd64
chmod +x lime-linux-amd64
mv lime-linux-amd64 /usr/local/bin/lime
# Restart service
systemctl restart lime
# Pull the latest image
docker pull ghcr.io/werbot/lime:latest
# Stop and remove old container
docker stop lime
docker rm lime
# Start with new image
docker run -d \
-p 8088:8088 \
-v $(pwd)/data:/data \
--name lime \
ghcr.io/werbot/lime:latest
lime gen --config
This creates lime.toml with default settings. Edit the file to configure:
0.0.0.0:8088)admin@mail.com / Pass123)Keys are generated automatically on first run, or manually:
# Generate JWT keys
lime gen --jwt
# Generate license master keys
lime gen --license
lime serve
The server will start on http://0.0.0.0:8088
Navigate to http://localhost:8088/_/ and login with:
[!IMPORTANT] Change the default admin credentials immediately after first login!
lime serveStart the license server.
lime serve
Server will start on the address defined in lime.toml (default: 0.0.0.0:8088)
lime genGenerate configuration files and cryptographic keys.
# Generate configuration file
lime gen --config
# Generate JWT key pair
lime gen --jwt
# Generate license master key pair
lime gen --license
Development helper scripts are available in the ./scripts folder:
# Install or update Go version
./scripts/golang
# Database migrations
./scripts/migrate dev up # Apply migrations with fixtures
./scripts/migrate dev down # Rollback migrations
./scripts/migrate up # Apply migrations only
./scripts/migrate down # Rollback migrations
# Optimize SQLite database
./scripts/sqlite
# Generate keys (alternative to 'lime gen')
./scripts/gen
# Clean up hung processes
./scripts/clear
Currently, Lime supports Stripe for payment processing. Additional payment providers can be added by extending the payment handler.
Get your Stripe API keys from Stripe Dashboard
https://yourdomain.com/_/api/webhook/stripeTo add support for additional payment providers:
internal/models/payments.go:
const (
_ PaymentProvider = iota
NONE
STRIPE
YOUR_PROVIDER // Add your provider
)
Implement payment webhook handler in internal/handlers/admin/payment.go
web/src/utils/index.ts:
export const paymentProvidersObj = [
{ name: "None", color: "gray" },
{ name: "Stripe", color: "purple" },
{ name: "YourProvider", color: "blue" }, // Add your provider
];
The backend is developed in Go language. The frontend (admin site and base site) operates on the Vue3 and TailwindCSS.
There are a number of scripts (in the ./scripts folder) that simplify development:
./scripts/golang - Installs or updates a previously installed version of go (if needed).
./scripts/migration - Helps to work with migrations. For instance, the ./scripts/migration dev up command will apply new migrations from folder ./migrations, then implement the migrations from folder ./fixtures.
./scripts/sqlite - Optimizes the existing database.
./scripts/gen - Generate JWT or master-License keys.
./scripts/clear - Removing hung golang or vite processes.
First run:
yarn --cwd ./web run build - This is necessary in order to be able to compile and run a go app.cd ./cmd/ && go run main.go gen --config - (if need) To save the configuration file with default parameters for further modificationcd ./cmd/ && go run main.go serve - Launch the license serveryarn --cwd ./web run dev - (if need) If you need to change the server for if you’re going to modify the UI admin or manager panel, it will launch a dev environment with Vite.[!NOTE] I recommend running the
./scripts/migration dev upcommand. It will add test data to the database, which makes it easier to work with. For example, it will create products, transfer test images and create a test user for access to the admin panel on address http://0.0.0.0:8088/_/:
login - admin@mail.com
password - Pass123
If you want to say thank you and/or support the active development of lime:
Tweet about the project on your Twitter
You can learn more about how you can contribute to this project in the contribution guide.