open-vault/ui/app/templates/vault/cluster/replication-dr-promote.hbs
2018-11-02 09:22:22 -06:00

63 lines
2 KiB
Handlebars

<SplashPage as |Page|>
<Page.header>
<h1 class="title is-4">
Disaster Recovery Secondary is&nbsp;enabled
</h1>
</Page.header>
<Page.content>
<nav class="tabs sub-nav is-marginless">
<ul>
<li class="{{if (eq action '') 'is-active'}}">
{{#link-to 'vault.cluster.replication-dr-promote' (query-params action='')}}
Operation token
{{/link-to}}
</li>
<li class="{{if (eq action 'update') 'is-active'}}">
{{#link-to 'vault.cluster.replication-dr-promote' (query-params action='update')}}
Update primary
{{/link-to}}
</li>
<li class="{{if (eq action 'promote') 'is-active'}}">
{{#link-to 'vault.cluster.replication-dr-promote' (query-params action='promote')}}
Promote
{{/link-to}}
</li>
</ul>
</nav>
{{#if (eq action 'promote')}}
<AlertBanner
@type="warning"
@title="Caution"
@message="Vault replication is not designed for active-active usage and enabling two performance primaries should never be done, as it can lead to data loss if they or their secondaries are ever reconnected."
@class="unseal-warning"
data-test-cluster-status
/>
<ReplicationActions
@replicationMode="dr"
@selectedAction="promote"
@model={{model}}
/>
{{/if}}
{{#if (eq action 'update')}}
<ReplicationActions
@replicationMode="dr"
@selectedAction="updatePrimary"
@model={{model}}
/>
{{/if}}
{{#unless action}}
<ShamirFlow
@action="generate-dr-operation-token"
@buttonText="Promote cluster"
@fetchOnInit=true
@generateAction=true
>
<p>
Generate an Operation Token by entering a portion of the master key.
Once all portions are entered, the generated operation token may be used to manage your Seondary Disaster Recovery cluster.
</p>
</ShamirFlow>
{{/unless}}
</Page.content>
</SplashPage>