Home

Awesome

<img src="assets/logo.png" align="left" width="144px"/>

Hajimari πŸŒ…

...The beginning of a pleasant experience

<br />

Discord Go GitHub Workflow Status


Hajiwhatsi?

Hajimari is a simplistically beautiful startpage designed to be the entrypoint for your self-hosted Kubernetes cluster.

Hajimari

User config

App groups

Features

Installation

Helm

helm repo add hajimari https://hajimari.io

helm repo update

helm install hajimari hajimari/hajimari

Helm docs

Locally

Clone the repo and run the following command to generate the hajimari binary:

make deps
make build

Or for local development with hot reload:

make deps
make dev

You will need to have go 1.19 and node 18 installed.

Hajimari will need access to a kubeconfig file for a service account with access to ingress and endpoint slice objects.

Usage

Ingresses

Hajimari looks for specific annotations on Ingresses.

AnnotationDescriptionRequired
hajimari.io/enableAdd this with value true to the ingress of the app you want to show in Hajimaritrue
hajimari.io/iconIcon name from MDI iconsfalse
hajimari.io/appNameA custom name for your application. Use if you don't want to use the name of the ingressfalse
hajimari.io/groupA custom group name. Use if you want the application to show in a different group than the namespace it is running infalse
hajimari.io/instanceA comma separated list of name/s of the Hajimari instance/s where you want this application to appear. Use when you have multiple Hajimari instancesfalse
hajimari.io/urlA URL for the Hajimari app (This will override the ingress URL). It MUST begin with a scheme i.e., http:// or https://false
hajimari.io/targetBlankDetermines if links should open in new tabs/windowsfalse
hajimari.io/infoA short description of the Hajimari appfalse

Config

Hajimari supports the following configuration options that can be modified by either ConfigMap or values.yaml if you are using Helm

FieldDescriptionDefaultType
instanceNameName of the Hajimari instance""string
defaultEnableSet to true to expose all ingresses in selected namespaces by defaultfalsebool
namespaceSelectorNamespace selector which uses a combination of hardcoded namespaces as well as label selectorsany: trueNamespaceSelector
nameName to use in the greeting"You"string
titleBrowser title for this Hajimari instance"Hajimari"string
lightThemeTheme to use when the browser prefers light themes"gazette"string
darkThemeTheme to use when the brwoser prefers dark themes"horizon"string
customThemesA list of custom themes[][]Theme
showGreetingToggle showing the greeting and datetruebool
showAppGroupsToggle grouping apps by group (namespaces)truebool
showAppUrlsToggle displaying app URLstruebool
showAppInfoToggle showing app infofalsebool
showAppStatusToggle showing app replica status indicatorstruebool
showBookmarkGroupsToggle grouping bookmarks by grouptruebool
showGlobalBookmarksToggle showing global bookmarks on custom startpagesfalsebool
alwaysTargetBlankSet to true to open apps/bookmarks in a new window by defaultfalsebool
defaultSearchProvidername of the configured search provider to use as default"Google"string
searchProvidersA list of custom search providers[...][]SearchProvider
customAppsA list of custom apps to add to the discovered apps[][]AppGroup
globalBookmarksA list of bookmark groups to add[][]BookmarkGroup

HajimariApp objects

It also possible to define Apps via Kubernetes Custom Resources for those using Istio's Virtual Services, Traefik's IngressRoutes or other solutions, which does not reply on native Ingress objects:

apiVersion: hajimari.io/v1alpha1
kind: Application
metadata:
  name: hajimari-issues
spec:
  name: Hajimari Issues
  group: info
  icon: simple-icons:github
  url: https://github.com/toboshii/hajimari/issues
  info: Submit issue to this project
  targetBlank: true

NamespaceSelector

It is a selector for selecting namespaces either selecting all namespaces or a list of namespaces, or filtering namespaces through labels.

