issue198:c_c
Différences
Ci-dessous, les différences entre deux révisions de la page.
Prochaine révision | Révision précédente | ||
issue198:c_c [2023/10/28 15:57] – créée auntiee | issue198:c_c [2023/11/01 16:24] (Version actuelle) – andre_domenech | ||
---|---|---|---|
Ligne 1: | Ligne 1: | ||
- | So, after my proofreader had gotten through the last command and conquer paper, he said that he felt a little lost. | + | **So, after my proofreader had gotten through the last command and conquer paper, he said that he felt a little lost. |
While that article was intended to be a high level overview and get you interested in having your own web server to play with, so you can create your own web pages, web games or whatever, I will now go over some web server-speak; | While that article was intended to be a high level overview and get you interested in having your own web server to play with, so you can create your own web pages, web games or whatever, I will now go over some web server-speak; | ||
Ligne 9: | Ligne 9: | ||
distribution: | distribution: | ||
- | where “domain” is the name and “google.com” is the value, or “distribution” is the name and “Ubuntu” is the value. | + | where “domain” is the name and “google.com” is the value, or “distribution” is the name and “Ubuntu” is the value.** |
- | Context is a whole section in the configuration that contains directives. The directives in the section set configurations for that context. Clear as mud, eh? Back to our coding example, context is like a block of code, you can have other blocks of code nested within that specific block of code that affects only the enclosing block of code. The same with context. You can have context nested within context, that contain directives specific to that context. Still muddy, eh? Ok, think of paragraphs in a book, except here, whatever happens in that paragraph pertains only to that paragraph. For instance you read how they dig a well in that paragraph, that happens only in that paragraph; if, further in the book, you read about someone digging a well, it has nothing to do with the well that was dug earlier. Though, overall in the story or chapter, there are two wells dug, each paragraph about digging wells knows only about their specific well. Within the context or “paragraph” if I put in - | + | Bon. Après que mon relecteur ait réussi à terminer sa lecture du dernier article de C&C, il a dit qu'il se sentait un peu perdu. |
+ | |||
+ | Alors que cet article se voulait être une vue d' | ||
+ | |||
+ | La première chose que vous rencontrerez sera des directives et du « context ». Les directives sont des options spécifiques qui sont réglées dans le fichier de configuration (pas comme les directives arborescentes des robots dans les histoires d' | ||
+ | |||
+ | domain: google.com | ||
+ | |||
+ | distribution: | ||
+ | |||
+ | où « domain » est le nom et « google.com » est la valeur ou « distribution » est le nom et « Ubuntu » est la valeur. | ||
+ | |||
+ | **Context is a whole section in the configuration that contains directives. The directives in the section set configurations for that context. Clear as mud, eh? Back to our coding example, context is like a block of code, you can have other blocks of code nested within that specific block of code that affects only the enclosing block of code. The same with context. You can have context nested within context, that contain directives specific to that context. Still muddy, eh? Ok, think of paragraphs in a book, except here, whatever happens in that paragraph pertains only to that paragraph. For instance you read how they dig a well in that paragraph, that happens only in that paragraph; if, further in the book, you read about someone digging a well, it has nothing to do with the well that was dug earlier. Though, overall in the story or chapter, there are two wells dug, each paragraph about digging wells knows only about their specific well. Within the context or “paragraph” if I put in - | ||
distribution: | distribution: | ||
Ligne 21: | Ligne 33: | ||
it does not matter, as in that section we call the ‘context’, | it does not matter, as in that section we call the ‘context’, | ||
- | If it still is not clear, please send a message to misc@fullcirclemagazine.com | + | If it still is not clear, please send a message to misc@fullcirclemagazine.com** |
- | The main configuration file is named the “main context”. Don’t ask, I did not name these things. The main context (aka config file) contains global directives (aka settings) - do I need to bring up local and global variables? You have been following our Python tutorial, haven’t you? Global directives apply to the master process. | + | Context est toute une section de la configuration qui contient des directives. Les directives dans la section règlent les configurations pour ce context. Aussi limpide que de l'eau trouble, non ? De retour à notre exemple de codage : context est comme un bloc de code. Vous pouvez avoir d' |
+ | |||
+ | distribution: | ||
+ | |||
+ | puis dans un autre context « paragraphe », je peux mettre : | ||
+ | |||
+ | distribution: | ||
+ | |||
+ | cela n'a aucune importance, car dans cette section que nous appelons le « context », la paire clé-valeur que nous appelons la « directive », n'a trait qu'à ce « context » précis. | ||
+ | |||
+ | Si cela n'est toujours pas clair, veuillez envoyer un message à misc@fullcirclemagazine.com | ||
+ | |||
+ | |||
+ | **The main configuration file is named the “main context”. Don’t ask, I did not name these things. The main context (aka config file) contains global directives (aka settings) - do I need to bring up local and global variables? You have been following our Python tutorial, haven’t you? Global directives apply to the master process. | ||
As I said before, context can be nested, I will highlight a few important ones, so, within the main context, you will find, for instance, the ‘server context’ (where we defined our virtual host). We also have the ‘http context’, for http-related configurations and location context, to match requests incoming to the correct server context. | As I said before, context can be nested, I will highlight a few important ones, so, within the main context, you will find, for instance, the ‘server context’ (where we defined our virtual host). We also have the ‘http context’, for http-related configurations and location context, to match requests incoming to the correct server context. | ||
Ligne 33: | Ligne 58: | ||
Do you see where this jargon is used? This also tells us where you can find the directives you are looking for (~~hand wavy~~ These are not the ‘droids’ you are looking for!). | Do you see where this jargon is used? This also tells us where you can find the directives you are looking for (~~hand wavy~~ These are not the ‘droids’ you are looking for!). | ||
- | This is very important, it helps us not only read the documentation correctly, but it also helps us find where our directive should go (shown below). | + | This is very important, it helps us not only read the documentation correctly, but it also helps us find where our directive should go (shown below).** |
+ | |||
+ | Le fichier principal de configuration se nomme le « main context ». Ne me posez pas de question, c'est pas moi qui a nommé ces choses. Le main context (alias le fichier config) contient des directives globales (alias paramètres) - ai-je besoin de parler de variables locales et globales ? Vous suivez le tutoriel de Python, n' | ||
+ | |||
+ | Comme j'ai dit auparavant, context peut être imbriqué. Je vais en souligner quelques-uns qui sont importants : ainsi à l' | ||
+ | |||
+ | Naviguez ici : | ||
+ | https:// | ||
+ | (voir l' | ||
+ | |||
+ | Vous voyez l' | ||
+ | |||
+ | C'est très important : il nous aide non seulement à lire la documentation comme il faut, mais aussi à trouver où on doit mettre notre directive (voir ci-dessous). | ||
+ | |||
+ | |||
+ | **If we look at the first example, we will find the context says it is in http, server and location, whereas merge_slashes is not found in “location”. Having it in a context where it does not belong, will mean it has no effect. If I have the above configuration in “location” context, it will not affect the “http” context even though they are both in the main context. | ||
+ | |||
+ | I hope this has cleared up some of the confusing bits in the series, so if I ever talk about context again while talking about web servers, I mean this ^^^, not some random context or in the context of the article. Have fun with your web servers! ** | ||
+ | |||
+ | Si nous examinons le premier exemple, nous verrons que le context dit qu'il se trouve dans http, server et location, alors que merge_slashes n'est pas trouvé dans « location ». S'il est placé dans un context impropre, cela signifiera qu'il n'aura aucun effet. Si j'ai la configuration ci-dessus dans le context « location », cela n' | ||
- | If we look at the first example, we will find the context says it is in http, server and location, whereas merge_slashes is not found in “location”. Having it in a context where it does not belong, will mean it has no effect. If I have the above configuration in “location” | + | J' |
- | I hope this has cleared up some of the confusing bits in the series, so if I ever talk about context again while talking about web servers, I mean this ^^^, not some random context or in the context of the article. Have fun with your web servers! |
issue198/c_c.1698501471.txt.gz · Dernière modification : 2023/10/28 15:57 de auntiee