Coder Social home page Coder Social logo

redhat-cip / dci-ui Goto Github PK

View Code? Open in Web Editor NEW
9.0 11.0 7.0 15.51 MB

Home Page: https://www.distributed-ci.io/

License: Other

JavaScript 1.31% HTML 0.06% Dockerfile 0.04% CSS 0.04% TypeScript 98.54%
dci-ui webpack es6 redux scss patternfly react normalizr

dci-ui's Introduction

dci-ui

Source code for dci user interface. https://distributed-ci.io dci-ui is a static web app pluggable through CORS on a DCI server.

Getting started

To run the app in development mode follow those steps:

  • clone this repository
  • ensure DCI api is listening on localhost:5000. See dci-dev-env.
  • install node dependencies: npm install
  • run the development server : REACT_APP_BACKEND_HOST='http://127.0.0.1:5000' npm start

If you want to test the SSO autentification :

  • ensure Keycloak is listening on localhost:8180. See dci-dev-env.
  • run the development server with SSO env variables : REACT_APP_SSO_URL='http://localhost:8180' REACT_APP_BACKEND_HOST='http://127.0.0.1:5000' npm start

Build tools

To manage the workflow the project use npm scripts

List of commands:

  • npm start: start web server with live reload
  • npm run build: build application in build/ folder
  • npm run test: start unit test

dci-ui's People

Contributors

asergienk avatar dsavineau avatar fredericlepied avatar goneri avatar guillaumevincent avatar hguemar avatar ixday avatar leifmadsen avatar prophidys avatar rh-gvincent avatar sf-project-io avatar spredzy avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

dci-ui's Issues

Improve job tab navigation

Add url support of tabs in the job view, this will help sharing views and developing on a specific tab.

Something like:

http://localhost:8000/#/jobs/968fcfab-fe51-4dce-a206-1b4a961e16b3
http://localhost:8000/#/jobs/968fcfab-fe51-4dce-a206-1b4a961e16b3/details
http://localhost:8000/#/jobs/968fcfab-fe51-4dce-a206-1b4a961e16b3/edit
http://localhost:8000/#/jobs/968fcfab-fe51-4dce-a206-1b4a961e16b3/context

Error are not correctly displayed

In the administrate panel the error message is always "team already exists" even if the error is not related. Provides a default error message explaining that something bad happened

Update Adminitrator User Panel

The following ticket is a bucket of few ideas to improve the User Experience in the UI:

  • (as a super_admin): In the Administrator/Users page, instead of Team ID display Team Name
  • (as a super_admin): In the Administrator/Users page, allow to filter by Team. Currently every user of every team are displayed, it is starting to become cumbersome
  • (as an admin): In the Administator/Users page, do not have a column Team ID, as I can only list the members of my team

I get silently disconnect if I try to add subscribe to a remoteci

I'm in the OpenStack team, switch is one level below the goneri team. I want to subscribe to my remoteci. So I go on https://www.distributed-ci.io/notification and click on the ⊞ signe.

The following URL is called:
https://api.distributed-ci.io/api/v1/remotecis/af991b96-bfe0-4e00-bd87-5c98893c3238/users
The payload sent by the browser:

{"user_id":"51bd34bf-5767-48c2-aeae-b49212480533"}

answer:

{
  "message": "Operation not authorized.",
  "payload": {},
  "status_code": 401
}

If I retry to do the same, I get a different result:

{
  "message": "Authorization header malformed",
  "payload": {},
  "status_code": 401
}

I actually disconnected. I reload the browser and get redirected to auth page.

GlobalStatus incorrect Tuile

The big block on the top of the GlobalStatus page does not reflect all the topics covered by the global status.

Taking the OpenStack example:

  • Blocks shows: OSP 8 - OSP 9 - OSP10 - OSP11
  • Available topics reported: OSP {8,9,10,11,12} and RDO {Pike, Ocata}

Take the Ansible example:

  • Block shows: Ansible-devel-coverage, Ansible-2.4
  • Available topics reported: Ansible-{2.3, 2.4, devel, devel-coverage}

it's too easy to permanently delete a job

A job can be deleted just by clicking on the little checkbox. There is no confirmation box and it's ready to lose some information.

Could we use a 'deleted' status instead to hide those jobs instead of just pruning them out of the DB? This way we will be able to recover them later.

Handle responsive

All the layout breaks on small resolution, mobile support is not needed :p but a better display will bring more comfort

jobs: issues tab doesn't load the content

Under /jobs/uuid/issues we should have the issue list linked to associated job.
But even if the API returns the correct value, the UI is blocked the 'Loading' progress bar forever.

bogus job duration

I still have a TZ issue. I attached a screenshot. The first one is ok, the job has been
started 2 minutes ago.
bogus_job_duration

Add a messages service

In order to visualize errors and notifications a messages services must be implemented.
Currently, errors are handled directly in the controller and displayed in the template, which can cause some UI issues. The idea here is to provide a central service for displaying messages in the UI.

rpm install erase %config(noreplace) file

During the installation of the RPM file, it seems that the config.js file is replaced even if the file is marked as %config(noreplace)

see https://github.com/redhat-cip/dci-ui/blob/master/dci-ui.spec#L40

@dsavineau think about a problem between the symbolic link, the cp and the noreplace:

