Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ const serviceSchema = z
id: z.number().optional(),
type: z.enum(['http', 'https', 'tcp', 'udp', 'srv']),
internalPort: z.string(),
externalPort: z.number().optional(),
externalHostname: z.string().optional(),
externalDomainId: z.string().optional(),
dnsName: z.string().optional(),
Expand Down Expand Up @@ -183,6 +184,7 @@ export function ContainerFormPage() {
: 'http'
: (s.transportService?.protocol ?? 'tcp'),
internalPort: String(s.internalPort),
externalPort: s.transportService?.externalPort,
externalHostname: s.httpService?.externalHostname || '',
externalDomainId: s.httpService ? String(s.httpService.externalDomainId) : '',
dnsName: s.dnsService?.dnsName || '',
Expand Down Expand Up @@ -627,6 +629,20 @@ export function ContainerFormPage() {
/>
</div>
)}
{(svc.type === 'tcp' || svc.type === 'udp') && (
<div>
<p className="text-[10px] font-medium uppercase tracking-wide text-muted-foreground">
External port
</p>
<p className="font-mono text-sm">
{svc.externalPort ?? (
<span className="text-muted-foreground">
Auto-assigned on save
</span>
)}
</p>
</div>
)}
{svc.type === 'srv' && (
<Input
label="DNS name"
Expand Down
Loading