Code Monkey home page Code Monkey logo

rancher-desktop's Issues

Package as a Mac app

Setup the toolchain so this application can be built into a Mac App. This does not yet need to be a signed app.

Stratos UI

Stratos, the Cloud Foundry UI that can also do Kubernetes and Helm, is a UI we've invested heavily in and that can be built as an electron app. We should look at how to incorporate it into RD. This includes:

  • Should we incorporate it with reasons?
  • How do we pull it in and make it part of RD?
  • Exposing through the menu next to Dashboard
  • What elements should be available? Should CF be displayed by default? Is this configurable?

Expose kubectl and helm

Through the preference UI, provide checkboxes to symlink kubectl and helm to /usr/local/bin on mac.

The goal of this is to provide the users with access to these tools. Eventually we will have other applications to expose here.

Move from Homestead to Rancher

We currently install a homestead chart for minimal rancher. This is an in-development project that doesn't appear to be reaching production readiness in the near future. We need to move to using rancher itself instead.

We can start by replacing the the homestead chart tgz file with one from rancher and renaming the release-name to rancher.

Also, the UI calls it minimal rancher and that will need to be changed.

Toggle developer tools in preferences

The developer tools are currently on in preferences by default. This should be a toggle and off by default. It could be a keyboard shortcut or an environment variable. Or, something else.

Use sliders for some numeric widgets

minikube memory-to-allocate: slider should go from the minimum value (TBD) to the max available on the user's sytem

minikube num-cpus-to-allocate: same thing

  • see virtualbox, docker desktop, or other vm management systems to see how they're done.

Depends on issues #47 and #48

Localization

Currently all messages in the app are English-only. We may want to some day support additional languages.

(Filing this for scheduling & note taking purposes, but not expecting to get around to it any time soon.)

Factory Reset Button

This is for two use cases:

  • As a developer I want to test the fresh install setup. It would be nice to have an easy button for this.
  • As a user, I've encountered some problem where my environment is borked. Being about to factory reset could be an option to fix it.

This button would delete the directories created in the library and force RD to restart (is this possible)?

Expose Rancher Dashboard via Menu

Just like the preferences are able to be open via the menu, The Rancher Dashboard (new Vue UI) should be able to be exposed for the local cluster. This depends on #7.

Push button expose a service locally

When someone deploys a workload they will often want to access using a port forward. Today you need to know the right kubectl commands to make that happen.

We want to provide a UI that lists workloads and provides a button to create a port forward.

There are numerous details that still need to be worked out such as, is the list just for services or does it include pods?

Provide setting for amount of RAM to use

The default value provided by minikube is a fine default.

The UI for this should be in the Kubernetes preferences. It can be below the existing Kubernetes preferences and before the CLI linking section.

There should be validation on the values here. If a value passed in will cause a problem for minikube we should catch it, inform the user, and not save the setting.

Exception when no kubeconfig can be found

On a new machine, running npm run dev, I get this error message in the console:

(node:15202) UnhandledPromiseRejectionWarning: Error: ENOENT: no such file or directory, watch
    at FSWatcher.start (internal/fs/watchers.js:169:26)
    at Object.watch (fs.js:1343:11)
    at new Tray (/Users/ericp/workspace/rancher/desktop/app/background.js:3916:8)
    at _callee2$ (/Users/ericp/workspace/rancher/desktop/app/background.js:34665:18)
    at tryCatch (/Users/ericp/workspace/rancher/desktop/app/background.js:32119:40)
    at Generator.invoke [as _invoke] (/Users/ericp/workspace/rancher/desktop/app/background.js:32349:22)
    at Generator.next (/Users/ericp/workspace/rancher/desktop/app/background.js:32174:21)
    at asyncGeneratorStep (/Users/ericp/workspace/rancher/desktop/app/background.js:64:24)
    at _next (/Users/ericp/workspace/rancher/desktop/app/background.js:86:9)
    at /Users/ericp/workspace/rancher/desktop/app/background.js:93:7
(node:15202) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2)
(node:15202) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

Unknown bootstrapper - another new machine issue

When starting up on a new machine:

  1. Without running npm run setupmac:
X Exiting due to MK_BOOTSTRAPPER: unknown bootstrapper: k3s
  1. After having run npm run setupmac:
X Exiting due to MK_BOOTSTRAPPER: unknown bootstrapper: <empty string>

The dialog box contains a useless long block of code, consisting mostly of the status line 

minikube-v1.17.0.iso: MiB / 212.69 MiB % MiB p/s ETA


repeated over and over without line breaks.

Include first run iso/images in RD

On first run RD downloads elements from the Internet. This can be slow and the first startup time is slow. Can this be packaged into the download and copied to the right place (or linked) on first run to speed up the startup experience.

Turn rancher logo and status red on error

When kubernetes goes into an error state the status indicator on the tray drop down and the rancher logo should turn red. This will indicate an error.

We should be able to tie this into the events for status.

Provide setting for number of CPUs to use

The default value provided by minikube is a fine default.

The UI for this should be in the Kubernetes preferences. It can be below the existing Kubernetes preferences and before the CLI linking section.

