backend.createrepo

backend.createrepo.run_cmd_unsafe(comm_str, lock_path)[source]
backend.createrepo.createrepo_unsafe(path, dest_dir=None, base_url=None)[source]

Run createrepo_c on the given path

Warning! This function doesn’t check user preferences. In most cases use createrepo(...)

Parameters:
  • path (string) – target location to create repo
  • lock – [optional]
  • dest_dir (str) – [optional] relative to path location for repomd, in most cases you should also provide base_url.
  • base_url (str) – optional parameter for createrepo_c, “–baseurl”
Return tuple:

(return_code, stdout, stderr)

backend.createrepo.add_appdata(path, username, projectname, lock=None)[source]
backend.createrepo.add_module_md(path)[source]
backend.createrepo.createrepo(path, front_url, username, projectname, override_acr_flag=False, base_url=None)[source]
Creates repo depending on the project setting “auto_createrepo”. When enabled creates repodata at the provided path, otherwise
Parameters:
  • path – directory with rpms
  • front_url – url to the copr frontend
  • username – copr project owner username
  • projectname – copr project name
  • base_url – base_url to access rpms independently of repomd location
  • lock (Multiprocessing.Lock) – [optional] global copr-backend lock
Returns:

tuple(returncode, stdout, stderr) produced by createrepo_c