Unverified Commit b863b230 authored by Kubernetes Submit Queue's avatar Kubernetes Submit Queue Committed by GitHub

Merge pull request #67893 from juju-solutions/master

Automatic merge from submit-queue (batch tested with PRs 67942, 67893). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. Work on Juju charms:CSI, dyn config, cloud integration **What this PR does / why we need it**: This PR updates the Juju charms with fixes/additions regarding. CSI, cloud integration, dynamic configs and cdk-addons **Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*: Fixes # **Special notes for your reviewer**: **Release note**: ```release-note NONE ```
parents 42295cf9 7c2f5e32
...@@ -40,6 +40,38 @@ firewall rules may not be able to contact the Charm Store. In these network ...@@ -40,6 +40,38 @@ firewall rules may not be able to contact the Charm Store. In these network
restricted environments the resource can be uploaded to the model by the Juju restricted environments the resource can be uploaded to the model by the Juju
operator. operator.
#### Snap Refresh
The kubernetes resources used by this charm are snap packages. When not
specified during deployment, these resources come from the public store. By
default, the `snapd` daemon will refresh all snaps installed from the store
four (4) times per day. A charm configuration option is provided for operators
to control this refresh frequency.
>NOTE: this is a global configuration option and will affect the refresh
time for all snaps installed on a system.
Examples:
```sh
## refresh kubernetes-master snaps every tuesday
juju config kubernetes-master snapd_refresh="tue"
## refresh snaps at 11pm on the last (5th) friday of the month
juju config kubernetes-master snapd_refresh="fri5,23:00"
## delay the refresh as long as possible
juju config kubernetes-master snapd_refresh="max"
## use the system default refresh timer
juju config kubernetes-master snapd_refresh=""
```
For more information on the possible values for `snapd_refresh`, see the
*refresh.timer* section in the [system options][] documentation.
[system options]: https://forum.snapcraft.io/t/system-options/87
# Configuration # Configuration
This charm supports some configuration options to set up a Kubernetes cluster This charm supports some configuration options to set up a Kubernetes cluster
......
...@@ -147,6 +147,15 @@ options: ...@@ -147,6 +147,15 @@ options:
default: true default: true
description: | description: |
If true the metrics server for Kubernetes will be deployed onto the cluster. If true the metrics server for Kubernetes will be deployed onto the cluster.
snapd_refresh:
default: "max"
type: string
description: |
How often snapd handles updates for installed snaps. Setting an empty
string will check 4x per day. Set to "max" to delay the refresh as long
as possible. You may also set a custom string as described in the
'refresh.timer' section here:
https://forum.snapcraft.io/t/system-options/87
default-storage: default-storage:
type: string type: string
default: "auto" default: "auto"
......
...@@ -18,6 +18,8 @@ includes: ...@@ -18,6 +18,8 @@ includes:
- 'interface:aws-integration' - 'interface:aws-integration'
- 'interface:gcp-integration' - 'interface:gcp-integration'
- 'interface:openstack-integration' - 'interface:openstack-integration'
- 'interface:vsphere-integration'
- 'interface:azure-integration'
options: options:
basic: basic:
packages: packages:
......
...@@ -47,6 +47,10 @@ requires: ...@@ -47,6 +47,10 @@ requires:
interface: gcp-integration interface: gcp-integration
openstack: openstack:
interface: openstack-integration interface: openstack-integration
vsphere:
interface: vsphere-integration
azure:
interface: azure-integration
resources: resources:
kubectl: kubectl:
type: file type: file
......
...@@ -27,6 +27,38 @@ To add additional compute capacity to your Kubernetes workers, you may ...@@ -27,6 +27,38 @@ To add additional compute capacity to your Kubernetes workers, you may
join any related kubernetes-master, and enlist themselves as ready once the join any related kubernetes-master, and enlist themselves as ready once the
deployment is complete. deployment is complete.
## Snap Configuration
The kubernetes resources used by this charm are snap packages. When not
specified during deployment, these resources come from the public store. By
default, the `snapd` daemon will refresh all snaps installed from the store
four (4) times per day. A charm configuration option is provided for operators
to control this refresh frequency.
>NOTE: this is a global configuration option and will affect the refresh
time for all snaps installed on a system.
Examples:
```sh
## refresh kubernetes-worker snaps every tuesday
juju config kubernetes-worker snapd_refresh="tue"
## refresh snaps at 11pm on the last (5th) friday of the month
juju config kubernetes-worker snapd_refresh="fri5,23:00"
## delay the refresh as long as possible
juju config kubernetes-worker snapd_refresh="max"
## use the system default refresh timer
juju config kubernetes-worker snapd_refresh=""
```
For more information on the possible values for `snapd_refresh`, see the
*refresh.timer* section in the [system options][] documentation.
[system options]: https://forum.snapcraft.io/t/system-options/87
## Operational actions ## Operational actions
The kubernetes-worker charm supports the following Operational Actions: The kubernetes-worker charm supports the following Operational Actions:
...@@ -97,4 +129,3 @@ follow the same steps inversely. ...@@ -97,4 +129,3 @@ follow the same steps inversely.
``` ```
juju run --application kubernetes-worker close-port 30510 juju run --application kubernetes-worker close-port 30510
``` ```
...@@ -80,3 +80,29 @@ options: ...@@ -80,3 +80,29 @@ options:
description: | description: |
Docker image to use for the default backend. Auto will select an image Docker image to use for the default backend. Auto will select an image
based on architecture. based on architecture.
snapd_refresh:
default: "max"
type: string
description: |
How often snapd handles updates for installed snaps. Setting an empty
string will check 4x per day. Set to "max" to delay the refresh as long
as possible. You may also set a custom string as described in the
'refresh.timer' section here:
https://forum.snapcraft.io/t/system-options/87
kubelet-extra-config:
default: "{}"
type: string
description: |
Extra configuration to be passed to kubelet. Any values specified in this
config will be merged into a KubeletConfiguration file that is passed to
the kubelet service via the --config flag. This can be used to override
values provided by the charm.
Requires Kubernetes 1.10+.
The value for this config must be a YAML mapping that can be safely
merged with a KubeletConfiguration file. For example:
{evictionHard: {memory.available: 200Mi}}
For more information about KubeletConfiguration, see upstream docs:
https://kubernetes.io/docs/tasks/administer-cluster/kubelet-config-file/
...@@ -3,6 +3,7 @@ includes: ...@@ -3,6 +3,7 @@ includes:
- 'layer:basic' - 'layer:basic'
- 'layer:debug' - 'layer:debug'
- 'layer:snap' - 'layer:snap'
- 'layer:leadership'
- 'layer:docker' - 'layer:docker'
- 'layer:metrics' - 'layer:metrics'
- 'layer:nagios' - 'layer:nagios'
...@@ -15,6 +16,8 @@ includes: ...@@ -15,6 +16,8 @@ includes:
- 'interface:aws-integration' - 'interface:aws-integration'
- 'interface:gcp-integration' - 'interface:gcp-integration'
- 'interface:openstack-integration' - 'interface:openstack-integration'
- 'interface:vsphere-integration'
- 'interface:azure-integration'
- 'interface:mount' - 'interface:mount'
config: config:
deletes: deletes:
......
...@@ -36,6 +36,10 @@ requires: ...@@ -36,6 +36,10 @@ requires:
interface: gcp-integration interface: gcp-integration
openstack: openstack:
interface: openstack-integration interface: openstack-integration
vsphere:
interface: vsphere-integration
azure:
interface: azure-integration
nfs: nfs:
interface: mount interface: mount
provides: provides:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment