diff --git a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/centralize_logs.md b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/centralize_logs.md index 2c996d0853..798003596c 100644 --- a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/centralize_logs.md +++ b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/centralize_logs.md @@ -109,6 +109,59 @@ To configure log rotation and retention, you must patch your Automate configurat After you patch the Automate configuration, Automate saves and rotates the log files in the location specified in `redirect_log_file_path`. +## Configure Rate Limiter + +To configure Rate Limiter, you must patch your Automate configuration. + +1. Create a TOML file with the following content on the node running Chef Automate in a standalone deployment or on the bastion host in an Automate HA cluster: + + ```toml + [global.v1.log] + redirect_sys_log = true + redirect_log_file_path = "" + rate_limit_interval = 600 + rate_limit_burst = 20000 + ``` + + Set the following values: + + - `redirect_sys_log`: Whether to save the system logs to a file. Set to `true` to save to a file. Default value: `false`. + - `redirect_log_file_path`: The path to the directory that you want to save the Automate log to. This value is required if `redirect_sys_log` is `true`. + - `rate_limit_interval`: This defines the time interval for rate-limiting in seconds. For example, if it's set to 600s, rsyslog will track messages within each 600-second window. The default value will be the same as the `rsyslog` default value, which is `600` [rsyslog Page](https://www.rsyslog.com/doc/configuration/modules/imjournal.html#ratelimit-interval). + - `rate_limit_burst`: This sets the maximum number of messages allowed within the interval defined by rate_limit_interval. If more messages are received within the interval, they will be temporarily suppressed to avoid spamming the rsyslog. The default value will be the same as the `rsyslog` default value, which is `20000` [rsyslog Page](https://www.rsyslog.com/doc/configuration/modules/imjournal.html#ratelimit-burst). + + {{< note >}} + + - Changing the `rate_limit_burst` or `rate_limit_interval` value will configure both journald and rsyslog settings as well. + - The default values for RateLimitInterval and RateLimitBurst in `journald` are 30 seconds and 10,000 messages, respectively. + - In `rsyslog`, the default values for RateLimitInterval and RateLimitBurst are 600 seconds and 20,000 messages, respectively. + + {{< /note >}} + + {{< warning >}} + Enabling this configuration may lead to increased disk utilization. + {{< /warning >}} + +1. Patch the Chef Automate configuration. + + To patch a standalone Chef Automate node or Chef Automate HA nodes in a cluster: + + ```bash + sudo chef-automate config patch + ``` + + To patch OpenSearch nodes in Chef Automate HA cluster: + + ```bash + chef-automate config patch --opensearch + ``` + + To patch PostgreSQL nodes in Chef Automate HA cluster: + + ```bash + chef-automate config patch --postgresql + ``` + ## Centralize all node logs to one location You can configure all nodes in a Chef Automate HA cluster to save log files to one log location. diff --git a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/chef_automate_license.md b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/chef_automate_license.md index 53cb46f73f..0a79e1e992 100644 --- a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/chef_automate_license.md +++ b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/chef_automate_license.md @@ -15,9 +15,15 @@ Before running Chef Automate, you must accept the Chef EULA. Chef Automate offers two license tiers that have different entitlements: -* **Trial:** A trial license is for users or organizations interested in exploring the product before buying. +* **Trial:** A trial license is for users or organizations interested in exploring the product before buying. Generate the license from https://www.chef.io/license-generation-free-trial * **Commercial:** A commercial license is for customers who have purchased and are entitled to use it according to the license terms. +{{< warning >}} + +The Chef Server deployed and running with Automate will also require a license. The Chef Automate license will cover the Chef Server license. + +{{< /warning >}} + Chef Automate is built around a web user interface that provides visibility into all aspects of your infrastructure. The licensing types will affect your UI journey. For more information on Chef licenses, see [Chef licensing documentation](https://docs.chef.io/licensing/). @@ -104,3 +110,10 @@ You cannot use Chef Automate features and capabilities. To continue using Chef A 1. [Contact us](https://www.chef.io/contact-us) to get a license. 1. If you already have a license key, paste it in the popup box and check the I agree to the Terms and Service box. 1. Select **Apply License**. + +## Chef Server under Automate License + +Chef Server, when deployed with Automat,e will abide by the Automate license. + +The `chef-server-ctl` command will not work if the commercial/trial license has not been applied to Automate or has expired. In the case of `knife` or `Infra Client` execution, the Chef Server will not respond if the Automate license has not been applied or expired. + \ No newline at end of file diff --git a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/configuration.md b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/configuration.md index 482ae5476b..454fdd7e02 100644 --- a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/configuration.md +++ b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/configuration.md @@ -121,6 +121,17 @@ key = """-----BEGIN RSA PRIVATE KEY----- Then run `chef-automate config patch ` to deploy your change. +### Include X-Forwarded-For Header + +To log the source node IP address in Automate Load Balancer and Chef Server Load Balancer, the following configuration needs to be patched: + +```toml +[global.v1.sys.ngx.http] + include_x_forwarded_for = true +``` +Then run `chef-automate config patch ` to deploy your change. +The Automate Load Balancer and Chef Server Load Balancer will log the content of the `X-Forwarded-For` header data. + #### License Key You can apply for your Chef Automate license with the `chef-automate license apply` command in one of two ways: diff --git a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_aws_deployment_prerequisites.md b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_aws_deployment_prerequisites.md index abe15a4c2b..58474b3c17 100644 --- a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_aws_deployment_prerequisites.md +++ b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_aws_deployment_prerequisites.md @@ -89,7 +89,8 @@ Current Automate HA integrates with the following non-Chef tools: - Refer to [Performance Benchmarks](/automate/ha_performance_benchmarks) for more details on the hardware requirements. - Make sure the hardware requirement in not lesser than the recommended [Minimum Hardware Requirement](/automate/ha_aws_deployment_prerequisites/#minimum-hardware-requirement) - Contact your network manager to set up the above pre-requisites. - +- We recommended that all hardware/VMs be in the same region/data center. + {{< /note >}} ### Minimum Hardware Requirement diff --git a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_backup_restore_aws_efs.md b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_backup_restore_aws_efs.md index 0dcc338aec..7c2674adfa 100644 --- a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_backup_restore_aws_efs.md +++ b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_backup_restore_aws_efs.md @@ -64,6 +64,11 @@ Configure the OpenSearch `path.repo` attribute. - Above command will restart the OpenSearch cluster. #### Healthcheck commands +- Get the OpenSearch Cluster status + + ```sh + chef-automate status --os + ``` - Following command can be run in the OpenSearch node diff --git a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_chef_backend_to_automate_ha.md b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_chef_backend_to_automate_ha.md index 9b95a60237..05d6840764 100644 --- a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_chef_backend_to_automate_ha.md +++ b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_chef_backend_to_automate_ha.md @@ -51,7 +51,7 @@ Check the [AWS Deployment Prerequisites](/automate/ha_aws_deployment_prerequisit 2. Execute the below command to install the habitat package for `knife-ec-backup` ```sh - hab pkg install chef/knife-ec-backup + hab pkg install chef/knife-ec-backup -bf ``` 3. Execute the below command to generate a knife tidy server report to examine the stale node, data, etc. diff --git a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_disaster_recovery_setup.md b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_disaster_recovery_setup.md index 273bf982c0..5beccaa7e0 100644 --- a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_disaster_recovery_setup.md +++ b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_disaster_recovery_setup.md @@ -126,10 +126,11 @@ Configure backups for both clusters using either [file system](/automate/ha_back password = "admin" ``` - - Stop all the services on all Automate and Chef Infra frontend nodes using the following command: + - Stop all the services on all Automate and Chef Infra frontend nodes using the following command, use the below command from the bastion. ```sh - systemctl stop chef-automate + chef-automate systemctl --a2 + chef-automate systemctl --cs ``` - In the disaster recovery cluster, use the following sample command to restore the latest backup from any Chef Automate frontend instance. diff --git a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_existing_a2ha_to_automate_ha.md b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_existing_a2ha_to_automate_ha.md index af67c45f1c..72843f8377 100644 --- a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_existing_a2ha_to_automate_ha.md +++ b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_existing_a2ha_to_automate_ha.md @@ -79,11 +79,10 @@ done 1. Configure the backup at Automate HA cluster. If you have not configured it, please refer to this [Doc: Pre Backup Configuration for File System Backup](/automate/ha_backup_restore_file_system/#setting-up-the-backup-configuration) -1. From Step 3, you will get the backup mount path. +1. From the above Step, you will get the backup mount path. -1. Stop all the services at frontend nodes in Automate HA Cluster. - -1. Get the Automate version from the location `/var/tmp/` in Automate instance. Example: `frontend-4.x.y.aib`. +1. To run the restore command, we need the airgap bundle. Get the Automate HA airgap bundle from the location `/var/tmp/` in Automate instance. Example: `frontend-4.x.y.aib`. + - In case of airgap bundle is not present at `/var/tmp`, in that case, we can copy the bundle from the bastion node to the Automate node. 1. Run the command at the Chef-Automate node of Automate HA cluster to get the applied config: @@ -97,18 +96,9 @@ done sudo chef-automate stop ``` -1. To run the restore command, we need the airgap bundle. Get the Automate HA airgap bundle from the location `/var/tmp/` in Automate instance. Example: `frontend-4.x.y.aib`. - - In case of airgap bundle is not present at `/var/tmp`, in that case, we can copy the bundle from the bastion node to the Automate node. - -1. Run the command at the Chef-Automate node of Automate HA cluster to get the applied config - - ```bash - sudo chef-automate config show > current_config.toml - ``` - 1. Add the OpenSearch credentials to the applied config. - - If using Chef Managed OpenSearch, add the config below into `current_config.toml` (without any changes). + - If using Chef Managed OpenSearch, add the config below into `current_config.toml` (unless you have changed the credentials). ```bash [global.v1.external.opensearch.auth.basic_auth] @@ -136,14 +126,14 @@ done {{% automate/char-warn %}} {{< /warning >}} -```bash -[global.v1.external.opensearch.auth] - scheme = "aws_os" -[global.v1.external.opensearch.auth.aws_os] - username = "THIS YOU GET IT FROM AWS Console" - password = "THIS YOU GET IT FROM AWS Console" - access_key = "" - secret_key = "" +```sh + [global.v1.external.opensearch.auth] + scheme = "aws_os" + [global.v1.external.opensearch.auth.aws_os] + username = "THIS YOU GET IT FROM AWS Console" + password = "THIS YOU GET IT FROM AWS Console" + access_key = "" + secret_key = "" ``` 1. Copy the `bootstrap.abb` bundle to all the Frontend nodes of the Chef Automate HA cluster. Unpack the bundle using the below command on all the Frontend nodes. @@ -151,25 +141,26 @@ done ```sh sudo chef-automate bootstrap bundle unpack bootstrap.abb ``` -2. Stop the Service in all the frontend nodes with the below command. + +1. Stop the Service in all the frontend nodes with the below command. ``` bash sudo chef-automate stop ``` -3. To restore the A2HA backup on Chef Automate HA, run the following command from any Chef Automate instance of the Chef Automate HA cluster: +1. To restore the A2HA backup on Chef Automate HA, run the following command from any Chef Automate instance of the Chef Automate HA cluster: ```sh sudo chef-automate backup restore /mnt/automate_backups/backups/20210622065515/ --patch-config current_config.toml --airgap-bundle /var/tmp/frontend-4.x.y.aib --skip-preflight ``` -4. After successfully executing the restore, you will see the below message: +1. After successfully executing the restore, you will see the below message: ```bash Success: Restored backup 20210622065515 ``` -5. Start the Service in all the frontend nodes with the below command. +1. Start the Service in all the frontend nodes with the below command. ``` bash sudo chef-automate start diff --git a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_inplace_migration.md b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_inplace_migration.md index 195e686667..e2c6bf5131 100644 --- a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_inplace_migration.md +++ b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_inplace_migration.md @@ -190,7 +190,7 @@ OR chef-automate config show > applied_config.toml ``` -Modify `applied_config.toml`, remove the elastic search config, and set the config. Set `applied_config.toml` on all the frontend nodes manually. As the removal of config is not supported from the bastion. Use the below command to set the config manually. +Modify `applied_config.toml`, remove the elastic search config, and set the config. Set `applied_config.toml` on all the frontend nodes manually. As the removal of config is not supported from the bastion. Use the below command to set the config manually on each Frontend node. ```bash chef-automate config set applied_config.toml diff --git a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_on_premises_deployment_prerequisites.md b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_on_premises_deployment_prerequisites.md index 952cffb18d..401294facd 100644 --- a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_on_premises_deployment_prerequisites.md +++ b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/ha_on_premises_deployment_prerequisites.md @@ -87,7 +87,7 @@ Current Automate HA integrates with the following non-Chef tools: - Refer to [Performance Benchmarks](/automate/ha_performance_benchmarks) for more details on the hardware requirements. - Make sure the hardware requirement is not less than the recommended [Minimum Hardware Requirement](/automate/ha_on_premises_deployment_prerequisites/#minimum-hardware-requirement) - Contact your network manager to set up the above pre-requisites. - +- We recommended that all the hardware/VMs be in the same region/data center. {{< /note >}} ### Minimum Hardware Requirement diff --git a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/infra_server.md b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/infra_server.md index 1e08f04085..ebdda96d23 100644 --- a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/infra_server.md +++ b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/infra_server.md @@ -27,6 +27,12 @@ with Chef Automate. {{< /warning >}} +{{< warning >}} + +The Chef Server deployed and running with Automate will also require a license. The Chef Automate license will cover the Chef Server license. + +{{< /warning >}} + Use Chef Automate to install Chef Infra Server either for a single-host installation that contains both Chef Infra Server and Chef Automate, or for a standalone Chef Infra Server instance. See the [Chef Infra Server documentation]({{< relref "server.md" >}}) for instructions and guidance on using and managing your Chef Infra Server. @@ -241,7 +247,15 @@ The [`knife` command-line utility]({{< relref "workstation/knife.md" >}}) provid On the Chef Infra Server host: -1. Run the following command to create a user: +1. Apply License: + Chef Automate offers two license tiers that have different entitlements: + **Trial:** A trial license is for users or organizations interested in exploring the product before buying. Generate the license from https://www.chef.io/license-generation-free-trial + **Commercial:** A commercial license is for customers who have purchased and are entitled to use it according to the license terms. + + If you do not have the license, you can use the trial license to explore the product or contact the Chef Account Team to get a commercial license. + Please follow the instructions in the [Chef Automate License]({{< relref "chef_automate_license.md" >}}) documentation to apply for the license. + +2. Run the following command to create a user: ```shell sudo chef-server-ctl user-create USER_NAME FIRST_NAME LAST_NAME EMAIL 'PASSWORD' --filename USER_NAME.pem @@ -251,7 +265,7 @@ On the Chef Infra Server host: Save this RSA private key to a safe location. The `--filename` option will save the RSA private key to the specified absolute path. -1. Run the following command to create an organization, generate its validator key, and assign the user created in the previous step as an administrator: +3. Run the following command to create an organization, generate its validator key, and assign the user created in the previous step as an administrator: ```shell sudo chef-server-ctl org-create SHORT_NAME 'FULL_ORGANIZATION_NAME' --association_user USER_NAME --filename ORGANIZATION-validator.pem diff --git a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/log_management.md b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/log_management.md index 4903ba7407..decab7ec58 100644 --- a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/log_management.md +++ b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/log_management.md @@ -46,6 +46,29 @@ level = "debug" Then run `chef-automate config patch ` to deploy your change. + ## Configuring Log Rotation and Retention Log rotation and retention settings are managed at a system level using `journald`. At this point, `journald` does not support log retention policies at a granular level for units within itself. See the [man page](https://www.freedesktop.org/software/systemd/man/journald.conf.html) for more configuration options in `/etc/systemd/journald.conf`. + + +## Configuring Rate Limiter + +The rate limiter is used to control the volume of log messages that are written to the journal. You can configure Rate Limiter by creating a TOML file. + +```shell +[global.v1.log] +rate_limit_interval = 30 +rate_limit_burst = 10000 +``` + +Then run `chef-automate config patch ` to deploy your change. + +Set the following values: + +- `rate_limit_interval`: This defines the time interval for rate-limiting in seconds. For example, if it's set to 30s, journald will track messages within each 30-seconds window. Default value will be same as the `journald` default value, which is `30` [Journal Page](https://www.freedesktop.org/software/systemd/man/latest/journald.conf.html#RateLimitIntervalSec=). +- `rate_limit_burst`: This sets the maximum number of messages allowed within the interval defined by rate_limit_interval. If more messages are received within the interval, they will be temporarily suppressed to avoid spamming the journal. Default value will be same as the `journald` default value, which is `10000` [Journal Page](https://www.freedesktop.org/software/systemd/man/latest/journald.conf.html#RateLimitIntervalSec=). + +{{< warning >}} +By enabling this configuration it may lead to increasing disk utilization. +{{< /warning >}} \ No newline at end of file diff --git a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/reusable/md/opensearch_health_check.md b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/reusable/md/opensearch_health_check.md index 0e71846815..352fc4399d 100644 --- a/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/reusable/md/opensearch_health_check.md +++ b/_vendor/github.com/chef/automate/components/docs-chef-io/content/automate/reusable/md/opensearch_health_check.md @@ -1,5 +1,11 @@ Use the following commands on OpenSearch nodes to verify their health status. +1. Get the OpenSearch Cluster status from the bastion + + ```sh + chef-automate status --os + ``` + 1. Verify that the Habitat service is running. ```sh diff --git a/_vendor/modules.txt b/_vendor/modules.txt index 6bc09b7169..572a9970bd 100644 --- a/_vendor/modules.txt +++ b/_vendor/modules.txt @@ -1,4 +1,4 @@ -# github.com/chef/automate/components/docs-chef-io v0.0.0-20240926130942-4b98d9cf92f6 +# github.com/chef/automate/components/docs-chef-io v0.0.0-20241202053455-d6fa3db8941a # github.com/chef/desktop-config/docs-chef-io v0.0.0-20240814044820-5af667d41a43 # github.com/habitat-sh/habitat/components/docs-chef-io v0.0.0-20241119140456-8605fc35e9b2 # github.com/chef/chef-server/docs-chef-io v0.0.0-20241126093050-948ceb81afae diff --git a/go.mod b/go.mod index ff4a1fbd75..b535904066 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,7 @@ module github.com/chef/chef-web-docs go 1.22 require ( - github.com/chef/automate/components/docs-chef-io v0.0.0-20240926130942-4b98d9cf92f6 // indirect + github.com/chef/automate/components/docs-chef-io v0.0.0-20241202053455-d6fa3db8941a // indirect github.com/chef/chef-docs-theme v0.0.0-20241119200251-e9924c9d1278 // indirect github.com/chef/chef-server/docs-chef-io v0.0.0-20241126093050-948ceb81afae // indirect github.com/chef/chef-workstation/docs-chef-io v0.0.0-20240809064339-878cb76b2b66 // indirect diff --git a/go.sum b/go.sum index 276bb0cfec..28994e5485 100644 --- a/go.sum +++ b/go.sum @@ -1,5 +1,5 @@ -github.com/chef/automate/components/docs-chef-io v0.0.0-20240926130942-4b98d9cf92f6 h1:scrWEAK18Peqbtc3CxwxVaFp595kr+r8eYvYxW7qjQU= -github.com/chef/automate/components/docs-chef-io v0.0.0-20240926130942-4b98d9cf92f6/go.mod h1:juvLC7Rt33YOCgJ5nnfl4rWZRAbSwqjTbWmcAoA0LtU= +github.com/chef/automate/components/docs-chef-io v0.0.0-20241202053455-d6fa3db8941a h1:EzM6PeCHWg2y1XcXr4axYo/tXmfaYHWjTBX6cAiCaJI= +github.com/chef/automate/components/docs-chef-io v0.0.0-20241202053455-d6fa3db8941a/go.mod h1:juvLC7Rt33YOCgJ5nnfl4rWZRAbSwqjTbWmcAoA0LtU= github.com/chef/chef-docs-theme v0.0.0-20241119200251-e9924c9d1278 h1:m8AMAMs3n5s709tRYnDzNcx8jCqxzCwDUSfftaVbs7g= github.com/chef/chef-docs-theme v0.0.0-20241119200251-e9924c9d1278/go.mod h1:+Jpnv+LXE6dXu2xDcMzMc0RxRGuCPAoFxq5tJ/X6QpQ= github.com/chef/chef-server/docs-chef-io v0.0.0-20241126093050-948ceb81afae h1:ml5zs10Wv+YgJSq5zLlyLroTcP2x1U4Op/whIpVr14s=