• Stars
    star
    1,297
  • Rank 36,273 (Top 0.8 %)
  • Language
    JavaScript
  • License
    MIT License
  • Created over 7 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

πŸ“Ί Create your own team dashboard with custom widgets. Built with Next.js, React, styled-components and polished.

Dashboard

Dashboard

Create your own team dashboard with custom widgets.

Actions Status JavaScript Style Guide Dependabot Status Deploy to now

Table of Contents

Installation

  1. Download or clone the repository.
  2. Install the dependencies with npm install.

Server

Development

Run npm run dev and go to http://localhost:3000.

Production

Build your dashboard for production with npm run build and then start the server with npm start.

Docker

  1. Build your dashboard for production with npm run build
  2. Build the image with docker build -t dashboard .
  3. Start the container with docker run -d -p 8080:3000 dashboard
  4. Go to http://localhost:8080

Create a Dashboard

You can create multiple dashboards. For example populate pages/team-unicorn.js inside your project:

import Dashboard from '../components/dashboard'
import DateTime from '../components/widgets/datetime'
import lightTheme from '../styles/light-theme'

export default () => (
  <Dashboard theme={lightTheme} name='Unicorn Dashboard'>
    <DateTime />
  </Dashboard>
)

This dashboard is available at http://localhost:3000/team-unicorn.

For an example, see pages/index.js.

Available Widgets

DateTime

Example

import DateTime from '../components/widgets/datetime'

<DateTime interval={10000} />

props

  • interval: Refresh interval in milliseconds (Default: 10000)

Jenkins Job Status

Example

import JenkinsJobStatus from '../components/widgets/jenkins/job-status'

<JenkinsJobStatus
  url='https://builds.apache.org'
  jobs={[
    { label: 'JMeter', path: 'JMeter-trunk' },
    { label: 'Log4j Kotlin', path: 'Log4jKotlin', branch: 'master' }
  ]}
/>

For Jenkins multibranch projects add branch to the object.

props

  • title: Widget title (Default: Job Status)
  • interval: Refresh interval in milliseconds (Default: 300000)
  • url: Jenkins URL
  • jobs: List of all jobs
  • authKey: Credential key, defined in auth.js

Jenkins Job Health

Example

import JenkinsJobHealth from '../components/widgets/jenkins/job-health'

<JenkinsJobHealth
  url='https://builds.apache.org'
  jobs={[
    { label: 'JMeter', path: 'JMeter-trunk' },
    { label: 'Log4j Kotlin', path: 'Log4jKotlin', branch: 'master' }
  ]}
/>

For Jenkins multibranch projects add branch to the object.

props

  • title: Widget title (Default: Job Health)
  • interval: Refresh interval in milliseconds (Default: 300000)
  • url: Jenkins URL
  • jobs: List of all jobs
  • authKey: Credential key, defined in auth.js

Jenkins Build Duration

Example

import JenkinsBuildDuration from '../components/widgets/jenkins/build-duration'

<JenkinsBuildDuration
  url='https://builds.apache.org'
  jobs={[
    { label: 'JMeter', path: 'JMeter-trunk' },
    { label: 'Log4j Kotlin', path: 'Log4jKotlin', branch: 'master' }
  ]}
/>

For Jenkins multibranch projects add branch to the object.

props

  • title: Widget title (Default: Build Duration)
  • interval: Refresh interval in milliseconds (Default: 300000)
  • url: Jenkins URL
  • jobs: List of all jobs
  • authKey: Credential key, defined in auth.js

JIRA Issue Count

Example

import JiraIssueCount from '../components/widgets/jira/issue-count'

<JiraIssueCount
  title='JIRA Open Bugs'
  url='https://jira.atlassian.com'
  query='type=Bug AND project="Bitbucket Server" AND resolution=Unresolved ORDER BY priority DESC,created DESC'
/>

For Jenkins multibranch projects add branch to the object.

props

  • title: Widget title (Default: JIRA Issue Count)
  • interval: Refresh interval in milliseconds (Default: 300000)
  • url: JIRA Server URL
  • query: JIRA search query (jql)
  • authKey: Credential key, defined in auth.js

JIRA Sprint Days Remaining

Example

import JiraSprintDaysRemaining from '../components/widgets/jira/sprint-days-remaining'

<JiraSprintDaysRemaining
  title='Sprint Days'
  url='https://jira.atlassian.com'
  boardId={42}
/>

