Fix: Linting issues

This commit is contained in:
DrMxrcy
2024-11-19 11:56:23 -05:00
parent 3698e8a827
commit 5cbdc8fad9
2 changed files with 41 additions and 40 deletions

View File

@@ -1,46 +1,46 @@
import { import {
type DomainSchema, type DomainSchema,
type Schema, type Schema,
type Template, type Template,
generateBase64, generateBase64,
generatePassword, generatePassword,
generateRandomDomain, generateRandomDomain,
} from "../utils"; } from "../utils";
export function generate(schema: Schema): Template { export function generate(schema: Schema): Template {
const mainDomain = generateRandomDomain(schema); const mainDomain = generateRandomDomain(schema);
const secretKeyBase = generateBase64(64); const secretKeyBase = generateBase64(64);
const postgresPassword = generatePassword(); const postgresPassword = generatePassword();
const domains: DomainSchema[] = [ const domains: DomainSchema[] = [
{ {
host: mainDomain, host: mainDomain,
port: 3000, port: 3000,
serviceName: "chatwoot-rails", serviceName: "chatwoot-rails",
}, },
]; ];
const envs = [ const envs = [
`FRONTEND_URL=http://${mainDomain}`, `FRONTEND_URL=http://${mainDomain}`,
`SECRET_KEY_BASE=${secretKeyBase}`, `SECRET_KEY_BASE=${secretKeyBase}`,
`RAILS_ENV=production`, "RAILS_ENV=production",
`NODE_ENV=production`, "NODE_ENV=production",
`INSTALLATION_ENV=docker`, "INSTALLATION_ENV=docker",
`RAILS_LOG_TO_STDOUT=true`, "RAILS_LOG_TO_STDOUT=true",
`LOG_LEVEL=info`, "LOG_LEVEL=info",
`DEFAULT_LOCALE=en`, "DEFAULT_LOCALE=en",
`POSTGRES_HOST=chatwoot-postgres`, "POSTGRES_HOST=chatwoot-postgres",
`POSTGRES_PORT=5432`, "POSTGRES_PORT=5432",
`POSTGRES_DATABASE=chatwoot`, "POSTGRES_DATABASE=chatwoot",
`POSTGRES_USERNAME=postgres`, "POSTGRES_USERNAME=postgres",
`POSTGRES_PASSWORD=${postgresPassword}`, `POSTGRES_PASSWORD=${postgresPassword}`,
`REDIS_URL=redis://chatwoot-redis:6379`, "REDIS_URL=redis://chatwoot-redis:6379",
`ENABLE_ACCOUNT_SIGNUP=false`, "ENABLE_ACCOUNT_SIGNUP=false",
`ACTIVE_STORAGE_SERVICE=local`, "ACTIVE_STORAGE_SERVICE=local",
]; ];
return { return {
domains, domains,
envs, envs,
}; };
} }

View File

@@ -841,7 +841,8 @@ export const templates: TemplateData[] = [
id: "chatwoot", id: "chatwoot",
name: "Chatwoot", name: "Chatwoot",
version: "v3.14.1", version: "v3.14.1",
description: "Open-source customer engagement platform that provides a shared inbox for teams, live chat, and omnichannel support.", description:
"Open-source customer engagement platform that provides a shared inbox for teams, live chat, and omnichannel support.",
logo: "chatwoot.svg", logo: "chatwoot.svg",
links: { links: {
github: "https://github.com/chatwoot/chatwoot", github: "https://github.com/chatwoot/chatwoot",