mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-09-22 13:39:35 +00:00
fix: restructure and requested changes
This commit is contained in:
@@ -112,7 +112,7 @@ const redeployService = async (secretSync: TRenderSyncWithCredentials) => {
|
|||||||
{
|
{
|
||||||
headers: {
|
headers: {
|
||||||
Authorization: `Bearer ${apiKey}`,
|
Authorization: `Bearer ${apiKey}`,
|
||||||
"Accept-Encoding": "application/json"
|
Accept: "application/json"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ import {
|
|||||||
useRenderConnectionListServices
|
useRenderConnectionListServices
|
||||||
} from "@app/hooks/api/appConnections/render";
|
} from "@app/hooks/api/appConnections/render";
|
||||||
import { SecretSync } from "@app/hooks/api/secretSyncs";
|
import { SecretSync } from "@app/hooks/api/secretSyncs";
|
||||||
import { RenderSyncScope, RenderSyncType } from "@app/hooks/api/secretSyncs/render-sync";
|
import { RenderSyncScope, RenderSyncType } from "@app/hooks/api/secretSyncs/types/render-sync";
|
||||||
|
|
||||||
import { TSecretSyncForm } from "../schemas";
|
import { TSecretSyncForm } from "../schemas";
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ import { z } from "zod";
|
|||||||
|
|
||||||
import { BaseSecretSyncSchema } from "@app/components/secret-syncs/forms/schemas/base-secret-sync-schema";
|
import { BaseSecretSyncSchema } from "@app/components/secret-syncs/forms/schemas/base-secret-sync-schema";
|
||||||
import { SecretSync } from "@app/hooks/api/secretSyncs";
|
import { SecretSync } from "@app/hooks/api/secretSyncs";
|
||||||
import { RenderSyncScope, RenderSyncType } from "@app/hooks/api/secretSyncs/render-sync";
|
import { RenderSyncScope, RenderSyncType } from "@app/hooks/api/secretSyncs/types/render-sync";
|
||||||
|
|
||||||
export const RenderSyncDestinationSchema = BaseSecretSyncSchema(
|
export const RenderSyncDestinationSchema = BaseSecretSyncSchema(
|
||||||
z.object({
|
z.object({
|
||||||
|
|||||||
@@ -4,9 +4,9 @@ import {
|
|||||||
SecretSyncImportBehavior,
|
SecretSyncImportBehavior,
|
||||||
SecretSyncInitialSyncBehavior
|
SecretSyncInitialSyncBehavior
|
||||||
} from "@app/hooks/api/secretSyncs";
|
} from "@app/hooks/api/secretSyncs";
|
||||||
import { RenderSyncScope } from "@app/hooks/api/secretSyncs/render-sync";
|
|
||||||
import { GcpSyncScope } from "@app/hooks/api/secretSyncs/types/gcp-sync";
|
import { GcpSyncScope } from "@app/hooks/api/secretSyncs/types/gcp-sync";
|
||||||
import { HumanitecSyncScope } from "@app/hooks/api/secretSyncs/types/humanitec-sync";
|
import { HumanitecSyncScope } from "@app/hooks/api/secretSyncs/types/humanitec-sync";
|
||||||
|
import { RenderSyncScope } from "@app/hooks/api/secretSyncs/types/render-sync";
|
||||||
|
|
||||||
export const SECRET_SYNC_MAP: Record<SecretSync, { name: string; image: string }> = {
|
export const SECRET_SYNC_MAP: Record<SecretSync, { name: string; image: string }> = {
|
||||||
[SecretSync.AWSParameterStore]: { name: "AWS Parameter Store", image: "Amazon Web Services.png" },
|
[SecretSync.AWSParameterStore]: { name: "AWS Parameter Store", image: "Amazon Web Services.png" },
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
import { SecretSync, SecretSyncImportBehavior } from "@app/hooks/api/secretSyncs";
|
import { SecretSync, SecretSyncImportBehavior } from "@app/hooks/api/secretSyncs";
|
||||||
import { DiscriminativePick } from "@app/types";
|
import { DiscriminativePick } from "@app/types";
|
||||||
|
|
||||||
import { TRenderSync } from "../render-sync";
|
|
||||||
import { TOnePassSync } from "./1password-sync";
|
import { TOnePassSync } from "./1password-sync";
|
||||||
import { TAwsParameterStoreSync } from "./aws-parameter-store-sync";
|
import { TAwsParameterStoreSync } from "./aws-parameter-store-sync";
|
||||||
import { TAwsSecretsManagerSync } from "./aws-secrets-manager-sync";
|
import { TAwsSecretsManagerSync } from "./aws-secrets-manager-sync";
|
||||||
@@ -24,6 +23,7 @@ import { THerokuSync } from "./heroku-sync";
|
|||||||
import { THumanitecSync } from "./humanitec-sync";
|
import { THumanitecSync } from "./humanitec-sync";
|
||||||
import { TOCIVaultSync } from "./oci-vault-sync";
|
import { TOCIVaultSync } from "./oci-vault-sync";
|
||||||
import { TRailwaySync } from "./railway-sync";
|
import { TRailwaySync } from "./railway-sync";
|
||||||
|
import { TRenderSync } from "./render-sync";
|
||||||
import { TSupabaseSync } from "./supabase";
|
import { TSupabaseSync } from "./supabase";
|
||||||
import { TTeamCitySync } from "./teamcity-sync";
|
import { TTeamCitySync } from "./teamcity-sync";
|
||||||
import { TTerraformCloudSync } from "./terraform-cloud-sync";
|
import { TTerraformCloudSync } from "./terraform-cloud-sync";
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import { AppConnection } from "@app/hooks/api/appConnections/enums";
|
import { AppConnection } from "@app/hooks/api/appConnections/enums";
|
||||||
import { SecretSync } from "@app/hooks/api/secretSyncs";
|
import { SecretSync } from "@app/hooks/api/secretSyncs";
|
||||||
import { TRootSecretSync } from "@app/hooks/api/secretSyncs/types/root-sync";
|
import { RootSyncOptions, TRootSecretSync } from "@app/hooks/api/secretSyncs/types/root-sync";
|
||||||
|
|
||||||
export type TRenderSync = TRootSecretSync & {
|
export type TRenderSync = TRootSecretSync & {
|
||||||
destination: SecretSync.Render;
|
destination: SecretSync.Render;
|
||||||
@@ -17,7 +17,7 @@ export type TRenderSync = TRootSecretSync & {
|
|||||||
id: string;
|
id: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
syncOptions: {
|
syncOptions: RootSyncOptions & {
|
||||||
autoRedeployServices?: boolean;
|
autoRedeployServices?: boolean;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
import { useRenderConnectionListServices } from "@app/hooks/api/appConnections/render";
|
import { useRenderConnectionListServices } from "@app/hooks/api/appConnections/render";
|
||||||
import { TRenderSync } from "@app/hooks/api/secretSyncs/render-sync";
|
import { TRenderSync } from "@app/hooks/api/secretSyncs/types/render-sync";
|
||||||
|
|
||||||
import { getSecretSyncDestinationColValues } from "../helpers";
|
import { getSecretSyncDestinationColValues } from "../helpers";
|
||||||
import { SecretSyncTableCell } from "../SecretSyncTableCell";
|
import { SecretSyncTableCell } from "../SecretSyncTableCell";
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import { GenericFieldLabel } from "@app/components/secret-syncs";
|
import { GenericFieldLabel } from "@app/components/secret-syncs";
|
||||||
import { useRenderConnectionListServices } from "@app/hooks/api/appConnections/render";
|
import { useRenderConnectionListServices } from "@app/hooks/api/appConnections/render";
|
||||||
import { TRenderSync } from "@app/hooks/api/secretSyncs/render-sync";
|
import { TRenderSync } from "@app/hooks/api/secretSyncs/types/render-sync";
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
secretSync: TRenderSync;
|
secretSync: TRenderSync;
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import { GenericFieldLabel } from "@app/components/secret-syncs";
|
import { GenericFieldLabel } from "@app/components/secret-syncs";
|
||||||
import { Badge } from "@app/components/v2";
|
import { Badge } from "@app/components/v2";
|
||||||
import { TRenderSync } from "@app/hooks/api/secretSyncs/render-sync";
|
import { TRenderSync } from "@app/hooks/api/secretSyncs/types/render-sync";
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
secretSync: TRenderSync;
|
secretSync: TRenderSync;
|
||||||
@@ -12,16 +12,10 @@ export const RenderSyncOptionsSection = ({ secretSync }: Props) => {
|
|||||||
} = secretSync;
|
} = secretSync;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<GenericFieldLabel label="Auto Redeploy Services">
|
||||||
{autoRedeployServices ? (
|
<Badge variant={autoRedeployServices ? "success" : "danger"}>
|
||||||
<GenericFieldLabel label="Auto Redeploy Services">
|
{autoRedeployServices ? "Enabled" : "Disabled"}
|
||||||
<Badge variant="success">Enabled</Badge>
|
</Badge>
|
||||||
</GenericFieldLabel>
|
</GenericFieldLabel>
|
||||||
) : (
|
|
||||||
<GenericFieldLabel label="Auto Redeploy Services">
|
|
||||||
<Badge variant="danger">Disabled</Badge>
|
|
||||||
</GenericFieldLabel>
|
|
||||||
)}
|
|
||||||
</div>
|
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user