27 Commits

Author SHA1 Message Date
David Cassany
cd3b23eb79 Add RPM and DEB targets to electron-builder
This commit adds RPM and DEB targets to the electron builder manifest
and uploads the result within the packaging workflow.

Signed-off-by: David Cassany <dcassany@suse.com>
2021-10-08 10:52:05 +02:00
David Cassany
566302c32b Rename linux icons to electron-builder expectations
Signed-off-by: David Cassany <dcassany@suse.com>
2021-10-08 10:52:05 +02:00
Matt Farina
29274197e8 Updating nerdctl script to use sh instead of bash
sh is required for WSL while bash is not. This makes the script
more widely usable

Signed-off-by: Matt Farina <matt.farina@suse.com>
2021-10-07 17:15:33 -04:00
Matt Farina
56f51eb8cc Make nerdctl script work in both WSL and on native linux
This will detect when linux is run in WSL or by itself to know
which method to talk to nerdctl.

Note, also removed debug output accidently left in.

Signed-off-by: Matt Farina <matt.farina@suse.com>
2021-10-07 06:48:24 -04:00
David Cassany
8116e0131f Do not call process.kill(0) on exit
Signed-off-by: David Cassany <dcassany@suse.com>
2021-10-06 13:55:47 +02:00
David Cassany
eb8cb2e552 Make use of nerdctl under linux
Signed-off-by: David Cassany <dcassany@suse.com>
2021-10-06 13:55:47 +02:00
David Cassany
68697abf14 Adding icons, desktop file and appdata xml
This commit adds the desktop files that flatpak expects for a proper
desktop integration according to the FreeDesktop specs.

Signed-off-by: David Cassany <dcassany@suse.com>
2021-10-06 13:55:47 +02:00
Jan Dubois
1ee48338a8 Run nerdctl via sudo
Also needs to pass-through CONTAINERD_ADDRESS because we set it in
~/.profile and not yet in /etc/environment.

Signed-off-by: Jan Dubois <jan.dubois@suse.com>
2021-09-22 12:10:39 -07:00
Mark Yen
0ae90b18c7 WSL: Do argument translation for nerdctl
This updates nerdctl-stub to parse arguments (such as
`nerdctl build --file`) and translate the paths.  On Windows (the host),
this just means convert it to `/mnt/c/...` form; on Linux (a second WSL
distribution), this means making a temporary bind mount under `/mnt/wsl/`
and converting relevant arguments to point to that instead.

In order to do the mounting, the nerdctl-stub binary needs to be setuid
root.  We therefore need to copy it to somewhere under `/mnt/wsl/` as well,
since anything under `/mnt/c/` (DrvFS) doesn't support setuid properly.

In order to correctly parse the arguments, we use a generator that parses
the output of `nerdctl -help` (and various subcommands) to build our
understanding of the available subcommands and options.  This may be
triggered on a Windows machine with the `rancher-desktop` WSL distribution
using `npm run generate:nerdctl-stub`.  (The requirement is to be able to
execute the `nerdctl` binary to parse its output.)

Signed-off-by: Mark Yen <mark.yen@suse.com>
2021-09-17 15:40:20 -07:00
Jan Dubois
fb78b341c3 Rename scriptname → scriptdir
This rename was done before manually, but 2 instances were missed.

Signed-off-by: Jan Dubois <jan.dubois@suse.com>
2021-09-16 10:07:46 -07:00
Matt Farina
7505928dbe Updating nerdctl script to new storage location
Signed-off-by: Matt Farina <matt.farina@suse.com>
2021-09-15 13:37:44 -04:00
Matt Farina
17498aa420 Updating the nerdctl script based on Jan's feedback
Signed-off-by: Matt Farina <matt.farina@suse.com>
2021-09-15 13:33:28 -04:00
Matt Farina
d778999c72 Improving the nerdctl detection of running rd
Based on feedback from Jan.

Signed-off-by: Matt Farina <matt.farina@suse.com>
2021-09-15 13:33:28 -04:00
Matt Farina
bc2c0974c9 Add support for nerdctl on macos.
This includes:
- nerdctl as a CLI that can be added to the path like the other
  tools.
