

Les traductions sont fournies par des outils de traduction automatique. En cas de conflit entre le contenu d'une traduction et celui de la version originale en anglais, la version anglaise prévaudra.

# Attributs haproxy
<a name="attributes-recipes-haproxy"></a>

**Important**  
Le AWS OpsWorks Stacks service a atteint sa fin de vie le 26 mai 2024 et a été désactivé tant pour les nouveaux clients que pour les clients existants. Nous recommandons vivement aux clients de migrer leurs charges de travail vers d'autres solutions dès que possible. Si vous avez des questions sur la migration, contactez l' AWS Support équipe sur [AWS Re:Post](https://repost.aws/) ou via le [AWS Support](https://aws.amazon.com/support) Premium.

**Note**  
Ces attributs ne sont disponibles que sur les piles Linux.

Les [`haproxy`attributs](https://github.com/aws/opsworks-cookbooks/blob/release-chef-11.10/haproxy/attributes/default.rb) spécifient la configuration [HAProxy du serveur](http://haproxy.1wt.eu/). Pour plus d'informations, consultez [HAProxyDocs](http://cbonte.github.io/haproxy-dconv/configuration-1.5.html). Pour plus d'informations sur la façon de remplacer les attributs intégrés afin de spécifier les valeurs personnalisées, consultez [Remplacement des attributs](workingcookbook-attributes.md).


****  

|  |  |  | 
| --- |--- |--- |
| [balance ](#attributes-recipes-haproxy-balance) | [check\$1interval ](#attributes-recipes-haproxy-interval) | [client\$1timeout ](#attributes-recipes-haproxy-client-timeout) | 
| [connect\$1timeout ](#attributes-recipes-haproxy-connect-timeout) | [default\$1max\$1connections ](#attributes-recipes-haproxy-default-max) | [global\$1max\$1connections ](#attributes-recipes-haproxy-global-max) | 
| [health\$1check\$1method ](#attributes-recipes-haproxy-health-method) | [health\$1check\$1url ](#attributes-recipes-haproxy-health-url) | [queue\$1timeout ](#attributes-recipes-haproxy-queue-timeout) | 
| [http\$1request\$1timeout ](#attributes-recipes-haproxy-http-timeout) | [maxcon\$1factor\$1nodejs\$1app ](#attributes-recipes-haproxy-nodejs-app) | [maxcon\$1factor\$1nodejs\$1app\$1ssl ](#attributes-recipes-haproxy-nodejs-ssl) | 
| [maxcon\$1factor\$1php\$1app ](#attributes-recipes-haproxy-php-app) | [maxcon\$1factor\$1php\$1app\$1ssl ](#attributes-recipes-haproxy-php-ssl) | [maxcon\$1factor\$1rails\$1app ](#attributes-recipes-haproxy-rails-app) | 
| [maxcon\$1factor\$1rails\$1app\$1ssl ](#attributes-recipes-haproxy-rails-ssl) | [maxcon\$1factor\$1static ](#attributes-recipes-haproxy-static-app) | [maxcon\$1factor\$1static\$1ssl ](#attributes-recipes-haproxy-static-ssl) | 
| [nouvelles tentatives ](#attributes-recipes-haproxy-retries) | [server\$1timeout ](#attributes-recipes-haproxy-server-timeout) | [stats\$1url ](#attributes-recipes-haproxy-stats-url) | 
| [stats\$1user ](#attributes-recipes-haproxy-user) |  |  | 

**balance **  <a name="attributes-recipes-haproxy-balance"></a>
Algorithme utilisé par un équilibreur de charge pour sélectionner un serveur (chaîne). La valeur par défaut est `'roundrobin'`. Les autres options sont :  
+ 'static-rr'
+ 'leastconn'
+ 'source'
+ 'uri'
+ 'url\$1param'
+ 'hdr(name)'
+ 'rdp-cookie'
+ 'rdp-cookie(name)'
Pour plus d'informations sur ces arguments, consultez [balance](http://cbonte.github.io/haproxy-dconv/configuration-1.5.html).  

```
node[:haproxy][:balance]
```

**check\$1interval **  <a name="attributes-recipes-haproxy-interval"></a>
Intervalle de la vérification du statut (chaîne). La valeur par défaut est `'10s'`.  

```
node[:haproxy][:check_interval]
```

**client\$1timeout **  <a name="attributes-recipes-haproxy-client-timeout"></a>
Durée maximale pendant laquelle un client peut être inactif (chaîne). La valeur par défaut est `'60s'`.  

```
node[:haproxy][:client_timeout]
```

**connect\$1timeout **  <a name="attributes-recipes-haproxy-connect-timeout"></a>
Durée maximale pendant laquelle HAProxy une tentative de connexion au serveur doit aboutir (chaîne). La valeur par défaut est `'10s'`.  

```
node[:haproxy][:connect_timeout]
```

**default\$1max\$1connections **  <a name="attributes-recipes-haproxy-default-max"></a>
Nombre maximal de connexions par défaut (chaîne). La valeur par défaut est `'80000'`.  

```
node[:haproxy][:default_max_connections]
```

**global\$1max\$1connections **  <a name="attributes-recipes-haproxy-global-max"></a>
Nombre maximal de connexions (chaîne). La valeur par défaut est `'80000'`.  

```
node[:haproxy][:global_max_connections]
```

**health\$1check\$1method **  <a name="attributes-recipes-haproxy-health-method"></a>
Méthode de vérification du statut (chaîne). La valeur par défaut est `'OPTIONS'`.  

```
node[:haproxy][:health_check_method]
```

**health\$1check\$1url **  <a name="attributes-recipes-haproxy-health-url"></a>
Chemin d'URL utilisé pour vérifier l'intégrité des serveurs (chaîne). La valeur par défaut est `'/'`.  

```
node[:haproxy][:health_check_url ]
```

**queue\$1timeout **  <a name="attributes-recipes-haproxy-queue-timeout"></a>
Durée d'attente maximale pour une connexion gratuite (chaîne). La valeur par défaut est `'120s'`.  

```
node[:haproxy][:queue_timeout]
```

**http\$1request\$1timeout **  <a name="attributes-recipes-haproxy-http-timeout"></a>
Durée maximale d'attente d' HAProxy une requête HTTP complète (chaîne). La valeur par défaut est `'30s'`.  

```
node[:haproxy][:http_request_timeout]
```

**nouvelles tentatives **  <a name="attributes-recipes-haproxy-retries"></a>
Nombre de tentatives après l'échec d'une connexion serveur (chaîne). La valeur par défaut est `'3'`.  

```
node[:haproxy][:retries]
```

**server\$1timeout **  <a name="attributes-recipes-haproxy-server-timeout"></a>
Durée maximale pendant laquelle un client peut être inactif (chaîne). La valeur par défaut est `'60s'`.  

```
node[:haproxy][:server_timeout]
```

**stats\$1url **  <a name="attributes-recipes-haproxy-stats-url"></a>
Chemin d'URL pour la page de statistiques (chaîne). La valeur par défaut est `'/haproxy?stats'`.  

```
node[:haproxy][:stats_url]
```

**stats\$1user **  <a name="attributes-recipes-haproxy-user"></a>
Nom d'utilisateur de la page de statistiques (chaîne). La valeur par défaut est `'opsworks'`.  

```
node[:haproxy][:stats_user]
```

Les `maxcon` attributs représentent un multiplicateur de facteur de charge utilisé pour calculer le nombre maximum de connexions autorisées pour HAProxy les [backends](attributes-json-opsworks-instance.md#attributes-json-opsworks-instance-backends). Par exemple, supposons que vous disposiez d'un serveur d'applications Rails sur une petite instance avec une `backend` valeur de 4, ce qui signifie que OpsWorks Stacks configurera quatre processus Rails pour cette instance. Si vous utilisez la `maxcon_factor_rails_app` valeur par défaut de 7, 28 (4\$17) connexions au serveur Rails HAProxy seront gérées.

**maxcon\$1factor\$1nodejs\$1app **  <a name="attributes-recipes-haproxy-nodejs-app"></a>
Facteur maxcon pour un serveur d'applications Node.js (nombre). La valeur par défaut est `10`.  

```
node[:haproxy][:maxcon_factor_nodejs_app]
```

**maxcon\$1factor\$1nodejs\$1app\$1ssl **  <a name="attributes-recipes-haproxy-nodejs-ssl"></a>
Facteur maxcon pour un serveur d'applications Node.js avec SSL (nombre). La valeur par défaut est `10`.  

```
node[:haproxy][:maxcon_factor_nodejs_app_ssl]
```

**maxcon\$1factor\$1php\$1app **  <a name="attributes-recipes-haproxy-php-app"></a>
Facteur maxcon pour un serveur d'applications PHP (nombre). La valeur par défaut est `10`.  

```
node[:haproxy][:maxcon_factor_php_app]
```

**maxcon\$1factor\$1php\$1app\$1ssl **  <a name="attributes-recipes-haproxy-php-ssl"></a>
Facteur maxcon pour un serveur d'applications PHP avec SSL (nombre). La valeur par défaut est `10`.  

```
node[:haproxy][:maxcon_factor_php_app_ssl]
```

**maxcon\$1factor\$1rails\$1app **  <a name="attributes-recipes-haproxy-rails-app"></a>
Facteur maxcon pour un serveur d'applications Rails (nombre). La valeur par défaut est `7`.  

```
node[:haproxy][:maxcon_factor_rails_app]
```

**maxcon\$1factor\$1rails\$1app\$1ssl **  <a name="attributes-recipes-haproxy-rails-ssl"></a>
Facteur maxcon pour un serveur d'applications Rails avec SSL (nombre). La valeur par défaut est `7`.  

```
node[:haproxy][:maxcon_factor_rails_app_ssl]
```

**maxcon\$1factor\$1static **  <a name="attributes-recipes-haproxy-static-app"></a>
Facteur maxcon pour un serveur web statique (nombre). La valeur par défaut est `15`.  

```
node[:haproxy][:maxcon_factor_static]
```

**maxcon\$1factor\$1static\$1ssl **  <a name="attributes-recipes-haproxy-static-ssl"></a>
Facteur maxcon pour un serveur web statique avec SSL (nombre). La valeur par défaut est `15`.  

```
node[:haproxy][:maxcon_factor_static_ssl]
```