Get DNS records for all completed deployments
This commit is contained in:
parent
dd12369cb2
commit
6d2b341d48
@ -17,7 +17,7 @@ import { DatabaseConfig } from './config';
|
||||
import { User } from './entity/User';
|
||||
import { Organization } from './entity/Organization';
|
||||
import { Project } from './entity/Project';
|
||||
import { Deployment } from './entity/Deployment';
|
||||
import { Deployment, DeploymentStatus } from './entity/Deployment';
|
||||
import { ProjectMember } from './entity/ProjectMember';
|
||||
import { EnvironmentVariable } from './entity/EnvironmentVariable';
|
||||
import { Domain } from './entity/Domain';
|
||||
@ -630,8 +630,9 @@ export class Database {
|
||||
const deployment = await deploymentRepository.findOne({
|
||||
where: {
|
||||
project: {
|
||||
id: projectId
|
||||
id: projectId,
|
||||
},
|
||||
status: DeploymentStatus.Ready
|
||||
}, order: {
|
||||
createdAt: "DESC",
|
||||
},
|
||||
|
@ -76,11 +76,11 @@ const Config = () => {
|
||||
|
||||
const dnsData = await client.getLatestDNSDataByProjectId(id);
|
||||
|
||||
setIPAddress(dnsData.value);
|
||||
|
||||
if (!dnsData || !dnsData.value) {
|
||||
setIPAddress("Not Configured")
|
||||
}
|
||||
|
||||
setIPAddress(dnsData.value);
|
||||
};
|
||||
|
||||
fetchDNSData();
|
||||
|
Loading…
Reference in New Issue
Block a user