Skip to content

Commit 211697a

Browse files
authored
Merge branch 'canary' into canary
2 parents c0b64c6 + e00e19e commit 211697a

File tree

6 files changed

+105
-38
lines changed

6 files changed

+105
-38
lines changed

apps/dokploy/components/dashboard/docker/logs/terminal-line.tsx

Lines changed: 23 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -35,45 +35,34 @@ export function TerminalLine({ log, noTimestamp, searchTerm }: LogLineProps) {
3535
})
3636
: "--- No time found ---";
3737

38-
const highlightMessage = (text: string, term: string) => {
39-
if (!term) {
38+
const highlightMessage = (text: string, term: string) => {
39+
if (!term) {
40+
return (
41+
<span
42+
className="transition-colors"
43+
dangerouslySetInnerHTML={{
44+
__html: fancyAnsi.toHtml(text),
45+
}}
46+
/>
47+
);
48+
}
49+
50+
const htmlContent = fancyAnsi.toHtml(text);
51+
const searchRegex = new RegExp(`(${escapeRegExp(term)})`, "gi");
52+
53+
const modifiedContent = htmlContent.replace(
54+
searchRegex,
55+
(match) =>
56+
`<span class="bg-orange-200/80 dark:bg-orange-900/80 font-bold">${match}</span>`,
57+
);
58+
4059
return (
4160
<span
4261
className="transition-colors"
43-
dangerouslySetInnerHTML={{
44-
__html: fancyAnsi.toHtml(text),
45-
}}
62+
dangerouslySetInnerHTML={{ __html: modifiedContent }}
4663
/>
4764
);
48-
}
49-
50-
const htmlContent = fancyAnsi.toHtml(text);
51-
const modifiedContent = htmlContent.replace(
52-
/<span([^>]*)>([^<]*)<\/span>/g,
53-
(match, attrs, content) => {
54-
const searchRegex = new RegExp(`(${escapeRegExp(term)})`, "gi");
55-
if (!content.match(searchRegex)) return match;
56-
57-
const segments = content.split(searchRegex);
58-
const wrappedSegments = segments
59-
.map((segment: string) =>
60-
segment.toLowerCase() === term.toLowerCase()
61-
? `<span${attrs} class="bg-yellow-200/50 dark:bg-yellow-900/50">${segment}</span>`
62-
: segment,
63-
)
64-
.join("");
65-
66-
return `<span${attrs}>${wrappedSegments}</span>`;
67-
},
68-
);
69-
70-
return (
71-
<span
72-
className="transition-colors"
73-
dangerouslySetInnerHTML={{ __html: modifiedContent }}
74-
/>
75-
);
76-
};
65+
};
7766

7867
const tooltip = (color: string, timestamp: string | null) => {
7968
const square = (
Lines changed: 6 additions & 0 deletions
Loading
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
services:
2+
mailpit:
3+
image: axllent/mailpit:v1.22.3
4+
restart: unless-stopped
5+
ports:
6+
- '1025:1025'
7+
volumes:
8+
- 'mailpit-data:/data'
9+
environment:
10+
- MP_SMTP_AUTH_ALLOW_INSECURE=true
11+
- MP_MAX_MESSAGES=5000
12+
- MP_DATABASE=/data/mailpit.db
13+
- MP_UI_AUTH=${MP_UI_AUTH}
14+
- MP_SMTP_AUTH=${MP_SMTP_AUTH}
15+
healthcheck:
16+
test:
17+
- CMD
18+
- /mailpit
19+
- readyz
20+
interval: 5s
21+
timeout: 20s
22+
retries: 10
23+
24+
volumes:
25+
mailpit-data:
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
import {
2+
type DomainSchema,
3+
type Schema,
4+
type Template,
5+
generateBase64,
6+
generatePassword,
7+
generateRandomDomain,
8+
} from "../utils";
9+
10+
export function generate(schema: Schema): Template {
11+
const domains: DomainSchema[] = [
12+
{
13+
host: generateRandomDomain(schema),
14+
port: 8025,
15+
serviceName: "mailpit",
16+
},
17+
];
18+
19+
const defaultPassword = generatePassword();
20+
21+
const envs = [
22+
"# Uncomment below if you want basic auth on UI and SMTP",
23+
`#MP_UI_AUTH=mailpit:${defaultPassword}`,
24+
`#MP_SMTP_AUTH=mailpit:${defaultPassword}`,
25+
];
26+
27+
return {
28+
domains,
29+
envs,
30+
};
31+
}

apps/dokploy/templates/templates.ts

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ export const templates: TemplateData[] = [
2525
"Outline is a self-hosted knowledge base and documentation platform that allows you to build and manage your own knowledge base applications.",
2626
links: {
2727
github: "https://github.com/outline/outline",
28-
website: "https://outline.com/",
29-
docs: "https://docs.outline.com/",
28+
website: "https://getoutline.com/",
29+
docs: "https://docs.getoutline.com/s/guide",
3030
},
3131
logo: "outline.png",
3232
load: () => import("./outline/index").then((m) => m.generate),
@@ -393,6 +393,21 @@ export const templates: TemplateData[] = [
393393
tags: ["chat"],
394394
load: () => import("./open-webui/index").then((m) => m.generate),
395395
},
396+
{
397+
id: "mailpit",
398+
name: "Mailpit",
399+
version: "v1.22.3",
400+
description:
401+
"Mailpit is a tiny, self-contained, and secure email & SMTP testing tool with API for developers.",
402+
logo: "mailpit.svg",
403+
links: {
404+
github: "https://github.com/axllent/mailpit",
405+
website: "https://mailpit.axllent.org/",
406+
docs: "https://mailpit.axllent.org/docs/",
407+
},
408+
tags: ["email", "smtp"],
409+
load: () => import("./mailpit/index").then((m) => m.generate),
410+
},
396411
{
397412
id: "listmonk",
398413
name: "Listmonk",
@@ -426,7 +441,7 @@ export const templates: TemplateData[] = [
426441
{
427442
id: "umami",
428443
name: "Umami",
429-
version: "v2.14.0",
444+
version: "v2.16.1",
430445
description:
431446
"Umami is a simple, fast, privacy-focused alternative to Google Analytics.",
432447
logo: "umami.png",
@@ -1574,3 +1589,4 @@ export const templates: TemplateData[] = [
15741589
load: () => import("./wikijs/index").then((m) => m.generate),
15751590
},
15761591
];
1592+

apps/dokploy/templates/umami/docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
services:
22
umami:
3-
image: ghcr.io/umami-software/umami:postgresql-v2.14.0
3+
image: ghcr.io/umami-software/umami:postgresql-v2.16.1
44
restart: always
55
healthcheck:
66
test: ["CMD-SHELL", "curl http://localhost:3000/api/heartbeat"]

0 commit comments

Comments
 (0)