Is setting up a failover k3s cluster between the cloud and on-premises still relevant? - kubernetes

I am an IoT Infrastructure Engineer student at Howest Kortrijk. For a project in my final year I have to figure out the following question, "How to build a failover Kubernetes cluster between an on-premises and cloud environment using Rancher?".
I have sat up a k3s cluster myself and tried to install Rancher, but without success. So much for my problems with the technical solution. In fact, I am left with another question. Is it actually still relevant to set up everything yourself and dabble with this.
Wouldn't it be better to run everything in the cloud?
Surely there are plenty of solutions for this?
Are running things on-premises still pertinent?
I myself don't have much experience with this yet. But hopefully there are experts here with a bit more experience who can answer these questions.
I recently attended an Azure (for developers) session and it got me thinking.

Related

What benefits does Cloud Composer provide over a Helm chart and GKE?

As I dive into the world of Cloud Composer, Airflow, Google Kubernetes Engine, and Kubernetes I've not yet found a good answer to what exactly makes Cloud Composer better than Helm and GKE.
Here are some things I've found that could be unique to Composer but mostly seem like they could be handled by GKE.
On their homepage:
End-to-end integration with Google Cloud products including BigQuery, Dataflow, Dataproc, Datastore, Cloud Storage, Pub/Sub, and AI Platform gives users the freedom to fully orchestrate their pipeline.
On the features page:
Identity-Aware Proxy protects the interface
Cloud Composer associates a Cloud Storage bucket with the environment. The associated bucket stores the DAGs, logs, custom plugins, and data for the environment.
The downsides of Composer I've seen include:
It takes many hours to spin up a new instance
It doesn't support Kubernetes Executor
It is risky to change the underlying GKE config because it could be changed back by a composer update
There are often errors that happen when auto-scaling often happen but are documented as known
Upgrading environments is still beta
To be clear, I'm not saying Cloud Composer is bad. I'm just having trouble seeing why people like it. When I've asked folks why it is better than Helm + GKE they haven't had any compelling answers despite that they can tell many stories of Composer being unpredictable and having lots of issues.
Are you comparing the same things?
On one side, GKE, you have a container orchestrator. Declare that you want, it will deploy and maintain the stability of the cluster according with declared configuration. This configuration can be packaged with helm to write it in an easier mode. Because you deploy container, you can use the language that you want in your services.
On the other side, you have a workflow manager, with scheduler, retry policies, parallel task, context forwarding. you write DAG in python (only!) and you have operators to interact with external product/services. It's mainly designed for data processing and used a lot by data scientist and data engineering team.
Note: Cloud Composer is deployed on top of GKE (scheduler and worker), redis, app engine and Cloud SQL.
You compare 2 different worlds: Ops world (GKE/Helm) and the App/Data world (Composer/Airflow). Have a look to this new video
Update 1:
My bad, I didn't understand!!! Anyway, personally I don't want to manage things by myself: a cluster, the update of K8S, VM patching, replicas, snapshot, backup/restore,...
If someone can do this for me, I prefer, and managed services are perfect for me!!
Do you ask yourselves this question about Cloud SQL and a database managed by yourselves on a Compute Engine instance? If not (because Cloud SQL solve a lot of boring issues), my opinion is the same for Composer.
But it's an opinion, I didn't test both and compare the performance, cost and easiness.

Migrating Atlassian Confluence to Kuberntes

I am in the process of migrating Atlassian Confluence from on-prem to Kubernetes. I found the official docker image for confluence and was able to spin up the application. I need to configure ssl and i already have the key and certificate. I tried to import the certificates and restarted the server.xml and it is not working. Has any worked on confluence migration from on-prem to kubernetes/docker and if any can provide a link/experience related to the same, it would be helpful.
Regards,
John
It's certainly possible, the healthcheck might be tricky and the reason for that is there is no automated install as far as I'm aware when it becomes live, meaning there will always been a manual configuration stage.
You're best looking at some package manager examples for this, which for Kubernetes is Helm. This allows you to iterate and rollback quickly.
Have a look at this example) which is for Jira, but the same flow should apply. Confluence and Jira are heavily related, so it should be relevant.

Using Kubernetes or easier orchestration tools

Hoping that there is some good insight into how to handle orchestration amount microservices in an on prem smaller company environment. Currently, the systems that we are looking to convert from monolithic to microservices like the rest of the world :).
The problem I'm having with as an architect, is justifying the big learning curve and server requirements with the resources we have at the moment. I can easily see us having 50ish microservices, which I feel could be on that line of using kubernetes or not.
The thing is, if we don't, how do we monitor if it is on-prem. We do use Azure Devops, so I'm wondering if this would safice for deployment parts.
Thanks!
This comes down to a debate over essential vs accidental complexity. The verdict is in from companies that k8s strikes a good balance vs swarm and other orchestrators are barely talked about in the industry.
https://www.reactiveops.com/blog/is-kubernetes-overkill
The platforms that build on kubernetes are still emerging to offer a simpler interface for those wanting a higher level of abstraction but aren't mature enough yet. GKE offers a very easy way to just deal with workloads, AKS is still maturing so you will likely face some bugs but it is tightly integrated with Azure Devops.
Microsoft is all-in on k8s although their on-prem offering doesn't seem fully fledged yet. GKE on-prem and Openshift 4.1 offer fully managed on-prem (if using vSphere) for list price of $1200/core/year. https://nedinthecloud.com/2019/02/19/azure-stack-kubernetes-cluster-is-not-aks/
Other ways of deploying on prem are emerging so long as you're comfortable with managing the compute, storage and network yourself. Installing and upgrading are becoming easier (see e.g. https://github.com/kubermatic/kubeone which builds on the cluster-api abstraction). For bare metal ambitious projects like talos are making k8s specific immutable OSes (https://github.com/talos-systems/talos).
AWS is still holding out hope for lock-in with ECS and Fargate but it remains to be seen if that will succeed.

Learning to use Kuberentes on one single computer

I'm in the need of learning how to use Kubernetes. I've read the first sentences of a couple of introductory tutorials, and never have found one which explains me, step by step, how to build a simulated real world example on a single computer.
Is Kubernetes by nature so distributed that even the 101-level tutorials can only be performed on clusters?
Or can I learn (execute important examples) the important stuff there is to know by just using my Laptop without needing to use a stack of Raspberry Pi's, AWS or GCP?
The easiest might be minikube.
Minikube is a tool that makes it easy to run Kubernetes locally.
Minikube runs a single-node Kubernetes cluster inside a VM on your
laptop for users looking to try out Kubernetes or develop with it
day-to-day.
For a resource that explains how to use this, try this getting started guide. It runs through an entire example application using a local development environment.
If you are okay with using Google Cloud Platform (I think one gets free credits initially), there is hello-node.
If you want to run the latest and greatest (not necessary stable) and you're using Linux, is also possible to spin up a local cluster on Linux from a cloned copy of the kubernetes sources, using hack/local_up_cluster.sh.

How to run 2 wordpress blogs using docker on ec2

I just started playing around with Docker.io. Its a great platform for sure. I have an issue i need some help with. I ran a medium instance on ec2 setup docker. Now i want to run 2 wordpress blog independent of each other using docker.io on top of the medium instance.
Please if someone can kindly guide me to resolve this issue i will extremely grateful
Many Thanks Indeed
Hareem Haque
Updated:
Basically, what i am trying to do is run two nodes for docker (node 1 & node 2). I run another node (node3: private repo for docker). What i am looking to accomplish is i run two blogs (wordpress on node1). I export the docker images to node3 (updates/exports are done very rarely)
Since i am going to run wordpress i was hoping to run wordpress within Nginx and since node1/node2 will run 80 web i can put a physical node (nginx reverse proxy) in front of the two nodes and have the blogs run in ha mode.
I am hoping that this experiment work so i that i can get rid of the xen cloud platform we have in office. Its to bulky and I have to manage alot of components.
I would rather export/backup docker image with my live data once in a blue moon and not have to worry about failover and vm management.
The problem is that i have a novice when it comes to running docker and thus i am currently running around like a head less chicken with no idea where to properly begin.
I would be extremely grateful if you can provide any guidance/assistance indeed.
Best Regards
Hareem Haque
Hareem asked his question a while back, and there don't seem to be any good answers yet. I'm a noobie as well, and I too want to learn how to use a generic wordpress container that I can push to Amazon or test locally. I'm very new to docker, so this seems like a tall order!
Goal
For now, I'll start collecting some resources here. Maybe they will help Hareem, and others like myself. This document will turn into a complete answer, or prompt someone else to give their version of an answer (which I'm sure is not quite so complex.)
The Docker.io Index
First, the Docker index is a repository of already existing Docker.io components. Of these, there is a wordpress unit that seems relevant here:
jbfink - Wordpress 3.5.2.
Docker on EC2
There is as yet no official Docker support for Ec2. However, the Docker community suggests an install path using a tool called Vagrant. The instructions for this live here:
Docker Doc - Installing on Amazon EC2
Work In Progress
This is not a complete answer to the question. As of right now this only presents a couple of easy to locate resources, and perhaps goes against guidelines. Please bear with this!
Things that need to be answered:
How do we run / test the wordpress container(s) locally?
How do we push the container(s) up to the EC2 instance?
How do we wire the EC2 wordpress containers up to their own domains?
Hopefully I will answer these questions - contributions and forks are welcome. I think Hareem's question is worth answering!