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

Broken dependency for yumrepos #22

Closed
misaflo opened this issue May 4, 2021 · 4 comments
Closed

Broken dependency for yumrepos #22

misaflo opened this issue May 4, 2021 · 4 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@misaflo
Copy link

misaflo commented May 4, 2021

Hello,

A new bug with version 2.1.3 on CentOS:

Could not find resource 'Yumrepo[icinga-testing-builds]' for relationship on 'Package[createrepo]'

I fix this with this modification on manifests/repos/yum.pp:

$repos.each |String $repo_name, Hash $repo_config| {
  if $repo_name in keys($managed) and $managed[$repo_name] {
    yumrepo { $repo_name:
      *       =>  $repo_config,
      require => File['/etc/yum.repos.d/netways-plugins-release.repo', '/etc/yum.repos.d/netways-extras-release.repo'],
    }
  }
  Yumrepo[$repo_name] -> Package <| |>
}

to:

$repos.each |String $repo_name, Hash $repo_config| {
  if $repo_name in keys($managed) and $managed[$repo_name] {
    yumrepo { $repo_name:
      *       =>  $repo_config,
      require => File['/etc/yum.repos.d/netways-plugins-release.repo', '/etc/yum.repos.d/netways-extras-release.repo'],
    } -> Package <| |>
  }
}
@lbetz
Copy link
Contributor

lbetz commented May 4, 2021

Strange, don't see that makes a difference. Ah now. Dependency belongs to the wrong block.

@lbetz lbetz added the bug Something isn't working label May 4, 2021
@lbetz lbetz added this to the v2.1.4 milestone May 4, 2021
@lbetz lbetz changed the title Bug with yumrepo Broken dependency for yumrepos May 4, 2021
@lbetz lbetz self-assigned this May 4, 2021
@lbetz lbetz closed this as completed in b0e82e9 May 4, 2021
@lbetz
Copy link
Contributor

lbetz commented May 4, 2021

before I publish a new release, can you test the master branch?

@misaflo
Copy link
Author

misaflo commented May 4, 2021

Yes, it works (tested on CentOS and Debian). :-)

@lbetz
Copy link
Contributor

lbetz commented May 4, 2021

Thx, release is upcoming.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants