Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 8151ec094d | |||
| 63e85d5306 |
@@ -77,6 +77,9 @@ model ProvisionedDevice {
|
||||
kernel String?
|
||||
distro String?
|
||||
device Json?
|
||||
agentVersion String? @map("agent_version")
|
||||
agentUpdatedAt DateTime? @map("agent_updated_at") @db.Timestamptz(3)
|
||||
agentLastSeenAt DateTime? @map("agent_last_seen_at") @db.Timestamptz(3)
|
||||
installedAt DateTime @default(now()) @map("installed_at") @db.Timestamptz(3)
|
||||
lastProvisionedAt DateTime @default(now()) @map("last_provisioned_at") @db.Timestamptz(3)
|
||||
createdAt DateTime @default(now()) @map("created_at") @db.Timestamptz(3)
|
||||
@@ -85,6 +88,7 @@ model ProvisionedDevice {
|
||||
@@unique([accountEmail, tailscaleHostname])
|
||||
@@index([accountEmail])
|
||||
@@index([tailscaleHostname])
|
||||
@@index([agentLastSeenAt])
|
||||
@@map("provisioned_devices")
|
||||
}
|
||||
|
||||
|
||||
@@ -1008,9 +1008,14 @@ export class AppsService {
|
||||
}
|
||||
|
||||
const app = release?.app ?? quickBuild!.component.app;
|
||||
const images = release
|
||||
const releaseImages = release
|
||||
? parseReleaseImageTags(release.imageTags).images
|
||||
: { [quickBuild!.component.name]: quickBuild!.image! };
|
||||
const images = Object.fromEntries(
|
||||
Object.entries(releaseImages).filter(([componentName]) => (
|
||||
app.components.find((component) => component.name === componentName)?.type !== 'DATABASE'
|
||||
)),
|
||||
);
|
||||
const deploymentLabel = release
|
||||
? `${app.name} ${release.version}`
|
||||
: `${app.name} ${quickBuild!.component.name} ${quickBuild!.commitSha?.slice(0, 7) ?? 'quick'}`;
|
||||
@@ -3498,7 +3503,8 @@ function createReleaseImageTags(
|
||||
const imageSource = normalizeImageSource(component.imageSource, component.type);
|
||||
if (
|
||||
!images[component.name]
|
||||
&& (imageSource === 'EXTERNAL' || imageSource === 'DATABASE')
|
||||
&& imageSource === 'EXTERNAL'
|
||||
&& component.type !== 'DATABASE'
|
||||
&& component.externalImage?.trim()
|
||||
) {
|
||||
images[component.name] = component.externalImage.trim();
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import {
|
||||
BadRequestException,
|
||||
BadGatewayException,
|
||||
Injectable,
|
||||
UnauthorizedException,
|
||||
@@ -118,6 +119,10 @@ export class GiteaService {
|
||||
params.set('page', String(page));
|
||||
if (query.sha) {
|
||||
params.set('sha', query.sha);
|
||||
const { branches } = await this.listBranches(owner, repo) as { branches: Array<{ name?: string }> };
|
||||
if (!branches.some((branch) => branch.name === query.sha)) {
|
||||
throw new BadRequestException('해당 브랜치가 없습니다.');
|
||||
}
|
||||
}
|
||||
if (query.since) {
|
||||
params.set('since', query.since);
|
||||
|
||||
Reference in New Issue
Block a user