Skip to content

m4rc2a/nextcloud-kubernetes

Repository files navigation

Prerequisites

Installation

In the official installation guide there is no exact installation for windows but there are executable binarys available on github.

Download the executables

Releases · knative/client · GitHub

Releases · knative-sandbox/kn-plugin-quickstart · GitHub (Only if you want to do the quickstart)

move the executable file e.g. to C:\Program Files\Knative\. You may want to create an extra folder for Knative.

Add to PATH environment variable

Press Windows + R type "control" and press enter.

Press the Windows+X

Click on system

Go to Advanced System Settings and then to Environment Variables

Select the PATH variable and click on Edit

Click on new and insert the installation directory

Click on new and paste the installation directory. For example "C:\Program Files\kn".

Verify

Verify that the plugin is working by running the command:

kn version

Quickstart

From here on you can follow the [official instructions](Install Knative using quickstart - Knative) to do the quickstart.

Notice: if you use minikube instead of kind enter c

kn quickstart minikube

instead of

kn quickstart kind

Notice: if you are using Docker you can access the webserver by using Encrypted SOCKS tunnel via ssh. (Only as a temporary solution)

To have access via ssh you can create a ssh key by typing

ssh-keygen

To gain access via ssh, you can create an ssh key by typing: ssh-keygen You can specify the algorythm with -t and the bit value with -b.

For example for rsa

ssh-keygen -b 4096

and for ed25519

ssh-keygen -ted25519

When you generated the ssh keys you have to add the public key to the ~/.ssh/authorized_keys file.

Then you have to edit the /etc/ssh/sshd_config config file.

But you can just run this command in the Docker Desktop Terminal:

echo -e "Port 22\nAddressFamily any\nPermitRootLogin yes\nPubkeyAuthentication yes\nAuthorizedKeysFile      .ssh/authorized_keys .ssh/authorized_keys2" >> /etc/ssh/sshd_config

But actually you don't have to log in with an ssh key, because it's all local on the computer anyway. Then you only have to set other things in the config file.

Unfortunately, the port on the Docker container for ssh is different after each startup. To find out which port you can use to access ssh, enter the command:

PS C:\Users\praktikant> docker port knative
22/tcp -> 127.0.0.1:2696 <-- ssh port
2376/tcp -> 127.0.0.1:2697
32443/tcp -> 127.0.0.1:2698
5000/tcp -> 127.0.0.1:2694
8443/tcp -> 127.0.0.1:2695

Now that you know the ssh port you can login with

ssh -i (private key) -p (port) root@127.0.0.1

ssh -i (private key).

For example, the command to log in would look like this. You can shorten it by configuring the ssh client

ssh -i %HOMEPATH%/.ssh/id_ed25519 -p2696 root@127.0.0.1

to create the tunnel run

ssh -i (private key) -p (port) -vvTND 4711 root@127.0.0.1

For Firefox: At Preferences > General navigates to the bottom of the page and click Settings..., which is to the right of the Network Settings title. Next, within the new semi window, check the Manual proxy configuration option and enter localhost in the SOCKS host text field, and the port number in the Port text field (4711 in the example above) next to it.

Firefox does not automatically make DNS requests through the socks tunnel. This potential privacy concern can be mitigated by scrolling further down, checking in the Proxy DNS when using SOCKS v5. Obviously, this will only work if you chooses SOCKS v5 rather than v4.

Restart Firefox to activate these settings.

i don't know exactly how to set this in chrome but maybe it helps to set these variables to these values and then open chrome:

SOCKS_SERVER=localhost:4711
SOCKS_VERSION=5

Unfortunately, at least I can't access the Internet through the tunnel, so you always have to disconnect as soon as you want to access the Internet.

About

kubernetes-test

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •