* create skeleton of team management page and hook it up with routing
* added reducers and kolide api teams code, hooked up empty state
* request for get all teams and remove unused loading bar
* fix sending teams response to store
* added create team functionality|gs
* added edit and delete fuctionality to teams management
* fixed up some edge cases for deleting and editing teams
* remove unused UserRow
* get list of teams for user to add new users to, fix up Userform
* add prettier and have it format all js code except website:
:
* trying running prettier check in CI
* fix runs on in CI
* change CI job name
* fix prettier erros and fix CI
Label flow
- Create a new label and make sure it shows up on the hosts page
- Edit the label name
- Delete the label
Query flow
- Create a new saved query
- Edit the query
- Delete the query
Pack flow
- Create a pack
- Edit the pack name
- Schedule a query
- Remove a query from the pack
- Delete the pack
Closes#597
- unhandledPromiseRejection errors caused test failures on Node 15.
Instead verbose log these for later followup.
- Fix uses of Nock in tests
- Fix some warnings in tests
- Upgrade some test dependencies
* e2e test for manage user page, and updating styles for ui components
* make checkbox more accessible and create e2e test around creating user
* add react testing library and use it for radio testing
* clean up comments
* update docs and clean up
* start with making nav horizontal and updating nav and main content areas
* remove unneded subnav styling and JS code
* remove unused isSmallNav and --small styles
* remove isSmallNav in reducer and fix tests
* change 'admin' to 'settings'
* remove unnneded username to logo
* change account page urls
* Add user avatar dropdown to nav
* remove unused background colour on company logo
* get tabbing to work correctly
* implement styling of tab and page descriptions
* change default settings nav to organisation settings
* remove more unneeded subnav code
* fix some broken tests after changes
* pull out getdefaultTabIndex in settingsWrapper
* sticky sub nav for settings pages
* tweak zindex for setting subnav
* updated yarn.lock
* update icons
* fix collapsing nav items
* tweak avatar dropdown styles
* remove sidebar on osquery page
Beginning of an e2e testing framework for the fleet application.
This uses [Cypress](https://www.cypress.io/) to implement a first end-to-end test in Fleet.
* chnage webpack to resolve typescript modules. convert TextCell to TS
* change headercell and statuscell to ts
* ignore casesensitve error, seems a bit buggy
* ignore camelcase error, we already use snakecase many places
* updated LinkCell and modules it depends on to typescript
* fix up some warnings from changes
* fix more types in textcell and hosttableconfig
* use alias imports
* add require button state interfcae
* updated typescript version and tsconfig in project
* updated eslint version
* change from experimental export to supported export
* removed accidentally added script
* turn off buggy jsx-a11y eslint rules
* remove unused tslint.json
* fix wrong jsx-a11y depedency
* use correct eslint-plugin-jsx-a11y version
* fix rest of linting errors
* move back js-yaml version to 3 major
* start adding global search filter
* update polyfill setup to use async await for react-table
* update browerslist to sensible defaults
* get global search functionality woring
* more progress on the data table
* get label network calls working in hostdatatable
* get pagination functionality into the HostDataTable
* get search query making network call
* get ordering making query
* make actual sort order network calls
* disable cpu column sorting
* seperate get table data from get labels
* fix issues with input resetting and got search query working
* get sort working
* ignore vs code editor settings
* improve loading spinner to move inside the table
* improve styling
* add sorting arrows
* remove unused sorting arrow component
* add host query params to labels endpoint
* fix style for query textarea on label hosts
* got new pagination working
* set server data as source of truth for table global filter
* cleanup logs
* clean up pagination styles
* fix up paginationa and no host styles
* add result count to table
* remove logs
* tweak header styles
* fix to sort order
* simplify default sort direction
* keep sort order of server api responses and use in host table
* clean up logs
* Add styles for header cell and pagination
* fix tests for ManageHostPage
* fix tests for HostContainer
* fix lower level action reducer and thunk tests
* fix tests for hosts client
* fix up some host count styling
* added back no hosts start message
* fix linting errors
* remove unused old pagination code
* add back scrollToTop utility on pagination
* remove unused code in managehostpage test
Co-authored-by: Noah Talerman <noahtal@umich.edu>
* recreate host table with react-table
* move old host table and container next to other code related to host page
* start replacing old host table with new host table
* replace old table with with new data table
* fix up tests and remove some unused code
* update react-redux to 7.7.2
* update redux to 4.05
* update react to 17.0.1
* Revert "update react to 17.0.1"
This reverts commit 004f3bb5a9e26bfcea9e921a2093adcc1e95068f.
This PR adds a new Host details page as part of the Hosts UI project #162
Summary of changes:
- New component <HostDetailsPage />
- Move "Query" and "Delete" buttons from the hosts list to the Host details page
- Add new button variants label and text-link
- Add react-tooltip package to the project (v4.2.13)
Resolves a GitHub security alert about node-notifier (https://github.com/advisories/GHSA-5fw9-fq32-wv5p). This was unlikely
to be relevant in the case of Fleet where this was used only as a
development dependency.
- Move from Mocha to Jest for JS testing (Jest seems to have better support for
'watching' tests and a more active community these days).
- Codemod existing tests to Jest syntax (using https://github.com/skovhus/jest-codemods)
- Fix some errors in tests that were previously hidden.
- Update Babel.
- Output easy to parse stack traces during run of tests
- Fix some spurious warnings and errors in tests
- Add --exit flag to Mocha invocation to fix hang due to timers in ACE editor
Created 3 new components: <OsqueryOptionsPage /> , <OsqueryOptionsForm />, and <YamlAce />
The <OsqueryOptionsPage /> component is rendered at the new route /admin/osquery. The user navigates to this route by selecting the "Osquery Options" sub-navigation in the admin dropdown menu.
On the Osquery Options page, the user is presented with a ACE editor filled with the current osquery options. The current osquery options are retrieved from the serve when the page component mounts. These current osquery options are stored in the osquery slice of state.
Clicking "UPDATE OPTIONS" will trigger a form submit and hit the v1/kolide/spec/osquery_options endpoint if the yaml is valid. If the yaml is not valid, an error message is presented to the user with details on what the error is and where it occurred. If the yaml is valid, the osquery options will be updated even if the options haven't change.
There was a prototype pollution vulnerability in 4.17.11 that is
unlikely to have high impact on Fleet due to all JS executing on the
client side. Upgrading lodash to satisfy security warnings from
Github.
- Replace uses of deprecated Bourbon helpers with raw CSS
- Add autoprefixer into the build chain to prefix the now removed helpers
This process was achieved by running through each of the deprecation warnings and using the following bash function to replace it in all files:
```
function bourbon-deprecate() {
grep -rl "@include $1" ./frontend --exclude-dir=.git | xargs sed -i '' -E "s/@include $1[(](.*)[)]/$1: \1/g"
}
```
For some helpers, this did not result in valid CSS, so manual modifications were made.
Closes#1189#1274
Use the [SockJS Protocol](https://github.com/sockjs/sockjs-protocol) to handle
bidirectional communication instead of plain websockets. This allows
distributed queries to function in situations in which they previously failed
(Load balancers not supporting websockets, issues with Safari and self-signed
certs, etc.).
Also includes fixes to the JS message handling logic where slightly different
message delivery semantics (when using XHR) were exposing bugs.
Fixes#1241, #1327.