FieldDescriptionDefaultType
anyBoolean describing whether all namespaces are selected in contrast to a list restricting themfalsebool
labelSelectorFilter namespaces based on kubernetes metav1.LabelSelector typenullmetav1.LabelSelector
matchNamesList of namespace namesnull[]string

Note: If you specify both labelSelector and matchNames, Hajimari will take a union of all namespaces matched and use them.

Theme

If you want to add custom themes you can provide a list of custom theme atrributes.

FieldDescriptionType
nameName of the themeString
backgroundColorBackground color hex valueString
primaryColorPrimary color hex valueString
accentColorAccent color hex valueString

SearchProvider

If you want to add custom search providers you can provide a list of custom providers to override the defaults.

FieldDescriptionType
nameName of the search providerString
tokenShort token used to activate this provider in the search barString
iconIcon name or URL to use for this search providerString
searchUrlURL to use for searches, the token {query} will be replaced with the queryString
urlURL to use when only token is entered in search barString
Default Search Providers

searchProviders defaults to the following values:

searchProviders:
  - name: Google
    token: g
    icon: simple-icons:google
    searchUrl: https://www.google.com/search?q={query}
    url: https://www.google.com
  - name: DuckDuckGo
    token: d
    icon: simple-icons:duckduckgo
    searchUrl: https://duckduckgo.com/?q={query}
    url: https://duckduckgo.com
  - name: IMDB
    token: i
    icon: simple-icons:imdb
    searchUrl: https://www.imdb.com/find?q={query}
    url: https://www.imdb.com
  - name: Reddit
    token: r
    icon: simple-icons:reddit
    searchUrl: https://www.reddit.com/search?q={query}
    url: https://www.reddit.com
  - name: YouTube
    token: 'y'
    icon: simple-icons:youtube
    searchUrl: https://www.youtube.com/results?search_query={query}
    url: https://www.youtube.com
  - name: Spotify
    token: s
    icon: simple-icons:spotify
    searchUrl: hhttps://open.spotify.com/search/{query}
    url: https://open.spotify.com

AppGroup

If you want to add any apps that are not exposed through ingresses or are external to the cluster, you can use the custom apps feature. You can pass a list of custom apps inside the config.

FieldDescriptionType
groupName of the group (namespace)String
appsA list of custom apps[]App
App

Custom apps can be added by configuring a list of apps under an app group.

FieldDescriptionType
nameName of the custom appString
iconIcon name or URL for the custom appString
urlURL of the custom appString
infoShort description of the custom appString
targetBlankOpen app in a new window/tabBool

BookmarkGroup

Bookmark groups can be added by creating a list of groups and associated bookmarks.

FieldDescriptionType
groupName of the bookmark groupString
bookmarksArray of bookmarks[]Bookmark

Bookmarks can be added by configuring a list of bookmarks under a group.

Bookmark
FieldDescriptionType
nameName of the bookmarkString
iconIcon name or URL for the bookmarkString
urlURL of the bookmarkString
targetBlankOpen bookmark in a new window/tabBool

Search

The search bar has a few functionalities:

Icons

Any icon field can be either an Iconify supported icon (ex: mdi:kubernetes, simple-icons:google) or a URL to an image.

Custom startpage setup

  1. Open Hajimari in your browser, click the hamburger menu in the lower lefthand corner.
  2. Modify the options you wish to change in the built-in YAML editor.
  3. Click Save and you'll be redirected to your new custom page with a random ID on the URL. Set this page as your homepage/new tab page. For the best experience in Firefox I recommend the New Tab Override extension; for Chrome Custom New Tab URL.
  4. You can make further modifications to this page at anytime under the hamburger menu.

Please note there is no authentication. You might want to run this behind ingress with access restrictions.

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

Run make help for information on linting, tests, etc.

About

Why Hajimari?

Hajimari (ε§‹γΎγ‚Š) is Japanese for beginnings. Hajimari's original intended purpose is to be used as a browser startpage, so the name seemed fitting as it's the beginning of all new tabs/windows :)

Thank you / dependencies

License

Apache-2.0