crc-org / crc-extension Goto Github PK
View Code? Open in Web Editor NEWRed Hat OpenShift Local Extension for integration of OpenShift Local clusters with Podman Desktop
License: Apache License 2.0
Red Hat OpenShift Local Extension for integration of OpenShift Local clusters with Podman Desktop
License: Apache License 2.0
I have installed OpenShift Local from the extension:
Now inside of Podman Desktop, I'm getting asked to install a preset:
If I hit "escape", then I have "install" again displayed on the dashboard and I need to redownload OpenShift Local entirely.
If I hit "microshift", then
I'm in a weird state, where I have multiple statuses displayed:
I am usually picking up custom location where I install crc (linux, windows), it would be nice to offer a user a way to setup crc which is not on PATH.
Provide a input field in CRC extension page for crc binary.
The original tray handled the telemetry gathering for the UI-related actions. If Podman Desktop can return if consent has been given, we can use this functionality to allow this to prevent an additional consent prompt.
Note: the backend already knows where actions originate from, so the telemetry in that case is redundant.
The defaults and presets are currently part of package.json
Line 27 in 3427cc1
but this would cause problems, as these values are based on the preset that is chosen.
I had CRC v2.5 installed, and it was shown on the dashboard. I needed to update to the latest (2.17 currently) but there's no help to do it. We should prompt the user to update and help them do it.
@themr0c, this is something we have to start outlining.
Especially in light of: containers/podman-desktop#1686 (comment)
This is a follow-up to #83. To correctly inform the user, we should provide the current version of CRC, the installed version of OpenShift and possible new version
We need to implement update flow with podman-desktop API for update of installed binary
I had the CRC 2.5 cli installed. The extension showed it as stopped, and clicking Start from the system tray showed no change nor error.
After I upgraded from the command line to 2.17 it worked fine. I'm ok having to update, but there should have been some failure in the UI when I tried to start.
% crc version
WARN A new version (2.17.0) has been published on https://developers.redhat.com/content-gateway/file/pub/openshift-v4/clients/crc/2.17.0/crc-macos-installer.pkg
CRC version: 2.5.1+5b02b826
OpenShift version: 4.10.18
Podman version: 4.1.0
% crc config view
- consent-telemetry : yes
- memory : 4608
-
% crc status
CRC VM: Stopped
OpenShift:
Podman: 3.4.4
Disk Usage: 0B of 0B (Inside the CRC VM)
Cache Usage: 102.7GB
Cache Directory: /Users/deboer/.crc/cache
% crc start
WARN A new version (2.17.0) has been published on https://developers.redhat.com/content-gateway/file/pub/openshift-v4/clients/crc/2.17.0/crc-macos-installer.pkg
INFO Checking if running as non-root
INFO Checking if crc-admin-helper executable is cached
INFO Checking for obsolete admin-helper executable
INFO Checking if running on a supported CPU architecture
INFO Checking minimum RAM requirements
INFO Checking if crc executable symlink exists
INFO Checking if running emulated on a M1 CPU
INFO Checking if vfkit is installed
INFO Checking if old launchd config for tray and/or daemon exists
INFO Checking if crc daemon plist file is present and loaded
INFO Loading bundle: crc_podman_vfkit_4.1.0_arm64...
Bundle 'crc_podman_vfkit_4.1.0_arm64' was requested, but the existing VM is using 'crc_podman_hyperkit_3.4.4'. Please delete your existing cluster and start again
OS: Windows 10 Pro
podman-desktop: built from master
CRC extension: ghcr.io/crc-org/crc-extension:latest
After finishing the installation for CRC to work, we need to reboot the machine, while doing the installation from the extension/podman-desktop this is notified to the user via a message box that asks user to reboot, but after a few seconds of showing the msg box a new msg box is shown asking the user to select a preset and once selection is made or cancelled in which case the default preset is used, it goes on to download the bundle.
Trying to start CRC and go on with the suggested flow will eventually lead to the following error:
Q: Should we wait till the user reboots to show the preset selection msg box next time podman-desktop is started? as without a reboot user won't be able to use CRC.
Q: Can we put a Reboot
button on the msg box that notifies the user to just click and reboot the machine?
Perhaps:
crc-extension/src/extension.ts
Line 160 in b6c84ac
should be OpenShift Local
instead of OpenShift
I now see the OpenShift Local instance under Settings > Resources (yay!). I clicked on the delete button and get a notification that is has been deleted, but it is still there. I can delete a second time and get an error that it doesn't exist and I can click start (?) to create it.
Expectation: Clicking delete makes it disappear, and then I need to create a new instance before I can see (and start) it again.
yarn build
reports:
warning ..\..\..\..\..\package.json: No license field
warning [email protected]: The engine "podman-desktop" appears to be invalid.
$ rollup --bundleConfigAsCjs --config rollup.config.js --compact --environment BUILD:production
src/extension.ts, node_modules/hasha/thread.js → dist...
(!) "this" has been rewritten to "undefined"
https://rollupjs.org/troubleshooting/#error-this-is-undefined
node_modules/form-data-encoder/lib/FormDataEncoder.js
1: var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
^
2: if (kind === "m") throw new TypeError("Private method is not writable");
3: if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
...and 3 other occurrences
created dist in 6.1s
Done in 7.90s.
The extension should get a consistent naming - "OpenShift Local" instead of CRC. And it should also use the OpenShift icon
Like in tray-electron, add a functionality to the tray menu to allow the user to start a developer prompt that sets oc-env
.
We need to come up with a solution to more clearly indicate the location to get the pull-secret, as the palette option is hard to understand; not very visible and provides no information on the next step to solve this.
While we have:
It is not clear when this will be available.
The extension need to properly request the pullsecret when needed and perform basic validation before setting it.
On startup, when no pull-secret is available, the start will be postponed until the user has provided this; a dialog or input will be shown to collect this.
The user should be abel to provide the pull-secret from the configuration before start.
Basic validation is performed to make sure the pull-secret is a valid json message; a simple {
and }
is sufficient as a first increment.
Betttr to use https:/github.com/containers/podman-desktop.git
Line 53 in 044ee3a
otherwise access rights are needed
It hangs Starting
stage until manually refresh and also that is not even starting the cluster (no crc start process when click to start)
The dev console print following as soon as I hit Run Openshift Local
dex.ts:1299 main ↪️ [openshift-local] Error: cluster is busy
at DaemonCommander.start (/Users/prkumar/.local/share/containers/podman-desktop/plugins/ghcriocrcorgcrcextension/dist/extension.js:9335:19)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async startCrc (/Users/prkumar/.local/share/containers/podman-desktop/plugins/ghcriocrcorgcrcextension/dist/extension.js:25250:24)
at async Ij.startProviderLifecycle (/Applications/Podman Desktop.app/Contents/Resources/app.asar/packages/main/dist/index.cjs:83:47731)
at async /Applications/Podman Desktop.app/Contents/Resources/app.asar/packages/main/dist/index.cjs:335:2063
at async node:electron/js2c/browser_init:2:97945
As part of the onboarding of Podman Desktop, we need a way to be 'recommended' or allow the download to happen/activated. This is part of the Podman Desktop onboarding timeline. I created issue: https://github.com/containers/podman-desktop-internal/issues/83.
Note: The extension is already published, but might need to move to a new namespace; ref containers/podman-desktop#20
quay.io/redhat-developer/openshift-local-extension
Now we are using several scripts for build, some of them in JavaScript and some in TypeScript.
Need to rewrite them in to TypeScript.
Yes, we want to focus on hosting OpenShift and Microshift. But if you happen to have crc installed and used the podman preset, the extension is unable to do anything; trying to initialize hangs indefinitely. You are essentially stuck in this situation until you use the cli to delete and reset the config preset: https://access.redhat.com/discussions/6895111?tour=8
We should do the minimum to notify or help the user out of this situation. Ideally the other actions in the UI would be disabled and there'd be a warning with an optional action to fix the situation; even a warning with a link to a doc would be ok.
When installing from a fresh environment. When the popup is asking to choose a preset, if the user presses "ESC3 on the keyboard, the download process still start.
We need to provide an indication to the end user onto where to get the pull secret, otherwise, most users will be just stuck
It is requested to show the preset that is selected on the dashboard. This currently shows OpenShift Local is running
based on the provider state.
It is not clear how much we can actually add and how this can be formatted. but this could be {ProductName}: {preset} is {state}
I had a cluster created from the extension, but it's impossible to restart it.
On my laptop, I'm using iTerm.
When clicking on "Open developer terminal" it uses the MacOS terminal, while it should use my default one.
I click on the install
and then it started downloading the pkg file and I can see the status bar. Then I just exploring other options and came back to dashboard and I see the install
button again available to use so I again clicked it and I can see now in the status bar a new Downloading Openshift Local
and previous one is just stopped at 26%
.
When containers/podman-desktop#2187 is merged, we could use that API to indicate long running task:
crc setup
progressWe need to update the README file to have installation and update steps of the extension (if possible may be a gif which shows how it is installed).
Missing on the resource page is:
At the moment, the API is missing for this.
As of now we have option Push Image to kind cluster which works with kind cluster. We also need an option for Push Image to OpenShift Local cluster which sync image from podman machine instance to OpenShift Local instance.
Moved from containers/podman-desktop#2263
Allow configuration changes be made to:
and keep these in sync with the crc-daemon and extension.
Currently blocked by: containers/podman-desktop#1732
crc-extension/src/install/win-install.ts
Line 49 in d4f6b39
The current extension description is a bit wordy:
"This extension provides a Red Hat OpenShift Local cluster and allows Podman Desktop to interact with it"
and stands out from the other extensions. It should probably be something more like:
"Integration for OpenShift Local"
or at least start with that and include a short description of what OpenShift Local is or what you can do with it.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.