- An updated version of alpine-lima that includes nerdctl and the
  other binaries it needs.
- ~ is mounted so that nerdctl build can access the files to build.
  nerdctl build will not work for locations outside of ~.
- A .profile file exporting an environment variable to tell nerdctl
  where the containerd socket is as k3s puts it in a non-standard
  location.

Note, in the future we should look at taring up the build directory
and sending it to the VM. That would be a more substancial effort
to accomplish.

Related to #566

Thanks to Jan for all the pointers in creating this and the alpine-lima
build.

Signed-off-by: Matt Farina <matt.farina@suse.com>
2021-09-15 13:33:24 -04:00
Phillip Rak
088d0c58b3 Add new tray icons for macOS
Signed-off-by: Phillip Rak <phillip.rak@suse.com>
2021-09-02 17:26:40 -07:00
Eric Promislow
5c9d1139f0 Add a command to use trivy to scan images for vulnerabilities
* Install trivy in download-resources
* On Windows, we run trivy via wsl because there's no windows port
* But... to speed things up, we want wsl commands to hit the linux mount, not the windows mount
  - So we move the files from the windows mount to the linux once we know the
    rancher-desktop subsystem is available.
  - And to simplify this work, provide a resources function `wslify` to convert full windows
    paths into wsl paths in the windows mount.

Signed-off-by: Eric Promislow <epromislow@suse.com>
2021-08-04 15:15:04 -07:00
Matt Farina
f5b57459e0 Adding a macOS icon fitting Apple guidance
Closes #237

Signed-off-by: Matt Farina <matt.farina@suse.com>
2021-06-11 16:34:41 -04:00
Matt Farina
2b6997100a Correcting bw image dimensions
Signed-off-by: Matt Farina <matt.farina@suse.com>
2021-04-27 17:26:44 -04:00
Matt Farina
6303799e14 Correnting errors in move to new logo and name
Signed-off-by: Matt Farina <matt.farina@suse.com>
2021-04-27 16:30:22 -04:00
Matt Farina
732f8577b1 Updating to new icons
Signed-off-by: Matt Farina <matt.farina@suse.com>
2021-04-23 16:31:18 -04:00
Eric Promislow
2aa28ce464 Remove the Dashboard and all uses of Homestead
Signed-off-by: Eric Promislow <epromislow@suse.com>
2021-03-29 16:35:08 -07:00
Mark Yen
105ffe7d45 icons: Add issue-opened icon
The icon is from GitHub's "octicons" set, under the name "issue-opened".
The PNG file was generated via:

rsvg-convert issue-opened-16.svg --output=issue-opened-16.png

The larger verions was generated via:

rsvg-convert issue-opened-16.svg --zoom=2 --output=issue-opened-16@2x.png
2021-01-07 17:56:33 -08:00
Mark Yen
776cd57716 resources: add red variant icons
Icons are created via:

for i in logo-square{,@*}.png; do
  convert $i -colorize 200,-200,-300 ${i%.png}-red.png
done
2021-01-07 17:08:28 -08:00
Matt Farina
1585332667 Installing homestead by default.
Homestead is the current name for local rancher. This is in
development but provides a means for us to get to the Rancher
Dashboard among other things.

Closes #7

Signed-off-by: Matt Farina <matt@mattfarina.com>
2020-12-17 10:43:36 -05:00
Matt Farina
faecc6abba tray icon changes color based on k8s status
Signed-off-by: Matt Farina <matt@mattfarina.com>
2020-10-20 13:36:01 -04:00
Matt Farina
2b305ce1f3 Updating the icon usage
Signed-off-by: Matt Farina <matt@mattfarina.com>
2020-10-14 09:37:52 -04:00
Matt Farina
5e27fda22b Initial commit
This is a proof of concept for wrapping the "engine" (minikube or
something else) in electron as a UI. This is the base building
block for the desktop.

Signed-off-by: Matt Farina <matt@mattfarina.com>
2020-10-12 12:33:39 -04:00