Skip to content

Commit

Permalink
Refactor restart database messaging
Browse files Browse the repository at this point in the history
  • Loading branch information
kimlisa authored and github-actions committed Oct 3, 2024
1 parent 6e78825 commit f2c6746
Showing 1 changed file with 14 additions and 37 deletions.
51 changes: 14 additions & 37 deletions web/packages/teleport/src/Discover/Database/MutualTls/MutualTls.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -160,17 +160,7 @@ function DbEngineInstructions({ dbEngine }: { dbEngine: DatabaseEngine }) {
},
]}
/>
<Text mt={1}>
Restart the database server to apply the configuration. The
certificate is valid for 90 days so this will require installing an{' '}
<Link
href="https://goteleport.com/docs/enroll-resources/database-access/enroll-self-hosted-databases/postgres-self-hosted/#step-25-create-a-certificatekey-pair"
target="_blank"
>
updated certificate
</Link>{' '}
and restarting the database server before that to continue access.
</Text>
<RestartDatabaseText link="https://goteleport.com/docs/enroll-resources/database-access/enroll-self-hosted-databases/postgres-self-hosted/#step-25-create-a-certificatekey-pair" />
</Box>
);
}
Expand Down Expand Up @@ -259,19 +249,7 @@ function DbEngineInstructions({ dbEngine }: { dbEngine: DatabaseEngine }) {
},
]}
/>
<Text mt={1}>
Restart the database server to apply the configuration. The
certificate is valid for 90 days so this will require
installing an{' '}
<Link
href="https://goteleport.com/docs/enroll-resources/database-access/enroll-self-hosted-databases/mysql-self-hosted/#step-24-create-a-certificatekey-pair"
target="_blank"
>
updated certificate
</Link>{' '}
and restarting the database server before that to continue
access.
</Text>
<RestartDatabaseText link="https://goteleport.com/docs/enroll-resources/database-access/enroll-self-hosted-databases/mysql-self-hosted/#step-24-create-a-certificatekey-pair" />
<Text mt={2}>
See{' '}
<Link
Expand Down Expand Up @@ -302,19 +280,7 @@ function DbEngineInstructions({ dbEngine }: { dbEngine: DatabaseEngine }) {
},
]}
/>
<Text mt={1}>
Restart the database server to apply the configuration. The
certificate is valid for 90 days so this will require
installing an{' '}
<Link
href="https://goteleport.com/docs/enroll-resources/database-access/enroll-self-hosted-databases/mysql-self-hosted/#step-24-create-a-certificatekey-pair"
target="_blank"
>
updated certificate
</Link>{' '}
and restarting the database server before that to continue
access.
</Text>
<RestartDatabaseText link="https://goteleport.com/docs/enroll-resources/database-access/enroll-self-hosted-databases/mysql-self-hosted/#step-24-create-a-certificatekey-pair" />
<Text mt={2}>
See{' '}
<Link
Expand All @@ -334,3 +300,14 @@ function DbEngineInstructions({ dbEngine }: { dbEngine: DatabaseEngine }) {
);
}
}

const RestartDatabaseText = ({ link }: { link: string }) => (
<Text mt={1}>
Restart the database server to apply the configuration. The certificate is
valid for 90 days so this will require installing an{' '}
<Link href={link} target="_blank">
updated certificate
</Link>{' '}
and restarting the database server before that to continue access.
</Text>
);

0 comments on commit f2c6746

Please sign in to comment.