Fix fetching build logs for redeployments (#39)
Part of [Service provider auctions for web deployments](https://www.notion.so/Service-provider-auctions-for-web-deployments-104a6b22d47280dbad51d28aa3a91d75) Co-authored-by: IshaVenikar <ishavenikar7@gmail.com> Reviewed-on: #39
This commit is contained in:
parent
bcb6ac241b
commit
b61682dd20
@ -92,7 +92,7 @@ const DeploymentDetailsCard = ({
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
const fetchDeploymentLogs = async () => {
|
const fetchDeploymentLogs = useCallback(async () => {
|
||||||
setDeploymentLogs('Loading logs...');
|
setDeploymentLogs('Loading logs...');
|
||||||
handleOpenDialog();
|
handleOpenDialog();
|
||||||
const statusUrl = `${deployment.deployer.deployerApiUrl}/${deployment.applicationDeploymentRequestId}`;
|
const statusUrl = `${deployment.deployer.deployerApiUrl}/${deployment.applicationDeploymentRequestId}`;
|
||||||
@ -108,7 +108,7 @@ const DeploymentDetailsCard = ({
|
|||||||
);
|
);
|
||||||
setDeploymentLogs(logsRes);
|
setDeploymentLogs(logsRes);
|
||||||
}
|
}
|
||||||
};
|
}, [deployment.deployer, deployment.applicationDeploymentRequestId]);
|
||||||
|
|
||||||
const renderDeploymentStatus = useCallback(
|
const renderDeploymentStatus = useCallback(
|
||||||
(className?: string) => {
|
(className?: string) => {
|
||||||
@ -127,7 +127,7 @@ const DeploymentDetailsCard = ({
|
|||||||
</Tooltip>
|
</Tooltip>
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
[deployment.status, deployment.commitHash],
|
[deployment.status, deployment.commitHash, fetchDeploymentLogs],
|
||||||
);
|
);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
@ -4,10 +4,7 @@ import { cloneIcon } from 'utils/cloneIcon';
|
|||||||
import { PWAIcon } from './PWAIcon';
|
import { PWAIcon } from './PWAIcon';
|
||||||
import { WebAppIcon } from './WebAppIcon';
|
import { WebAppIcon } from './WebAppIcon';
|
||||||
|
|
||||||
const TEMPLATE_ICONS = [
|
const TEMPLATE_ICONS = ['pwa', 'web'] as const;
|
||||||
'pwa',
|
|
||||||
'web'
|
|
||||||
] as const;
|
|
||||||
export type TemplateIconType = (typeof TEMPLATE_ICONS)[number];
|
export type TemplateIconType = (typeof TEMPLATE_ICONS)[number];
|
||||||
|
|
||||||
export interface TemplateIconProps extends CustomIconProps {
|
export interface TemplateIconProps extends CustomIconProps {
|
||||||
|
@ -73,17 +73,17 @@ const EnvironmentVariablesForm = () => {
|
|||||||
<div className="flex gap-2 p-2">
|
<div className="flex gap-2 p-2">
|
||||||
<Checkbox
|
<Checkbox
|
||||||
label="Production"
|
label="Production"
|
||||||
labelProps={{ className: "text-gray-900 dark:text-white" }}
|
labelProps={{ className: 'text-gray-900 dark:text-white' }}
|
||||||
{...register('environment.production')}
|
{...register('environment.production')}
|
||||||
/>
|
/>
|
||||||
<Checkbox
|
<Checkbox
|
||||||
label="Preview"
|
label="Preview"
|
||||||
labelProps={{ className: "text-gray-900 dark:text-white" }}
|
labelProps={{ className: 'text-gray-900 dark:text-white' }}
|
||||||
{...register('environment.preview')}
|
{...register('environment.preview')}
|
||||||
/>
|
/>
|
||||||
<Checkbox
|
<Checkbox
|
||||||
label="Development"
|
label="Development"
|
||||||
labelProps={{ className: "text-gray-900 dark:text-white" }}
|
labelProps={{ className: 'text-gray-900 dark:text-white' }}
|
||||||
{...register('environment.development')}
|
{...register('environment.development')}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
Reference in New Issue
Block a user