issue201:c_c
Différences
Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentesRévision précédenteProchaine révision | Révision précédente | ||
issue201:c_c [2024/01/28 14:53] – auntiee | issue201:c_c [2024/01/29 12:28] (Version actuelle) – andre_domenech | ||
---|---|---|---|
Ligne 1: | Ligne 1: | ||
**I was talking to a friend who is stuck in a dead end sales job, about learning the basics of code, so he can learn QA. (His background is actually QC) After a bit of uhm-ing and ah-ing, we got onto the topic of getting up and running with Python. He had tried before and ended up creating a python VM and followed along for the first lesson, but went to sleep thereafter. When he got to the second lesson, he was stuck, not knowing how to get back into that Python VM, so he gave up. I know these kinds of frustrations, | **I was talking to a friend who is stuck in a dead end sales job, about learning the basics of code, so he can learn QA. (His background is actually QC) After a bit of uhm-ing and ah-ing, we got onto the topic of getting up and running with Python. He had tried before and ended up creating a python VM and followed along for the first lesson, but went to sleep thereafter. When he got to the second lesson, he was stuck, not knowing how to get back into that Python VM, so he gave up. I know these kinds of frustrations, | ||
- | Afin qu’un ami, qui est actuellement bloqué dans un poste de vente sans avenir, puisse apprendre l’Assurance qualité (QA), je lui parlais de l’apprentissage des bases de codage. (En fait, il connais | + | Afin qu’un ami, qui est actuellement bloqué dans un poste de vente sans avenir, puisse apprendre l’Assurance qualité (QA), je lui parlais de l’apprentissage des bases du codage. (En fait, il connaît |
**I decided to put it onto paper how we did it, that way you guys ‘n gals can share it around. An Ubuntu install is straight forward, so we will skip that part. Once installed, do all the updates. Obviously one can install all the Snaps with one line from the terminal; snap install postman pycharm-community multipass | **I decided to put it onto paper how we did it, that way you guys ‘n gals can share it around. An Ubuntu install is straight forward, so we will skip that part. Once installed, do all the updates. Obviously one can install all the Snaps with one line from the terminal; snap install postman pycharm-community multipass | ||
Ligne 9: | Ligne 10: | ||
Want to know the best part? I just did it all again in a VM! I just created an Ubuntu desktop Virtual Machine on top of Linux Lite 6.6, that in turn runs an Ubuntu server VM. If you are a n00b to all of this, you may ask, “what am I smoking? | Want to know the best part? I just did it all again in a VM! I just created an Ubuntu desktop Virtual Machine on top of Linux Lite 6.6, that in turn runs an Ubuntu server VM. If you are a n00b to all of this, you may ask, “what am I smoking? | ||
- | J’ai décidé de mettre par écrit ce que nous avions fait pour que vous, les lecteurs et lectrices, | + | J’ai décidé de mettre par écrit ce que nous avions fait pour que vous, les lecteurs et lectrices, |
- | Et tout de suite, votre « client-side » (côté client) est configuré. Pycharm crée les VM Python à votre place et c’est un IDE. Postman vous permet de tester vos API et Multipass nous donne la possibilité de lancer le côté serveur pour développement. (Pour les curieux.) | + | Et tout de suite, votre « client-side » (côté client) est configuré. Pycharm crée les VM Python à votre place et c’est un IDE. Postman vous permet de tester vos API et Multipass nous donne la possibilité de lancer le côté serveur pour du développement. (Pour les curieux.) |
+ | |||
+ | Mais si vous voulez connaître le meilleur, j’ai tout simplement refait tout dans une VM ! Je viens de créer une machine virtuelle avec un bureau Ubuntu par-dessus Linux Lite 6.6, qui, à son tour, exécute une VM sous Ubuntu server. Si vous êtes un n00b concernant tout cela, vous pourriez vous demander « mais qu’est-ce qu’il fume ? » | ||
- | Mais si vous voulez connaître le meilleur, j’ai tout simplement refait tout dans une VM ! Je viens de créer une Machine virtuelle avec un bureau Ubuntu par-dessus Linux Lite 6.6, qui, à son tour, exécute une VM sous Ubuntu server. Si vous êtes un n00b concernant tout cela, vous pourriez vous demander « mais qu’est-ce qu’il fume ? » | ||
**Let’s rewind. I don’t have a spare PC, to set it all up again, so I thought I’d do it in a VM, so I can vet myself and take screen-shots for you ugly lot. The thing with Ubuntu LTS is, that Virtualbox is version 6.1 in the official repositories and you will need version 7.0+ to follow along. (You will see why in a minute.) I just download the .deb-file from the website and installed it | **Let’s rewind. I don’t have a spare PC, to set it all up again, so I thought I’d do it in a VM, so I can vet myself and take screen-shots for you ugly lot. The thing with Ubuntu LTS is, that Virtualbox is version 6.1 in the official repositories and you will need version 7.0+ to follow along. (You will see why in a minute.) I just download the .deb-file from the website and installed it | ||
Ligne 25: | Ligne 27: | ||
Une fois terminé, dans Virtualbox, sous l’onglet CPU, il y a un paramètre que vous devez régler. System → Processeur → Enable Nested VT-x | Une fois terminé, dans Virtualbox, sous l’onglet CPU, il y a un paramètre que vous devez régler. System → Processeur → Enable Nested VT-x | ||
- | Il faut juste vous souvenir d’allouer assez de CPU pour cela. Le serveur dans la VM en aura besoin d’un, minimum, aussi. Installez le bureau Ubuntu comme d’habitude, | + | Il faut juste vous souvenir d’allouer assez de CPU pour cela. Le serveur dans la VM en aura besoin d’un minimum aussi. Installez le bureau Ubuntu comme d’habitude, |
**That installs the one half, but you will need a server to faff around on. We can quickly do so with Multipass. All we are going to need is a yaml file describing our server. I searched the web for multipass cloud-init-examples and stole that yaml file and edited it to my liking: | **That installs the one half, but you will need a server to faff around on. We can quickly do so with Multipass. All we are going to need is a yaml file describing our server. I searched the web for multipass cloud-init-examples and stole that yaml file and edited it to my liking: | ||
Ligne 50: | Ligne 53: | ||
Quoi qu’il en soit, pour le lancer, il suffit de taper ce qui suit là où le fichier cloud-config.yaml se trouve : | Quoi qu’il en soit, pour le lancer, il suffit de taper ce qui suit là où le fichier cloud-config.yaml se trouve : | ||
- | multipass launch -n newbuntu - -cloud-init cloud-config.yaml | + | multipass launch -n newbuntu --cloud-init cloud-config.yaml |
- | Cela lancera votre instance que nous avons appelé newbuntu et, en regardant l’icône orange dans la barre des tâches, ou simplement en vérifiant dans le terminal, vous devriez le voir tourner :* | + | Cela lancera votre instance que nous avons appelé newbuntu et, en regardant l’icône orange dans la barre des tâches, ou simplement en vérifiant dans le terminal, vous devriez le voir tourner : |
multipass list | multipass list | ||
+ | |||
**Take note of that IP address, as you would need it to ssh into. If you type it into your browser, you should see your Apache landing page. I will add a screen-shot (below) so you can see what I mean. | **Take note of that IP address, as you would need it to ssh into. If you type it into your browser, you should see your Apache landing page. I will add a screen-shot (below) so you can see what I mean. | ||
Ligne 68: | Ligne 72: | ||
Above you can see my VM running a VM (Ubuntu server) with htop open and I can write Python code in Pycharm. ** | Above you can see my VM running a VM (Ubuntu server) with htop open and I can write Python code in Pycharm. ** | ||
- | Notez l’adresse IP, car vous en aurez besoin pour y entrer avec ssh. Si vous le tapez dans votre navigateur, vous devez voir votre page d’atterrissage Apache. J’ajouterai | + | Notez l’adresse IP, car vous en aurez besoin pour y entrer avec ssh. Si vous la tapez dans votre navigateur, vous devez voir votre page d’atterrissage Apache. J’ajoute |
Alors, c’était si difficile que ça ? | Alors, c’était si difficile que ça ? | ||
- | Entrez dans la machine via ssh avec le nom d’utilisateur ubuntu et le mot de pass poopypants (couche plein de caca) comme indiqué dans notre fichier de configuration et acceptez l’empreinte | + | Entrez dans la machine via ssh avec le nom d’utilisateur ubuntu et le mot de pass poopypants (couche plein de caca) comme indiqué dans notre fichier de configuration et acceptez l’empreinte |
Alors, qu’est-ce qu’il y a à ne pas aimer ici ? Si vous et vos amis/ | Alors, qu’est-ce qu’il y a à ne pas aimer ici ? Si vous et vos amis/ | ||
Ligne 79: | Ligne 83: | ||
Ci-dessus, vous voyez ma VM exécutant une VM (Ubuntu server) ; htop est ouvert et je peux écrire du code Python dans Pycharm. | Ci-dessus, vous voyez ma VM exécutant une VM (Ubuntu server) ; htop est ouvert et je peux écrire du code Python dans Pycharm. | ||
- | |||
- | |||
- | |||
issue201/c_c.1706450021.txt.gz · Dernière modification : 2024/01/28 14:53 de auntiee