mirror of
https://github.com/ceph/ceph-csi.git
synced 2024-11-22 14:20:19 +00:00
cleanup: use 0o600 intead of 0600
as we are using 0o600 in multiple files use the same in all files which also fixes go lint issue. Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
This commit is contained in:
parent
c67bacdb11
commit
4938fc2ff4
@ -320,7 +320,7 @@ func (kms *VaultTenantSA) getTokenPath() (string, error) {
|
||||
return "", err
|
||||
}
|
||||
|
||||
err = os.WriteFile(dir+"/token", []byte(token), 0600)
|
||||
err = os.WriteFile(dir+"/token", []byte(token), 0o600)
|
||||
if err != nil {
|
||||
return "", fmt.Errorf("failed to write token for ServiceAccount %s/%s: %w", kms.tenantSAName, kms.Tenant, err)
|
||||
}
|
||||
|
@ -1672,7 +1672,7 @@ func updateRBDImageMetadataStash(metaDataPath, device string) error {
|
||||
}
|
||||
|
||||
fPath := filepath.Join(metaDataPath, stashFileName)
|
||||
err = os.WriteFile(fPath, encodedBytes, 0600)
|
||||
err = os.WriteFile(fPath, encodedBytes, 0o600)
|
||||
if err != nil {
|
||||
return fmt.Errorf("failed to stash JSON image metadata at path: (%s) for spec:(%s) : %w",
|
||||
fPath, imgMeta.String(), err)
|
||||
|
Loading…
Reference in New Issue
Block a user