%install
install -d -m0755 %{buildroot}/srv/www/dci-ui
install -d -m0755 %{buildroot}/etc/dci-ui
cp -r static/* %{buildroot}/srv/www/dci-ui
ln -sf /srv/www/dci-ui/config.js %{buildroot}/etc/dci-ui/config.js

%files
/srv/www/dci-ui/*
%config(noreplace) /etc/dci-ui/config.js

The problem is during the deployment of dci-ui, config.js file is not valid between yum update and the ansible config.js configuration

- name: Configure dci-ui config.js
  template:
    src: config.js.j2
    dest: /etc/dci-ui/config.js
  notify:
    - reload httpd
  tags:
- dci-core

remotecis from teams on a 2nd level of deph are hidden

I'm PO in the OpenStack team, I can see the remotecis in the new "Remotecis" menu on the right. They are all here with the exception of the Pure one. What makes this remoteci special is that Pure is itself a sub-team of RAX.

Topic's component_types cannot be specified on create or update

As a Product Owner I'd like to create a new topic. One mandatory field for it to work is to specify component_types to know which component type would be associated with this topic, else any schedule will fail.

Currently there is no way to specify this value neither at creation time or update time.

Handle 404 not found

The UI does not handle 404 errors when the user ask for a non existing resource in the API.
The idea here is to implement a redirection and display an error.

Impossible to update a remoteci

I just tried to update the JSON field of a remoteci and I got this error:

allow_upgrade_job "expected bool". The UI set allow_upgrade_job to null, it should be false instead.

'{"name":"FutureVille2","state":"active","allow_upgrade_job":null,"data":{"tempest_extra_keys":[{"section":"volume","option":"vendor_name","value":"Dell"},{"section":"volume-feature-enabled","option":"volume_services","value":true},{"section":"auth","option":"use_dynamic_credentials","value":true},{"section":"volume-feature-enabled","option":"api_v1","value":true}]}}'

As an alternative, we can also patch the control-server so it will accept null as false.

Jobs>Files should be a patternfly list

Most list in the UI has been migrated to the patternfly list.

The one in Jobs>Files is still the old way. In order to keep same UX across all the interface, this list should also be moved to the patternfly list.

Older jobs not available

older results are not available anymore ? not great when working with multiple environments we're very limited , for eg. with x4 environments(agents) i can't see past 3 days old results.

Display components name in main tuile

As a user, I'd like to be able to see the name of the components used for a specific job in the main tuile.

So If my job has been run with 2 specific components:

  • OpenStack X.Y and Ceph A.B
  • Ansible X.Y and Openvswitch A.B

Be able to see this information in the main tuile.

Job/Edit/job Submit is broken

The Submit is ignored.

Array [ Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, 57 more… ] app.js:54510:5
Job "f11b69c1-09c2-448b-b55b-9f139c7a14cd" deleted ! app.js:20673:18
Job "0a2905e5-b17c-4c37-9d6a-9cf7613497cc" deleted ! app.js:20673:18
Something went bad: Job app.js:20673:18

Error: status[s] is undefined
require<[14]</</<.link/job.processStatus@http://46.231.133.47/js/app.js:54559:9
require<[14]</</<.link@http://46.231.133.47/js/app.js:54563:7
invokeLinkFn@http://46.231.133.47/js/app.js:17248:9
nodeLinkFn@http://46.231.133.47/js/app.js:16758:11
delayedNodeLinkFn@http://46.231.133.47/js/app.js:17006:11
compositeLinkFn@http://46.231.133.47/js/app.js:16107:13
publicLinkFn@http://46.231.133.47/js/app.js:15986:30
createBoundTranscludeFn/boundTranscludeFn@http://46.231.133.47/js/app.js:16125:16
controllersBoundTransclude@http://46.231.133.47/js/app.js:16785:18
ngRepeatAction@http://46.231.133.47/js/app.js:33789:15
$watchCollectionAction@http://46.231.133.47/js/app.js:23246:13
$RootScopeProvider/this.$get</Scope.prototype.$digest@http://46.231.133.47/js/app.js:23379:23
$RootScopeProvider/this.$get</Scope.prototype.$apply@http://46.231.133.47/js/app.js:23642:13
done@http://46.231.133.47/js/app.js:18692:36
completeRequest@http://46.231.133.47/js/app.js:18882:7
requestLoaded@http://46.231.133.47/js/app.js:18823:9
 <div class="ng-scope" ng-repeat="job in jobs" dci-job=""> app.js:20673:18

Error: assignment to undeclared variable conf
require<[9]</</api.updateJob@http://46.231.133.47/js/app.js:53805:25
require<[13]</</$scope.submit@http://46.231.133.47/js/app.js:54485:9
$parseFunctionCall@http://46.231.133.47/js/app.js:21441:15
ngEventHandler/</callback@http://46.231.133.47/js/app.js:30667:17
$RootScopeProvider/this.$get</Scope.prototype.$eval@http://46.231.133.47/js/app.js:23537:16
$RootScopeProvider/this.$get</Scope.prototype.$apply@http://46.231.133.47/js/app.js:23636:18
ngEventHandler/<@http://46.231.133.47/js/app.js:30672:17
createEventHandler/eventHandler@http://46.231.133.47/js/app.js:12014:9

Ability to delete jobs

We've lost the ability to delete jobs ,would be nice to have this back to clean up results.

search is slow

If I search the 'ironic' pattern, the result takes about 1 minute. Once the page is finally displayed, I've again to wait =~ 1 minute, to get the it fully operational (A lot of background requests are still ongoing)

Order test by name

It is easier to compare test results if they are still in the same order. The tests should be classified in each box by name.

Example: Rally and Tempest test should be in the same order

jobs page:

screen shot 2017-06-02 at 09 20 41

screen shot 2017-06-02 at 09 20 46

job results page:

screen shot 2017-06-02 at 09 21 38

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.