-
Notifications
You must be signed in to change notification settings - Fork 152
Add documentation for managing ECK file-based password length. #3322
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -62,7 +62,6 @@ | |||||
If you are using the `elastic` user credentials in your own applications, they will fail to connect to {{es}} and {{kib}} after you run this command. It is not recommended to use `elastic` user credentials for production use cases. Always [create your own users with restricted roles](../../../deploy-manage/users-roles/cluster-or-deployment-auth/native.md) to access {{es}}. | ||||||
:::: | ||||||
|
||||||
|
||||||
To regenerate all auto-generated credentials in a namespace, run the following command: | ||||||
|
||||||
```sh | ||||||
|
@@ -99,4 +98,82 @@ | |||||
|
||||||
ECK facilitates file-based role management through Kubernetes secrets containing the roles specification. Alternatively, you can use the Role management API or the Role management UI in {{kib}}. | ||||||
|
||||||
Refer to [Managing custom roles](/deploy-manage/users-roles/cluster-or-deployment-auth/defining-roles.md#managing-custom-roles) for details and ECK based examples. | ||||||
## Controlling the length of ECK-generated passwords | ||||||
|
||||||
```{applies_to} | ||||||
eck: ga 3.2 | ||||||
``` | ||||||
|
||||||
With an enterprise license users can control the password length of the file-based passwords generated by {{eck}}. | ||||||
|
||||||
:::{note} | ||||||
In {{eck}} 3.1 and earlier all file-based passwords are 24 characters long. | ||||||
::: | ||||||
|
||||||
### Controlling the length of passwords in Helm installations | ||||||
|
||||||
If you installed {{eck}} through the Helm chart commands listed in [](../../deploy/cloud-on-k8s/install-using-helm-chart.md), you can set `config.policies.passwords.length` to control the length of generated file-based passwords. | ||||||
|
||||||
For example: | ||||||
```shell | ||||||
helm upgrade -i eck-operator -n elastic-system --set=config.policies.passwords.length=64 | ||||||
``` | ||||||
|
||||||
This will cause any new file-based passwords that are generated to be a length of 64. | ||||||
|
||||||
::: {note} | ||||||
This will not cause existing passwords to be changed. To change existing password refer to [Rotating credentials](k8s-rotate-credentials) | ||||||
Check failure on line 125 in deploy-manage/users-roles/cluster-or-deployment-auth/managed-credentials-eck.md
|
||||||
::: | ||||||
|
||||||
### Using the operator manifests | ||||||
|
||||||
If you installed ECK through using the manifests using the commands listed in [](../../deploy/cloud-on-k8s/install-using-yaml-manifest-quickstart.md), some additional changes are required to control password length. | ||||||
|
||||||
1. Set the `password-length` in the `ConfigMap`. | ||||||
|
||||||
```yaml | ||||||
cat <<EOF | kubectl apply -f - | ||||||
kind: ConfigMap | ||||||
apiVersion: v1 | ||||||
metadata: | ||||||
name: elastic-operator | ||||||
namespace: elastic-system | ||||||
data: | ||||||
eck.yaml: |- | ||||||
log-verbosity: 0 | ||||||
metrics-port: 0 | ||||||
metrics-secure: false | ||||||
container-registry: docker.elastic.co | ||||||
max-concurrent-reconciles: 3 | ||||||
ca-cert-validity: 8760h | ||||||
ca-cert-rotate-before: 24h | ||||||
cert-validity: 8760h | ||||||
cert-rotate-before: 24h | ||||||
disable-config-watch: false | ||||||
exposed-node-labels: [topology.kubernetes.io/.*,failure-domain.beta.kubernetes.io/.*] | ||||||
set-default-security-context: auto-detect | ||||||
kube-client-timeout: 60s | ||||||
elasticsearch-client-timeout: 180s | ||||||
disable-telemetry: false | ||||||
distribution-channel: all-in-one | ||||||
validate-storage-class: true | ||||||
enable-webhook: false | ||||||
operator-namespace: elastic-system | ||||||
enable-leader-election: true | ||||||
elasticsearch-observation-interval: 10s | ||||||
ubi-only: false | ||||||
password-legnth: 64 | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
Maybe just update the example in https://www.elastic.co/docs/deploy-manage/deploy/cloud-on-k8s/configure-eck instead. |
||||||
EOF | ||||||
``` | ||||||
|
||||||
2. Restart the ECK operator | ||||||
|
||||||
```shell | ||||||
kubectl delete pod -n elastic-system elastic-operator-0 | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Operator will auto restart when its configuration changes |
||||||
``` | ||||||
|
||||||
This will cause any new file-based passwords that are generated to be a length of 64. | ||||||
|
||||||
::: {note} | ||||||
This will not cause existing passwords to be changed. To change existing password refer to [Rotating credentials](k8s-rotate-credentials) | ||||||
Check failure on line 178 in deploy-manage/users-roles/cluster-or-deployment-auth/managed-credentials-eck.md
|
||||||
::: |
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Did you base this on a branch with unmerged commits. This seems unrelated. |
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same here: accidentally included? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This feels like it is duplicating https://www.elastic.co/docs/deploy-manage/deploy/cloud-on-k8s/configure-eck.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would probably just mention the Helm value and ECK config flag and link to the existing docs on how to update it.