Commit Graph

639 Commits

Author SHA1 Message Date
Jai Bhagat
d0f8322786 ui: fix auto-fixable linting errors 2022-01-20 09:46:45 -05:00
Luiz Aoqui
61340142fa ui: fix test (#11870) 2022-01-18 10:36:10 -05:00
Jai Bhagat
08a5e867e2 test: add test stories for clicking allocation summary 2022-01-14 10:23:09 -05:00
Jai Bhagat
ecaf46c6c9 refact: allocation and child summaries into ember-cli-page-object components 2022-01-14 10:20:33 -05:00
Jai Bhagat
c1bef174ee fix: typo in data-test-selector 2022-01-14 10:19:01 -05:00
Luiz Aoqui
6b488bdad3 Fix ACL requirements for job details UI (#11672) 2022-01-12 21:26:02 -05:00
Luiz Aoqui
f34e76a68f ui: fix CI (#11785) 2022-01-06 16:01:55 -05:00
Jai Bhagat
4d39d887d3 fix: add ember-a11y-testing-audit-call 2021-12-21 07:47:22 -05:00
Jai Bhagat
1a2914b9fe fix: test specs should expect to receive breadcrumb titles 2021-12-21 07:47:06 -05:00
Jai Bhagat
5ca9ebe04d fix: update breadcrumb tests according to new breadcrumb structure 2021-12-21 07:46:28 -05:00
Jai Bhagat
0ea0e69f31 refactor: delete unit tests for old breadcrumbs service 2021-12-21 07:46:28 -05:00
Jai Bhagat
2cc8a37a83 test: breadcrumbs functionality 2021-12-21 07:46:28 -05:00
Jai Bhagat
972b52ad91 chore: write tests for trigger component 2021-12-21 07:46:28 -05:00
Jai
ca8af7314a Merge pull request #11545 from hashicorp/f-ui/add-alloc-filters-on-table
Add Allocation Filters in Client View
2021-12-18 09:39:53 -05:00
Jai
296a29f0dd Merge pull request #11544 from hashicorp/f-ui/add-filters-to-allocs
Add filters to Allocations
2021-12-18 09:38:28 -05:00
Luiz Aoqui
efd05eaa54 ui: fix volume serializer tests 2021-12-17 20:23:28 -05:00
Luiz Aoqui
e6ee0619c0 ui: fix allocation serializer tests 2021-12-17 20:02:59 -05:00
Luiz Aoqui
ad80c84aff ui: fix job allocation filter by status, remove version filter, and add tests 2021-12-17 19:50:43 -05:00
Luiz Aoqui
770bb0534a ui: fix linting 2021-12-17 18:55:41 -05:00
Luiz Aoqui
1d773d0d9e ui: fix task group alloc filter and add tests 2021-12-17 18:49:47 -05:00
Luiz Aoqui
648b71c96a ui: display empty message in the client details page if there are no allocations to show 2021-12-17 18:49:47 -05:00
Luiz Aoqui
6112620590 ui: fix client details page alloc status filter and replace task group with namespace and job 2021-12-17 18:49:42 -05:00
Luiz Aoqui
f54a89177a UI: Add tests for prodcut links (#11645) 2021-12-07 19:51:17 -05:00
Tim Gross
55c29fbf50 api: return 404 for alloc FS list/stat endpoints (#11482)
* api: return 404 for alloc FS list/stat endpoints

If the alloc filesystem doesn't have a file requested by the List
Files or Stat File API, we currently return a HTTP 500 error with the
expected "file not found" error message. Return a HTTP 404 error
instead.

* update FS Handler

Previously the FS handler would interpret a 500 status as a 404
in the adapter layer by checking if the response body contained
the text  or is the response status
was 500 and then throw an error code for 404.

Co-authored-by: Jai Bhagat <jaybhagat841@gmail.com>
2021-11-17 11:15:07 -05:00
Luiz Aoqui
3648346da4 ui: fix tests broken by d3-format upgrade 2021-11-05 18:09:13 -04:00
Luiz Aoqui
52f1ac0380 ui: fix tests broken by d3-format upgrade 2021-11-05 18:09:13 -04:00
pangratz
5c99b9cdc4 test: ensure we return a valid JSON response
An empty string is not a valid JSON response which is expected by this
endpoint.
2021-11-04 16:07:06 +01:00
Luiz Aoqui
f729ba5df4 ui: persist node drain settings (#11368) 2021-10-22 10:51:31 -04:00
Luiz Aoqui
f88dc37fc2 ui: display Nomad version in the Clients and Servers table (#11366) 2021-10-22 10:33:06 -04:00
Luiz Aoqui
d599c63c9c ui: create tooltip component (#11363) 2021-10-21 13:12:33 -04:00
Luiz Aoqui
f757f619f3 ui: set * as the default namespace selector (#11357) 2021-10-21 10:24:07 -04:00
Luiz Aoqui
d4c3989e2a Update job details box (#11288) 2021-10-12 16:36:10 -04:00
Jai
0564f9fa68 System Batch UI, Client Status Bar Chart and Client Tab page view (#11078) 2021-10-07 17:11:38 -04:00
Luiz Aoqui
cf7675a376 ui: set the job namespace when redirecting after the job is dispatched (#11141) 2021-09-07 12:27:33 -04:00
Luiz Aoqui
ea47fa7d90 ui: set namespace when looking for and displaying children jobs (#11110) 2021-09-01 14:40:25 -04:00
Jai
c86f30d7f1 Merge pull request #10666 from hashicorp/b-ui/search-namespaces
ui: Fix fuzzy search namespace-handling
2021-08-10 13:13:20 -04:00
Jai Bhagat
00df085e71 edit hierarchy to lead with namespace before job 2021-08-10 10:35:36 -04:00
Luiz Aoqui
332dc88101 ui: fix job dispatch page when job doesn't have any meta fields (#10934) 2021-08-03 13:50:43 -04:00
Jai Bhagat
2649d19668 edit fuzzy search callback logic
Namespaces are set-up in Nomad to be an object that has an id property.
However, namespaces actually don't have that shape. Our search was expecting
a namespace object, but we actually don't have a namespace assigned to jobs
in our config and namespace is set to null. Normally, these namespaces would
be set to default, but that would require us to refactor our Mirage config
if we wanted to assert that namespaces are 'default' and not null. So this is
a bandaid solution.
2021-07-26 17:25:43 -04:00
Jai Bhagat
d3bf10335a Merge remote-tracking branch 'origin/main' into b-ui/search-namespaces 2021-07-22 15:16:30 -04:00
Jai Bhagat
3e07db87d4 address merge conflicts 2021-07-21 17:30:11 -04:00
Nicholas Cioli
801a7324a3 ui: add parameterized dispatch interface (#10675)
* ui: add parameterized dispatch interface

This commit adds a new interface for dispatching parameteried jobs, if
the user has the right permissions. The UI can be accessed by viewing a
parameterized job and clicking on the "Dispatch Job" button located in
the "Job Launches" section.

* fix failing lint test

* clean up dispatch and remove meta

This commit cleans up a few things that had typos and
inconsistent naming. In line with this, the custom
`meta` view was removed in favor of using the
included `AttributesTable`.

* ui: encode dispatch job payload and start adding tests

* ui: remove unused test imports

* ui: redesign job dispatch form

* ui: initial acceptance tests for dispatch job

* ui: generate parameterized job children with correct id format

* ui: fix job dispatch breadcrumb link

* ui: refactor job dispatch component into glimmer component and add form validation

* ui: remove unused CSS class

* ui: align job dispatch button

* ui: handle namespace-specific requests on job dispatch

* ui: rename payloadMissing to payloadHasError

* ui: don't re-fetch job spec on dispatch job

* ui: keep overview tab selected on job dispatch page

* ui: fix task and task-group linting

* ui: URL encode job id on dispatch job tests

* ui: fix error when job meta is null

* ui: handle job dispatch from adapter

* ui: add more tests for dispatch job page

* ui: add "job dispatch" capability check

* ui: update job dispatch from code review

Co-authored-by: Luiz Aoqui <luiz@hashicorp.com>
2021-07-20 18:27:41 -04:00
Jai Bhagat
b09559eb9e refactoring for same regression in job versions
In job versions, if you have an ACL token with a write policy
you should be able to revert a job, however, that was not the
case here. This is because we're using ember-can to check if
the user can run a job. That permission relies on policiesSupportRunning
which uses a function called namespaceIncludesCapability. We're going to
need to refactor any cases that use this function.
2021-07-20 16:24:42 -04:00
Jai Bhagat
d92261e2b0 edit ember-can to add additional attribute for namespace
We wanted the ability to get our namespace from query params
in order to do this, we're using additional attributes via
ember-can to set a bound property directly from our
handlebar file. This sets us up better in the event that
the namespace filter changes on the UI because our handlebar
file will be aware of the change, whereas our ability may not
update as the namespace filter updates.
2021-07-13 15:14:38 -04:00
Georges-Etienne Legendre
86fca8f513 Capture ACL Token from self API call for Reverse Proxy use-case (#10563)
* Proposed fix for #10561

Signed-off-by: Georges-Etienne Legendre <legege@legege.com>

* Add acceptance tests for reverse proxy use-case

Signed-off-by: Georges-Etienne Legendre <legege@legege.com>

* Use reads instead of computed/get

Signed-off-by: Georges-Etienne Legendre <legege@legege.com>

* Move back the line closer to the task

Signed-off-by: Georges-Etienne Legendre <legege@legege.com>

* skip a11y-audit-called lint rule on reverse proxy tests

Co-authored-by: Luiz Aoqui <luiz@hashicorp.com>
2021-07-12 20:42:08 -04:00
Jai Bhagat
bcb3e64237 add name property back to agent schema in ember mirage
The name property had to be added back to the agent schema
in the Agent Factory because the /agent/monitor endpoint in
the config finds agents by their names and since member is not
a proper entity in our Mirage Config we can't just findBy name
of the member. So although we're following the correct schema
we're set-up to rely on this.
2021-07-11 16:09:43 -04:00
Jai Bhagat
a9da541412 refactor tests that depend on Agent fixutres in Mirage 2021-07-08 08:01:15 -04:00
Florian Apolloner
5f968baf0d Fixed global-search keyboard shortcut for non-english keyboard layouts.
Closes #10646
2021-06-07 13:32:38 -04:00
Buck Doyle
6f999522c7 Add namespace to allocation search result label
Is “@ namespace” sensible? 🧐
2021-05-27 14:03:05 -05:00
Buck Doyle
c075ee5735 Change fuzzy search to search all namespaces
Thanks to @apollo13 for reporting this in #10101.
2021-05-27 13:45:34 -05:00