There should be validation on the values here. If a value passed in will cause a problem for minikube we should catch it, inform the user, and not save the setting.

Support Apple Silicon

Eventually, we will want to support RD on Apple Silicon. This will likely take a little time and tools are still being ported and our dependencies are being ported. But, this is the top level issue to handle support of that.

Make linting better

Currently (with #92) we're disabling a bunch of linting rules, because that PR was already big enough. We should go back and turn on various lint rules and fix anything that crops up.

See https://github.com/mattfarina/rd/issues/92#issuecomment-774306004 for a list of things we should consider:

  • non-interpolating strings: all single-quotes, double-quotes, or don't care?
    I'd vote for double quotes, since that seems to be the majority of what we have. Also, that's the eslint default.
  • missing semicolons
    We should set this to always, because that's what we've been doing.
  • I don't get the "missing trailing comma" message -- does json now allow them?
    I have it set at always-multiline: comma on multi-line things (because it makes future diffs better), never otherwise. Also, eslint shouldn't lint JSON?
  • indentation
    We have a .editorconfig
  • spacing around braces
    I guess we should take eslint defaults here?
  • extra = for all comparisons. Should be on because js type promotion can have unexpected results
    Agreed.

Human friendly error messages

The current error messages include exit codes and error messages that are not easy to understand. Exit codes include those of dependencies which are based on other dependencies.

The error messages (in popups) should be human readable with actions one can take if possible.

k3s fast reset and keep containerd content

When one clicks on the "Reset Kubernetes" button k8s shuts down, the VM is deleted, a new one is created, and k8s is brought back up. This is left over from the way minikube does things by default.

Instead, when the "Reset Kubernetes" button is clicked k3s should be deleted and recreated. containerd should not be reset and images in containerd should stay cached in its location. Note, workloads running in k3s should be killed.

Update language in UI on CLIs linked in

This update would include:

  • Adding context about why the tools can't be linked when they can't be
  • Adding text to explain what these tools are and what is going on

Make sliders work out of the box

The sliders will change the settings in the settings files but RD doesn't apply them. If you restart rancher you get an error that requires running a console command to fix. This should be an intuitive experience.

Support dark mode

The rancher dashboard has a dark mode. It shows, for example, a black body background instead of white. The preferences screens should support dark mode.

Preferences should have a version field

This makes it easier for us to do migrations in the future if existing prefs are dropped or renamed.

Still, we should try for full backward- and forward compatibility:

  • Ignore any unrecognized prefs
  • Never require any fields in a pref block; always supply reasonable defaults.

Local Rancher

A local version of Rancher needs to be running in the environment. This is for a single cluster and does not include multi-cluster management.

Ability to turn off Rancher/Homestead

Rancher installs many components that includes multi-cluster management. A lite version of Rancher (currently dubbed homestead) has numerous features turned off. This is rancher with different configuration to limit it to things like the dashboard (w/o cluster explorer), fleet, authn/z, and the catalog.

In the settings under a new tab on the left for "Rancher" we should have two or possibly more things. We can determine these when we move on this issue.

  1. The ability to turn off rancher. This would turn it off (uninstall it with Helm) and cause RD to not launch it when starting a k8s cluster.
  2. Provide an option to run full Rancher with all the features. This would be opt-in
  3. Possibly provide feature toggles to enable some things and disable others. For example, to enable the UI while disabling fleet. We would do this through passing configuration to the helm install/upgrade commands and the chart. We would expect the underlying features to be in the chart.

Note, if rancher is not installed or the UI is disabled the option in the menu should be removed.

Refactor tray to emit events

I'd like to refactor the menu/tray code so that it's an EventEmitter and we can emit events for the various menu items being clicked. Currently (in #46) I have it emitting events on app, which seems rather wrong.

k3s on Mac

The current setup on mac uses minikube and the default image. k3s should be the running Kuberentes. There are a couple possible ways this could be done.

  1. Using hyperkit start a VM and then install k3s there. Note, the following 3 requirements are needed for this setup...
    1. Any version of k3s needs to be able to be run.
    2. The setup needs to have the ability to reset the environment to default (wipes out any config changes and all workloads are gone).
    3. Upgrades need to work. For example, one could go from 1.16.8 to 1.18.4 while retaining workloads running in the cluster.
  2. Use flags like the --iso-url and registry location to swap out the default minikube environment for k3s.

Add unit testing

RD started as a POC but, as it moves to be a real project it needs testing. A framework needs to be added for testing.

Add a status bar for secondary messages

Some messages are too important to be hidden in the dev-tools console (or in the shell for the background process), but putting them in a dialog box or notification box is too obtrusive. Best to put them in a status bar where they can be dismissed manually or cleared after a settable delay (which should be a prefs-only field).

RD on Windows

We need to have RD running on Windows and that includes Windows Home where there is no hypervisor. Instead of a normal hypervisor we should use Windows Subsystem for Linux (likely v2). WSL is available on Windows 10 Home.

With WSL we could either install and manage k3s in an existing Linux or start up a custom Linux setup and expose K3s to windows and the other Linux instances from there. This is open for discussion.

This isn't going to use Minikube as minikube on Windows doesn't work with WSL to manage the things.

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.