Skip to content
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

generic ephemeral volume beta #99643

Merged
merged 5 commits into from Mar 10, 2021

Commits on Mar 9, 2021

  1. Configuration menu
    Copy the full SHA
    dcce753 View commit details
    Browse the repository at this point in the history
  2. generic ephemeral volumes: drop ReadOnly field

    As discussed during the alpha review, the ReadOnly field is not really
    needed because volume mounts can also be read-only. It's a historical
    oddity that can be avoided for generic ephemeral volumes as part
    of the promotion to beta.
    pohly committed Mar 9, 2021
    Configuration menu
    Copy the full SHA
    555d4a1 View commit details
    Browse the repository at this point in the history
  3. generic ephemeral volume: generate code

    This is the result of "make update" minus the testdata update which
    will be committed separately.
    pohly committed Mar 9, 2021
    Configuration menu
    Copy the full SHA
    52b758c View commit details
    Browse the repository at this point in the history
  4. testdata: drop the alpha EphemeralVolumeSource.ReadOnly field

    This is the result of
       UPDATE_COMPATIBILITY_FIXTURE_DATA=true go test k8s.io/api
    after removing the ReadOnly field from the API. The test data
    for older releases must be updated because the current code
    no longer supports that field.
    
    The removal itself is okay because the struct was declared
    as alpha.
    
    Because EphemeralVolumeSource is embedded quite a lot, different types
    are affected. Here is one example:
    
           --- FAIL: TestCompatibility/extensions.v1beta1.DaemonSet/v1.20.0 (0.04s)
                compatibility.go:476: json differs
                compatibility.go:477:   string{
                      	... // 12941 identical bytes
                      	0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, //  |               }|
                      	0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, //  |.              }|
                    - 	0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, // -|,.              |
                    - 	0x22, 0x72, 0x65, 0x61, 0x64, 0x4f, 0x6e, 0x6c, 0x79, 0x22, 0x3a, 0x20, 0x74, 0x72, 0x75, 0x65, // -|"readOnly": true|
                      	0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, //  |.            }. |
                      	0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, //  |         }.     |
                      	... // 31426 identical bytes
                      }
    
                compatibility.go:482: yaml differs
                compatibility.go:483:   string{
                      	... // 22893 identical bytes
                      	0x34, 0x22, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x65, 0x70, 0x68, 0x65, 0x6d, //  |4".        ephem|
                      	0x65, 0x72, 0x61, 0x6c, 0x3a, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, //  |eral:.          |
                    - 	0x72, 0x65, 0x61, 0x64, 0x4f, 0x6e, 0x6c, 0x79, 0x3a, 0x20, 0x74, 0x72, 0x75, 0x65, 0x0a, 0x20, // -|readOnly: true. |
                    - 	0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,                                           // -|         |
                      	0x76, 0x6f, 0x6c, 0x75, 0x6d, 0x65, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x54, 0x65, 0x6d, 0x70, 0x6c, //  |volumeClaimTempl|
                      	0x61, 0x74, 0x65, 0x3a, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, //  |ate:.           |
                      	... // 5965 identical bytes
                      }
    
                compatibility.go:488: proto differs
                compatibility.go:490:   (
                      	"""
                      	... // 459 identical lines
                      	                }
                      	              }
                    - 	              2: 1
                      	            }
                      	          }
                      	... // 1083 identical lines
                      	"""
                      )
    
                compatibility.go:506: wrote expected compatibility data... verify, commit, and rerun tests
    pohly committed Mar 9, 2021
    Configuration menu
    Copy the full SHA
    25f4174 View commit details
    Browse the repository at this point in the history
  5. generic ephemeral volumes: refresh rbac testdata

    This is the result of
      UPDATE_BOOTSTRAP_POLICY_FIXTURE_DATA=true go test k8s.io/kubernetes/plugin/pkg/auth/authorizer/rbac/bootstrappolicy
    
    Apparently enabling the GenericEphemeralVolume feature by default
    affect this test. The policy that it now tests against is indeed
    the one needed for the controller.
    pohly committed Mar 9, 2021
    Configuration menu
    Copy the full SHA
    c4311ae View commit details
    Browse the repository at this point in the history