-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
21 changed files
with
61 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Félicitations. | ||
Vous maitrisez kubectl, mais pourquoi ne pas passer à k9s ? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Félicitations. | ||
Les pods c'est bien, mais les déploiements, c'est mieux :) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Félicitations. | ||
N'hésitez pas à mettre à jour vos déploiements pour rajouter ces probes, pour plus de disponibilité. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Félicitations. | ||
Configurez vos déploiements avec des configmap et des secrets avec aisance :) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Félicitations. | ||
Les services n'ont plus de secrets pour vous ! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Félicitations. | ||
Vous maitrisez maintenant les bases des déploiements sur Kubernetes. Il existe des moyens automatisés de gérer cela, mais ce n'est pas au programme de cette session. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/bin/bash | ||
if [[ ! -e "/tmp/god" ]]; then | ||
grep "hpa-example" /tmp/res-step1 | ||
grep "hpa" /tmp/res-step1 | ||
fi |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Félicitations. | ||
Vous avez terminé l'ensemble des TP sur cette School Kubernetes, nous esperons que cela vous a plu. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
#!/bin/bash | ||
|
||
grep $(kubectl get secret mysql -o jsonpath='{.data.password}' | base64 -d) /tmp/res-step1 | ||
if [[ ! -e "/tmp/god" ]]; then | ||
grep $(kubectl get secret mysql -o jsonpath='{.data.password}' | base64 -d) /tmp/res-step1 | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,77 +1,60 @@ | ||
## 1/ Créer les volumes | ||
Appliquer ces 2 commandes | ||
|
||
Créer les volumes pour mysql et wordpress | ||
``` | ||
kubectl apply -f volume/mysql-volumeclaim.yaml | ||
kubectl apply -f volume/wordpress-volumeclaim.yaml | ||
kubectl apply -f volume/mysql-volumeclaim.yaml -f volume/wordpress-volumeclaim.yaml | ||
```{{exec}} | ||
## 2/ Créer ma base de données MySQL | ||
Les descripteurs permettant de déployer une base de données sont founis dans le TP. Les examiner et les appliquer: | ||
## 2/ Créer la base de données MySQL | ||
Les YAML permettant de déployer une base de données sont founis dans le TP. | ||
Vous pouvez les examiner avec `cat` | ||
``` | ||
cat volume/mysql.yaml | ||
```{{exec}} | ||
``` | ||
kubectl apply -f volume/mysql.yaml | ||
```{{exec}} | ||
``` | ||
cat volume/mysql-service.yaml | ||
```{{exec}} | ||
Les déployer: | ||
``` | ||
kubectl apply -f volume/mysql-service.yaml | ||
kubectl apply -f volume/mysql-service.yaml -f volume/mysql.yaml | ||
```{{exec}} | ||
## 3/ Créer l'instance Wordpress et l'exposer | ||
Les descripteurs sont founis dans le TP. Les examiner et les appliquer: | ||
Les YAML sont founis dans le TP. | ||
Vous pouvez les examiner avec `cat` | ||
``` | ||
cat volume/wordpress.yaml | ||
```{{exec}} | ||
``` | ||
kubectl apply -f volume/wordpress.yaml | ||
```{{exec}} | ||
``` | ||
cat volume/wordpress-service.yaml | ||
```{{exec}} | ||
Les déployer: | ||
``` | ||
kubectl apply -f volume/wordpress-service.yaml | ||
kubectl apply -f volume/wordpress.yaml -f volume/wordpress-service.yaml | ||
```{{exec}} | ||
## 4/ Vérifier l'état des pods | ||
Lancer la commande et attendre que les 2 pods soient en état "Running" | ||
Lancer la commande et attendre que les 2 pods soient en état "Running" (faire Ctrl + C quand tout est bon) | ||
``` | ||
watch kubectl get pods | ||
```{{exec}} | ||
## 5/ Accédez à votre wordpress | ||
Afficher via la commande `curl` la page d'installation de wordpress | ||
``` | ||
curl -L http://172.30.1.2:30000 | ||
```{{exec interrupt}} | ||
> Si vous constatez une erreur liée à la connexion avec la base de données, patienter 10 secondes et retenter la commande. | ||
> Si vous constatez une erreur liée à la connexion avec la base de données, patienter 10 secondes et retentez la commande. | ||
### Challenge | ||
Accédez à l'application depuis votre navigateur | ||
- En haut à droite de la fenêtre terminal, cliquer sur la petite icône représentant 3 barres (menu "hamburger") | ||
- Dans le menu qui s'ouvre, choisir "Traffic / Ports" | ||
- Dans la zone de saisie "Custom Ports" pour un des 2 hosts, entrer "30000" | ||
- Cliquer sur "Access" | ||
> Il est possible que vous obteniez une page d'erreur "502". Dans ce cas recharger la page. | ||
1. En haut à droite de la fenêtre terminal, cliquer sur la petite icône représentant 3 barres (menu "hamburger") | ||
2. Dans le menu qui s'ouvre, choisir "Traffic / Ports" | ||
3. Dans la zone de saisie "Custom Ports" pour un des 2 hosts, entrer "30000" | ||
4. Cliquer sur "Access" | ||
- Vous obtenez la page d'installation de Wordpress, vous pouvez suivre la procédure si vous le souhaitez. | ||
Ces erreurs sont liées à des limitations dans les environnements de test Killerkoda | ||
> Il est possible que vous obteniez une page d'erreur "502". Dans ce cas recharger la page. |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.