From 051618995daa14e73963d60e6ebe801782d220a1 Mon Sep 17 00:00:00 2001 From: Abd Ur Rehman Date: Sun, 12 Apr 2026 18:48:20 +0100 Subject: [PATCH] Add PeakURL docs --- peakurl/README-short.txt | 1 + peakurl/compose.yaml | 46 +++++++++++++++ peakurl/content.md | 121 +++++++++++++++++++++++++++++++++++++++ peakurl/github-repo | 1 + peakurl/license.md | 1 + peakurl/logo.svg | 10 ++++ peakurl/maintainer.md | 1 + peakurl/metadata.json | 8 +++ 8 files changed, 189 insertions(+) create mode 100644 peakurl/README-short.txt create mode 100644 peakurl/compose.yaml create mode 100644 peakurl/content.md create mode 100644 peakurl/github-repo create mode 100644 peakurl/license.md create mode 100644 peakurl/logo.svg create mode 100644 peakurl/maintainer.md create mode 100644 peakurl/metadata.json diff --git a/peakurl/README-short.txt b/peakurl/README-short.txt new file mode 100644 index 000000000000..f8346e7c54d3 --- /dev/null +++ b/peakurl/README-short.txt @@ -0,0 +1 @@ +PeakURL is a self-hosted URL shortener and branded links platform. diff --git a/peakurl/compose.yaml b/peakurl/compose.yaml new file mode 100644 index 000000000000..11138bb2350b --- /dev/null +++ b/peakurl/compose.yaml @@ -0,0 +1,46 @@ +name: peakurl +services: + peakurl: + image: peakurl + restart: unless-stopped + depends_on: + db: + condition: service_healthy + ports: + - 8080:80 + environment: + APACHE_SERVER_NAME: example.com + PEAKURL_INSTALL_DB_HOST_DEFAULT: db + PEAKURL_INSTALL_DB_PORT_DEFAULT: '3306' + PEAKURL_INSTALL_DB_NAME_DEFAULT: peakurl + PEAKURL_INSTALL_DB_USER_DEFAULT: peakurl + PEAKURL_INSTALL_DB_PASSWORD_DEFAULT: change-this-password + volumes: + - peakurl:/var/www/html + + db: + image: mysql:8.4 + restart: unless-stopped + environment: + MYSQL_DATABASE: peakurl + MYSQL_USER: peakurl + MYSQL_PASSWORD: change-this-password + MYSQL_ROOT_PASSWORD: change-this-root-password + command: + - --character-set-server=utf8mb4 + - --collation-server=utf8mb4_unicode_ci + - --skip-name-resolve + volumes: + - mysql:/var/lib/mysql + healthcheck: + test: + - CMD-SHELL + - mysqladmin ping -h 127.0.0.1 -p$$MYSQL_ROOT_PASSWORD --silent + interval: 10s + timeout: 5s + retries: 12 + start_period: 30s + +volumes: + peakurl: + mysql: diff --git a/peakurl/content.md b/peakurl/content.md new file mode 100644 index 000000000000..7da6ac21add9 --- /dev/null +++ b/peakurl/content.md @@ -0,0 +1,121 @@ +# What is PeakURL? + +PeakURL is a self-hosted URL shortener and branded links platform. It lets you create short links on your own domain, manage them from a web dashboard, and keep your link data under your own control. + +> [PeakURL/PeakURL](https://github.com/PeakURL/PeakURL) + +%%LOGO%% + +Use an exact version tag when you want a repeatable deployment. + +# How to use this image + +## Start a `%%IMAGE%%` server instance + +PeakURL needs a MySQL-compatible database. The examples below use `mysql:8.4`. + +Create a network: + +```bash +docker network create peakurl +``` + +Start MySQL: + +```bash +docker run -d \ + --name peakurl-db \ + --network peakurl \ + --env MYSQL_DATABASE=peakurl \ + --env MYSQL_USER=peakurl \ + --env MYSQL_PASSWORD=change-this-password \ + --env MYSQL_ROOT_PASSWORD=change-this-root-password \ + --volume peakurl-db:/var/lib/mysql \ + mysql:8.4 \ + --character-set-server=utf8mb4 \ + --collation-server=utf8mb4_unicode_ci \ + --skip-name-resolve +``` + +Then start PeakURL: + +```bash +docker run -d \ + --name some-%%REPO%% \ + --network peakurl \ + --publish 8080:80 \ + --env APACHE_SERVER_NAME=example.com \ + --env PEAKURL_INSTALL_DB_HOST_DEFAULT=peakurl-db \ + --env PEAKURL_INSTALL_DB_PORT_DEFAULT=3306 \ + --env PEAKURL_INSTALL_DB_NAME_DEFAULT=peakurl \ + --env PEAKURL_INSTALL_DB_USER_DEFAULT=peakurl \ + --env PEAKURL_INSTALL_DB_PASSWORD_DEFAULT=change-this-password \ + --volume peakurl-data:/var/www/html \ + %%IMAGE%% +``` + +Then open `http://localhost:8080/setup-config.php` and finish the installer. + +## Environment variables + +The image keeps configuration intentionally small. Most application setup is completed through the PeakURL web installer. + +The main environment variables exposed by this image are: + +### `APACHE_SERVER_NAME` + +Optional Apache `ServerName` value, usually set to your public domain. + +Example: + +```bash +--env APACHE_SERVER_NAME=example.com +``` + +### `PEAKURL_INSTALL_DB_HOST_DEFAULT` + +Default database host shown in the installer. Usually the database container name on the Docker network. + +### `PEAKURL_INSTALL_DB_PORT_DEFAULT` + +Default database port shown in the installer. + +### `PEAKURL_INSTALL_DB_NAME_DEFAULT` + +Default database name shown in the installer. + +### `PEAKURL_INSTALL_DB_USER_DEFAULT` + +Default database username shown in the installer. + +### `PEAKURL_INSTALL_DB_PASSWORD_DEFAULT` + +Default database password shown in the installer. + +## %%COMPOSE%% + +Run `docker compose up -d`, wait for the services to become ready, and then open `http://localhost:8080/setup-config.php`. + +If you already run Nginx, Apache, Traefik, or another reverse proxy on the host, publish the container on a localhost-only port instead and proxy your public domain to that port. + +## Persistent data + +Mount `/var/www/html` if you want PeakURL files to persist outside the container. + +On first startup, this image copies the bundled PeakURL release package into `/var/www/html` and then runs directly from that path. This keeps the folder layout the same as the upstream release ZIP. + +Mount `/var/lib/mysql` on the database container as well if you want database data to persist. + +## Reverse proxy and TLS + +PeakURL serves plain HTTP inside the container. TLS should be terminated by your reverse proxy or load balancer. + +Typical setups place the container behind Nginx, Apache, Traefik, or another proxy that forwards requests to the published container port. + +## Updating + +To update the container runtime itself, pull the newer image tag and recreate the container. + +PeakURL can also update its own application files from the dashboard. If `/var/www/html` is mounted, those dashboard updates persist across container restarts because the full app tree lives in the mounted volume. + +Pulling a newer image updates the PHP/Apache runtime and container packaging, but it does not overwrite application files already present in a persisted `/var/www/html` volume. diff --git a/peakurl/github-repo b/peakurl/github-repo new file mode 100644 index 000000000000..32179172efc1 --- /dev/null +++ b/peakurl/github-repo @@ -0,0 +1 @@ +https://github.com/PeakURL/containers diff --git a/peakurl/license.md b/peakurl/license.md new file mode 100644 index 000000000000..48742027639a --- /dev/null +++ b/peakurl/license.md @@ -0,0 +1 @@ +PeakURL is distributed under the [MIT License](https://github.com/PeakURL/PeakURL/blob/main/LICENSE). diff --git a/peakurl/logo.svg b/peakurl/logo.svg new file mode 100644 index 000000000000..47438a2eace0 --- /dev/null +++ b/peakurl/logo.svg @@ -0,0 +1,10 @@ + + PeakURL + PeakURL wordmark with link icon + + + + + + PeakURL + diff --git a/peakurl/maintainer.md b/peakurl/maintainer.md new file mode 100644 index 000000000000..fcdf67bc4378 --- /dev/null +++ b/peakurl/maintainer.md @@ -0,0 +1 @@ +[PeakURL](%%GITHUB-REPO%%) diff --git a/peakurl/metadata.json b/peakurl/metadata.json new file mode 100644 index 000000000000..423347af4f0b --- /dev/null +++ b/peakurl/metadata.json @@ -0,0 +1,8 @@ +{ + "hub": { + "categories": [ + "content-management-system", + "web-analytics" + ] + } +}