github.com/hernad/nomad@v1.6.112/ui/app/templates/application.hbs (about) 1 {{! 2 Copyright (c) HashiCorp, Inc. 3 SPDX-License-Identifier: MPL-2.0 4 ~}} 5 6 {{page-title 7 (if this.system.shouldShowRegions (concat this.system.activeRegion " - ")) 8 (if this.system.agent.config.UI.Label.Text (concat this.system.agent.config.UI.Label.Text " - ")) 9 "Nomad" 10 separator=" - " 11 }} 12 <SvgPatterns /> 13 14 <section class="notifications"> 15 {{#each this.notifications.queue as |flash|}} 16 <FlashMessage @flash={{flash}} as |component flash close|> 17 <Hds::Toast 18 @color={{or flash.color "neutral"}} 19 @onDismiss={{ 20 queue 21 (action close) 22 (action (optional flash.customCloseAction)) 23 24 }} 25 as |T|> 26 {{#if flash.title}} 27 <T.Title>{{flash.title}}</T.Title> 28 {{/if}} 29 {{#if flash.message}} 30 <T.Description>{{flash.message}}</T.Description> 31 {{/if}} 32 {{#if flash.customAction}} 33 <T.Button @text={{flash.customAction.label}} @color="secondary" {{on "click" (action flash.customAction.action)}} /> 34 {{/if}} 35 </Hds::Toast> 36 </FlashMessage> 37 {{/each}} 38 </section> 39 40 <KeyboardShortcutsModal /> 41 42 <PortalTarget @name="log-sidebar-portal" /> 43 44 {{#if this.error}} 45 <div class="error-container"> 46 <div data-test-error class="error-message"> 47 {{#if this.isNoLeader}} 48 <h1 data-test-error-title class="title is-spaced">No Cluster Leader</h1> 49 <p data-test-error-message class="subtitle"> 50 The cluster has no leader. 51 <a href="https://developer.hashicorp.com/nomad/tutorials/manage-clusters/outage-recovery"> 52 Read about Outage Recovery.</a> 53 </p> 54 {{else if this.isOTTExchange}} 55 <h1 data-test-error-title class="title is-spaced">Token Exchange Error</h1> 56 <p data-test-error-message class="subtitle"> 57 Failed to exchange the one-time token. 58 </p> 59 {{else if this.is500}} 60 <h1 data-test-error-title class="title is-spaced">Server Error</h1> 61 <p data-test-error-message class="subtitle">A server error prevented 62 data from being sent to the client.</p> 63 {{else if this.is404}} 64 <h1 data-test-error-title class="title is-spaced">Not Found</h1> 65 <p data-test-error-message class="subtitle">What you're looking for 66 couldn't be found. It either doesn't exist or you are not authorized 67 to see it.</p> 68 {{else if this.is403}} 69 <h1 data-test-error-title class="title is-spaced">Not Authorized</h1> 70 {{#if this.token.secret}} 71 <p data-test-error-message class="subtitle">Your 72 <LinkTo @route="settings.tokens" data-test-error-acl-link>ACL token</LinkTo> 73 does not provide the required permissions. Contact your 74 administrator if this is an error.</p> 75 {{else}} 76 <p data-test-error-message class="subtitle">Provide an 77 <LinkTo @route="settings.tokens" data-test-error-acl-link>ACL token</LinkTo> 78 with requisite permissions to view this.</p> 79 {{/if}} 80 {{else}} 81 <h1 data-test-error-title class="title is-spaced">Error</h1> 82 <p data-test-error-message class="subtitle">Something went wrong.</p> 83 {{/if}} 84 {{#if (eq this.config.environment "development")}} 85 <pre class="error-stack-trace"><code>{{this.errorStr}}</code></pre> 86 {{/if}} 87 </div> 88 <div class="error-links"> 89 <LinkTo @route="jobs" data-test-error-jobs-link class="button is-white">Go 90 to Jobs</LinkTo> 91 <LinkTo 92 @route="clients" 93 data-test-error-clients-link 94 class="button is-white" 95 >Go to Clients</LinkTo> 96 <LinkTo 97 @route="settings.tokens" 98 data-test-error-signin-link 99 class="button is-white" 100 >Go to Sign In</LinkTo> 101 </div> 102 </div> 103 {{else}} 104 {{outlet}} 105 {{/if}}