props

  • title: Widget title (Default: JIRA Sprint Days Remaining)
  • interval: Refresh interval in milliseconds (Default: 3600000)
  • url: JIRA Server URL
  • boardId: JIRA board id
  • authKey: Credential key, defined in auth.js

Bitbucket PullRequest Count

Example

import BitbucketPullRequestCount from '../components/widgets/bitbucket/pull-request-count'

<BitbucketPullRequestCount
  title='Bitbucket Open PR'
  url='https://bitbucket.typo3.com'
  project='EXT'
  repository='blog'
  users={['stekal', 'marleg', 'denhub']}
/>

props

  • title: Widget title (Default: Bitbucket PR Count)
  • interval: Refresh interval in milliseconds (Default: 300000)
  • url: Bitbucket Server URL
  • project: Bitbucket project key
  • repository: Bitbucket repository slug
  • users: Bitbucket user slugs as an array
  • authKey: Credential key, defined in auth.js

PageSpeed Insights Score

Example

import PageSpeedInsightsScore from '../components/widgets/pagespeed-insights/score'

<PageSpeedInsightsScore url='https://github.com' />

props

  • title: Widget title (Default: PageSpeed Score)
  • interval: Refresh interval in milliseconds (Default: 43200000)
  • url: URL to fetch and analyze
  • strategy: Analysis strategy (Default: desktop)
    • Acceptable values: desktop | mobile
  • filterThirdPartyResources: Indicates if third party resources should be filtered out (Default: false)

PageSpeed Insights Stats

Example

import PageSpeedInsightsStats from '../components/widgets/pagespeed-insights/stats'

<PageSpeedInsightsStats url='https://github.com' />

props

  • title: Widget title (Default: PageSpeed Stats)
  • interval: Refresh interval in milliseconds (Default: 43200000)
  • url: URL to fetch and analyze
  • strategy: Analysis strategy (Default: desktop)
    • Acceptable values: desktop | mobile
  • filterThirdPartyResources: Indicates if third party resources should be filtered out (Default: false)

SonarQube

Example

import SonarQube from '../components/widgets/sonarqube'

<SonarQube
  url='https://sonarcloud.io'
  componentKey='com.icegreen:greenmail-parent'
/>

props

  • title: Widget title (Default: SonarQube)
  • interval: Refresh interval in milliseconds (Default: 300000)
  • url: SonarQube URL
  • componentKey: SonarQube project key
  • authKey: Credential key, defined in auth.js

Elasticsearch Hit Count

Example

import ElasticsearchHitCount from '../components/widgets/elasticsearch/hit-count'

<ElasticsearchHitCount
  title='Log Hits'
  url='http://ec2-34-210-144-223.us-west-2.compute.amazonaws.com:9200'
  index='blog'
  query='user:dilbert'
/>

props

  • title: Widget title (Default: Elasticsearch Hit Count)
  • interval: Refresh interval in milliseconds (Default: 300000)
  • url: Elasticsearch URL
  • index: Elasticsearch index to search in
  • query: Elasticsearch query
  • authKey: Credential key, defined in auth.js

GitHub Issue Count

Example

import GitHubIssueCount from '../components/widgets/github/issue-count'

<GitHubIssueCount
  owner='danielbayerlein'
  repository='dashboard'
/>

props

  • title: Widget title (Default: GitHub Issue Count)
  • interval: Refresh interval in milliseconds (Default: 300000)
  • owner: Owner of the repository
  • repository: Name of the repository
  • authKey: Credential key, defined in auth.js

Title

Example

import Title from '../components/widgets/title'

<Title>API Status</Title>

Available Themes

light

Example

import lightTheme from '../styles/light-theme'

<Dashboard theme={lightTheme}>
  ...
</Dashboard>

Preview

dashboard-light

dark

Example

import darkTheme from '../styles/dark-theme'

<Dashboard theme={darkTheme}>
  ...
</Dashboard>

Preview

dashboard-dark

Authentication

Any widget can authenticate itself, should your server expect this. We use basic authentication.

  1. Define your credential key in auth.js. For example:
    jira: {
      username: process.env.JIRA_USER,
      password: process.env.JIRA_PASS
    }
  2. Give the defined credential key jira via prop authKey to the widget. For example:
    <JiraIssueCount
      authKey='jira'
      url='https://jira.atlassian.com'
      query='type=Bug AND project="Bitbucket Server" AND resolution=Unresolved ORDER BY priority DESC,created DESC'
    />
  3. Create a .env file or rename .env.example to .env in the root directory of your project. Add environment-specific variables on new lines in the form of NAME=VALUE. For example:
    JIRA_USER=root
    JIRA_PASS=s1mpl3

