Skip to content

Commit

Permalink
Fix file owners during installation
Browse files Browse the repository at this point in the history
  • Loading branch information
edewata committed Jun 6, 2024
1 parent 4d8bbec commit e6966dc
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion base/server/python/pki/server/deployment/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2099,6 +2099,7 @@ def import_system_cert_request(self, subsystem, tag):
old_name=source_path,
new_name=dest_path,
overwrite_flag=True)
self.instance.chown(dest_path)

def import_system_cert_requests(self, subsystem):

Expand Down Expand Up @@ -3045,10 +3046,12 @@ def generate_csr(self,

shutil.move(csr_pathname, csr_path)

new_csr_path = subsystem.csr_file(tag)
self.file.copy(
old_name=csr_path,
new_name=subsystem.csr_file(tag),
new_name=new_csr_path,
overwrite_flag=True)
self.instance.chown(new_csr_path)

def create_cert_request(self, nssdb, tag, request):

Expand Down Expand Up @@ -4892,6 +4895,7 @@ def store_config(self):
logger.info('Creating %s', deployment_cfg_archive)

self.file.copy(deployment_cfg, deployment_cfg_archive)
self.instance.chown(deployment_cfg_archive)

def set_systemd_override(self, section, param, value, fname='local.conf'):
if fname not in self.systemd.overrides:
Expand Down Expand Up @@ -4954,6 +4958,7 @@ def store_manifest(self):
logger.info('Creating %s', manifest_archive)

self.file.copy(manifest_file, manifest_archive)
self.instance.chown(manifest_archive)

def restore_selinux_contexts(self):

Expand Down

0 comments on commit e6966dc

Please sign in to comment.