one-click-apps/public/v4/apps/kutt.yml

231 lines
10 KiB
YAML

captainVersion: 4
services:
$$cap_appname:
caproverExtra:
containerHttpPort: $$cap_KUTT_PORT
image: kutt/kutt:$$cap_KUTT_VERSION
environment:
PORT: $$cap_KUTT_PORT
SITE_NAME: $$cap_KUTT_SITE_NAME
DEFAULT_DOMAIN: $$cap_appname.$$cap_root_domain
LINK_LENGTH: $$cap_KUTT_LINK_LENGTH
DB_HOST: srv-captain--$$cap_appname-db
DB_NAME: $$cap_POSTGRES_DB
DB_USER: $$cap_POSTGRES_USER
DB_PASSWORD: $$cap_POSTGRES_PASSWORD
REDIS_HOST: srv-captain--$$cap_appname-cache
DISALLOW_REGISTRATION: $$cap_KUTT_DISALLOW_REGISTRATION
DISALLOW_ANONYMOUS_LINKS: $$cap_KUTT_DISALLOW_ANONYMOUS_LINKS
USER_LIMIT_PER_DAY: $$cap_KUTT_USER_LIMIT_PER_DAY
NON_USER_COOLDOWN: $$cap_KUTT_NON_USER_COOLDOWN
DEFAULT_MAX_STATS_PER_LINK: $$cap_KUTT_DEFAULT_MAX_STATS_PER_LINK
CUSTOM_DOMAIN_USE_HTTPS: $$cap_KUTT_CUSTOM_DOMAIN_USE_HTTPS
JWT_SECRET: $$cap_KUTT_JWT_SECRET
ADMIN_EMAILS: $$cap_KUTT_ADMIN_EMAILS
RECAPTCHA_SITE_KEY: $$cap_KUTT_RECAPTCHA_SITE_KEY
RECAPTCHA_SECRET_KEY: $$cap_KUTT_RECAPTCHA_SECRET_KEY
GOOGLE_SAFE_BROWSING_KEY: $$cap_KUTT_GOOGLE_SAFE_BROWSING_KEY
GOOGLE_ANALYTICS: $$cap_KUTT_GOOGLE_ANALYTICS_INDIVIDUAL
GOOGLE_ANALYTICS_UNIVERSAL: $$cap_KUTT_GOOGLE_ANALYTICS_UNIVERSAL
MAIL_HOST: $$cap_KUTT_MAIL_HOST
MAIL_PORT: $$cap_KUTT_MAIL_PORT
MAIL_SECURE: $$cap_KUTT_MAIL_SECURE
MAIL_USER: $$cap_KUTT_MAIL_USER
MAIL_FROM: $$cap_KUTT_MAIL_FROM
MAIL_PASSWORD: $$cap_KUTT_MAIL_PASSWORD
REPORT_EMAIL: $$cap_KUTT_REPORT_EMAIL
CONTACT_EMAIL: $$cap_KUTT_CONTACT_EMAIL
depends_on:
- $$cap_appname-db
- $$cap_appname-cache
$$cap_appname-db:
caproverExtra:
notExposeAsWebApp: 'true'
image: postgres:$$cap_POSTGRES_VERSION
environment:
POSTGRES_USER: $$cap_POSTGRES_USER
POSTGRES_PASSWORD: $$cap_POSTGRES_PASSWORD
POSTGRES_DB: $$cap_POSTGRES_DB
volumes:
- $$cap_appname-db:/var/lib/postgresql/data
$$cap_appname-cache:
caproverExtra:
notExposeAsWebApp: 'true'
image: redis:$$cap_REDIS_VERSION
volumes:
- $$cap_appname-cache:/data
caproverOneClickApp:
displayName: Kutt
description: Free Modern URL Shortener
isOfficial: true
documentation: https://github.com/thedevs-network/kutt
instructions:
start: |-
Kutt is a modern URL shortener with support for custom domains. Shorten URLs, manage your links and view the click rate statistics.
end: |-
Kutt has been successfully deployed! It might take few moments before it's fully started.
You can access it at `http://$$cap_appname.$$cap_root_domain`.
variables:
- id: $$cap_KUTT_VERSION
label: Version | Application
description: Kutt's version. Check out their valid tags at https://hub.docker.com/r/kutt/kutt/tags
defaultValue: v2.7.3
validRegex: /.{1,}/
- id: $$cap_POSTGRES_VERSION
label: Version | Database
description: PostgreSQL's version. Check out their valid tags at https://hub.docker.com/_/postgres/tags
defaultValue: '14.0-alpine'
validRegex: /.{1,}/
- id: $$cap_REDIS_VERSION
label: Version | Cache
description: Redis' version. Check out their valid tags at https://hub.docker.com/_/redis/tags
defaultValue: '6.2-alpine'
validRegex: /.{1,}/
- id: $$cap_KUTT_ADMIN_EMAILS
label: Administration | Admin Email Addresses
description: Comma separated email addresses of administrators so they can access admin actions on settings page.
- id: $$cap_KUTT_PORT
label: General | Port
description: Kutt's port. Should be left untouched.
defaultValue: 3000
validRegex: /.{1,}/
- id: $$cap_KUTT_SITE_NAME
label: General | Site Name
description: The name of the site (e.g. `My Link Shortener`).
defaultValue: Kutt
validRegex: /.{1,}/
- id: $$cap_KUTT_LINK_LENGTH
label: General | Link Length
description: Length of the generated links.
defaultValue: 6
validRegex: /.{1,}/
- id: $$cap_KUTT_DEFAULT_MAX_STATS_PER_LINK
label: Performance | Maximum Stats Per Link
description: Maximum number of visits for each link to have detailed statistics.
defaultValue: 5000
validRegex: /.{1,}/
- id: $$cap_KUTT_DISALLOW_REGISTRATION
label: Privacy | Disallow Registration
description: Whether to disable registration.
defaultValue: 'false'
validRegex: /^(true|false)$/
- id: $$cap_KUTT_DISALLOW_ANONYMOUS_LINKS
label: Privacy | Disallow Anonymous Links
description: Whether to disable creation of links anonymously.
defaultValue: 'false'
validRegex: /^(true|false)$/
- id: $$cap_KUTT_USER_LIMIT_PER_DAY
label: Anti-Abuse | Daily Limit
description: Daily link creation limit for each user.
defaultValue: 50
validRegex: /.{1,}/
- id: $$cap_KUTT_NON_USER_COOLDOWN
label: Anti-Abuse | Non-User Cool Down
description: Cool down for non-logged in users in minutes. Set to `0` to disable.
defaultValue: '0'
validRegex: /.{1,}/
- id: $$cap_KUTT_RECAPTCHA_SITE_KEY
label: Anti-Abuse | Recaptcha Site Key
description: >-
Site key for Recaptcha.
Leave blank if you do not want to use Recaptcha.
- id: $$cap_KUTT_RECAPTCHA_SECRET_KEY
label: Anti-Abuse | Recaptcha Secret Key
description: >-
Secret key for Recaptcha.
Leave blank if you do not want to use Recaptcha.
- id: $$cap_KUTT_GOOGLE_SAFE_BROWSING_KEY
label: Anti-Abuse | Google Safe Browsing Key
description: >-
Key for Google Cloud API to prevent from users from submitting malware URLs.
Leave blank if you do not want to use Google Safe Browsing.
- id: $$cap_KUTT_CUSTOM_DOMAIN_USE_HTTPS
label: Security | HTTPS For Custom Domains
description: Whether to use HTTPS for links with custom domain.
defaultValue: 'false'
validRegex: /^(true|false)$/
- id: $$cap_KUTT_JWT_SECRET
label: Security | JWT Secret
description: >-
Passphrase to encrypt JWT. Should be a long and secure key.
You can also generate one using command `openssl rand -hex 64`.
defaultValue: $$cap_gen_random_hex(64)
validRegex: /.{1,}/
- id: $$cap_POSTGRES_DB
label: Database | Name
description: Name of the database in PostgreSQL.
defaultValue: kutt
validRegex: /.{1,}/
- id: $$cap_POSTGRES_USER
label: Database | User
description: Name of the database user in PostgreSQL.
defaultValue: kutt
validRegex: /.{1,}/
- id: $$cap_POSTGRES_PASSWORD
label: Database | Password
description: Password of the database user in PostgreSQL.
defaultValue: $$cap_gen_random_hex(16)
validRegex: /.{1,}/
- id: $$cap_KUTT_GOOGLE_ANALYTICS_INDIVIDUAL
label: Tracking | Google Analytics Tracking ID
description: >-
Tracking ID for Google Analytics. Format is `UA-XXXX-XX`.
Leave blank if you do not want to use Google Analytics.
- id: $$cap_KUTT_GOOGLE_ANALYTICS_UNIVERSAL
label: Tracking | Google Analytics Universal Tracking ID
description: >-
Universal tracking ID for Google Analytics. Format is `UA-XXXX-XX`.
Leave blank if you do not want to use Google Analytics.
- id: $$cap_KUTT_MAIL_HOST
label: Mail | Host
description: >-
Mail host used to send verification mails.
Leave blank if you do not want to use email delivery.
If you would like to approve users manually you will have
to search for the verification token of the user
in the database (`SELECT verification_token FROM users WHERE email='myuser@mydomain'`)
and call `/verify/<verification_token>` to verify.
- id: $$cap_KUTT_MAIL_PORT
label: Mail | Port
description: >-
Port of mail host used to send verification mails.
Using port `465` is recommended.
Leave blank if you do not want to use email delivery.
defaultValue: 465
- id: $$cap_KUTT_MAIL_USER
label: Mail | User
description: >-
Mail user that sends verification mails.
Leave blank if you do not want to use email delivery.
- id: $$cap_KUTT_MAIL_PASSWORD
label: Mail | Password
description: >-
Password of mail user that sends verification mails.
Leave blank if you do not want to use email delivery.
- id: $$cap_KUTT_MAIL_SECURE
label: Mail | Security
description: >-
Whether to use secure connection to send mails.
Use value `true` (recommended) or `false` when using email delivery.
Leave blank when not using email delivery.
defaultValue: 'true'
- id: $$cap_KUTT_MAIL_FROM
label: Mail | Sender
description: >-
Specify the "From" field.
Example: `Kutt <support@kutt.it>`.
Leave blank to use the mail address only.
- id: $$cap_KUTT_REPORT_EMAIL
label: Contact | Report Mail Address
description: >-
Mail address that will receive submitted reports.
Leave blank to disable.
- id: $$cap_KUTT_CONTACT_EMAIL
label: Contact | Contact Mail Address
description: >-
Support mail address to show on the application.
Leave blank to disable.