Cross-Origin Resource Sharing (CORS)

Cross-Origin Resource Sharing (CORS) is a W3C spec that allows cross-domain communication from the browser. By building on top of the XMLHttpRequest object, CORS allows developers to work with the same idioms as same-domain requests.

Proxy

You can use a proxy (e.g. hapi-rest-proxy) to enable CORS request for any website.

Server

docker pull chrishelgert/hapi-rest-proxy
docker run -d -p 3001:8080 chrishelgert/hapi-rest-proxy

Dashboard

<SonarQube
  url='http://127.0.0.1:3001/?url=https://sonarcloud.io'
  componentKey='com.icegreen:greenmail-parent'
/>

Resources

License

Copyright (c) 2017-present Daniel Bayerlein. See LICENSE for details.

More Repositories

1

remote-jobs-germany

πŸ‘¨β€πŸ’» A list of semi to fully remote-friendly πŸ‡©πŸ‡ͺ companies in or around tech
308
star
2

middleman-casper

πŸ‘» Casper theme (Ghost) for Middleman-Blog
Ruby
134
star
3

middleman-google-analytics

πŸ“ˆ A @middleman plugin to handle generating your Google Analytics tracking code.
Gherkin
92
star
4

dotfiles

βš™οΈ Configuration files for Git, Hyper, Ruby, tmux, Vim, VS Code and Zsh
JavaScript
21
star
5

alfred-workflows

Make your Alfred App more powerful. Workflow for Homebrew, RubyGems and macOS
11
star
6

middleman-impress

A @middleman project template built with impress.js, Haml, Sass and CoffeeScript.
HTML
11
star
7

vallox-api

πŸ“š API for Vallox ventilation units
JavaScript
10
star
8

middleman-pattern-library

πŸ’… A @middleman project template for creating and managing your front-end pattern library / style guide.
CSS
10
star
9

honeycomb

🐝 Honeycomb is a common basis for @nodejs microservices
JavaScript
10
star
10

zazu-simple-theme

A simple theme for Zazu
CSS
8
star
11

tidesdk-template

A base TideSDK application template with Ruby, Haml, Sass, CoffeeScript and RubyGems.
Ruby
8
star
12

zazu-github

Zazu plugin to search for @GitHub repositories with github.com
JavaScript
8
star
13

sepicker

πŸ“Š Monitoring for the STIEBEL ELTRON Heat Pump
Python
7
star
14

speedly

A CLI tool to test your page speed performance.
Ruby
7
star
15

caniuse-yarn

❓ Can I use Yarn? caniuse-yarn checks if Yarn (@yarnpkg) is available.
JavaScript
5
star
16

zazu-npms

Zazu plugin to search for @npm packages with npms.io
JavaScript
5
star
17

hapi-webpack-middleware

@webpack middleware for @hapijs
JavaScript
4
star
18

language-galen

Galen Framework language package for Atom
CoffeeScript
4
star
19

zazu-homebrew

Zazu plugin to search for @Homebrew formulae with braumeister.org
JavaScript
3
star
20

zazu-devdocs

Zazu plugin to search for API documentations with devdocs.io
JavaScript
3
star
21

git-pick

πŸ’ git cherry-pick <commit> to multiple branches
JavaScript
3
star
22

homebridge-vallox

[WIP] πŸ’¨ Vallox plugin for Homebridge
2
star
23

aws-setup

☁️ Setup for AWS (Amazon Web Services)
TypeScript
2
star
24

zazu-battery

πŸ”‹ Zazu plugin to show information about your battery
JavaScript
1
star
25

sinatra-template

A base Sinatra application template with Haml, Sass, CoffeeScript and Sinatra AssetPack.
Ruby
1
star
26

zsh-plugins

πŸ”Œ Plugins for Zsh
Shell
1
star
27

dasheets-collection

Cheatsheet collection for Dasheets
1
star
28

zazu-rubygems

Zazu plugin to search for gems with rubygems.org
JavaScript
1
star
29

wintersmith-pattern-library

πŸ’… A wintersmith project template for creating and managing your front-end pattern library / style guide.
JavaScript
1
star
30

zazu-uptime

Zazu plugin to show the system uptime
JavaScript
1
star