Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
73 changes: 37 additions & 36 deletions src/features/instance/config/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,49 +45,30 @@ export function ConfigIndex() {
);
const isSelfManaged = cluster === undefined || clusterIsSelfManaged(cluster);

// Overview lives at the top (rendered by the nav bars below); the rest are kept alphabetical.
const children = canManage && (
<>
<li>
<Link
to={buildAbsoluteLinkToPage(params, 'config/users')}
className={sharedClasses}
inactiveProps={inactiveProps}
activeProps={activeProps}
>
<UsersIcon className="hidden md:inline-block" /> <span className="ms-3">Users</span>
</Link>
</li>
<li>
<Link
to={buildAbsoluteLinkToPage(params, 'config/roles')}
className={sharedClasses}
inactiveProps={inactiveProps}
activeProps={activeProps}
>
<HandshakeIcon className="hidden md:inline-block" /> <span className="ms-3">Roles</span>
</Link>
</li>
{deploymentsAvailable && (
{certsAvailable && (
<li>
<Link
to={buildAbsoluteLinkToPage(params, 'config/deployments')}
to={buildAbsoluteLinkToPage(params, 'config/certificates')}
className={sharedClasses}
inactiveProps={inactiveProps}
activeProps={activeProps}
>
<RocketIcon className="hidden md:inline-block" /> <span className="ms-3">Deployments</span>
<ShieldCheckIcon className="hidden md:inline-block" /> <span className="ms-3">Certificates</span>
</Link>
</li>
)}
{certsAvailable && (
{deploymentsAvailable && (
<li>
<Link
to={buildAbsoluteLinkToPage(params, 'config/certificates')}
to={buildAbsoluteLinkToPage(params, 'config/deployments')}
className={sharedClasses}
inactiveProps={inactiveProps}
activeProps={activeProps}
>
<ShieldCheckIcon className="hidden md:inline-block" /> <span className="ms-3">Certificates</span>
<RocketIcon className="hidden md:inline-block" /> <span className="ms-3">Deployments</span>
</Link>
</li>
)}
Expand All @@ -103,34 +84,54 @@ export function ConfigIndex() {
</Link>
</li>
)}
{certsAvailable && (
<li>
<Link
to={buildAbsoluteLinkToPage(params, 'config/roles')}
className={sharedClasses}
inactiveProps={inactiveProps}
activeProps={activeProps}
>
<HandshakeIcon className="hidden md:inline-block" /> <span className="ms-3">Roles</span>
</Link>
</li>
{
/* Secrets (the replicated hdb_secret store): any instance or cluster on a supported
version — key custody may be file-based (self-hosted) or injected (Fabric). */
}
{secretsSupported && (
<li>
<Link
to={buildAbsoluteLinkToPage(params, 'config/ssh-keys')}
to={buildAbsoluteLinkToPage(params, 'config/secrets')}
className={sharedClasses}
inactiveProps={inactiveProps}
activeProps={activeProps}
>
<KeyIcon className="hidden md:inline-block" /> <span className="ms-3">SSH Keys</span>
<LockIcon className="hidden md:inline-block" /> <span className="ms-3">Secrets</span>
</Link>
</li>
)}
{
/* Secrets (the replicated hdb_secret store): any instance or cluster on a supported
version — key custody may be file-based (self-hosted) or injected (Fabric). */
}
{secretsSupported && (
{certsAvailable && (
<li>
<Link
to={buildAbsoluteLinkToPage(params, 'config/secrets')}
to={buildAbsoluteLinkToPage(params, 'config/ssh-keys')}
className={sharedClasses}
inactiveProps={inactiveProps}
activeProps={activeProps}
>
<LockIcon className="hidden md:inline-block" /> <span className="ms-3">Secrets</span>
<KeyIcon className="hidden md:inline-block" /> <span className="ms-3">SSH Keys</span>
</Link>
</li>
)}
<li>
<Link
to={buildAbsoluteLinkToPage(params, 'config/users')}
className={sharedClasses}
inactiveProps={inactiveProps}
activeProps={activeProps}
>
<UsersIcon className="hidden md:inline-block" /> <span className="ms-3">Users</span>
</Link>
</li>
</>
);

Expand Down