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

Feature: metadata dependencies are auto installed #291

Closed

Conversation

cardil
Copy link
Contributor

@cardil cardil commented Jun 27, 2019

Auto-Install of dependencies based on metadata.json info

Adding support to install modules from remote Puppet Forge, automatically, by reading contents of metadata.json. There are some configuration options added, like option to define forge address. Automatic installation is disabled by default to keep backward compatibility - in next major version it should be enabled by default.

Actual default value is:

fixtures:
  metadata:
    autoinstall_dependencies: false

Additionally:

  • Adding installed module tree display after dependencies installation.
  • Added more tests, including acceptance, so that rake spec using this module will be asserted.

@cardil cardil changed the title Feature: metadata dependencieare auto installed Feature: metadata dependencies are auto installed Jun 27, 2019
@puppetcla
Copy link

CLA signed by all contributors.

@cardil cardil force-pushed the feature/metadata-dependencies branch 5 times, most recently from 7669b6f to b078b95 Compare July 1, 2019 20:50
@codecov-io
Copy link

codecov-io commented Jul 1, 2019

Codecov Report

Merging #291 into master will decrease coverage by 2.83%.
The diff coverage is 20.61%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #291      +/-   ##
==========================================
- Coverage   44.88%   42.04%   -2.84%     
==========================================
  Files          11       12       +1     
  Lines         782      849      +67     
==========================================
+ Hits          351      357       +6     
- Misses        431      492      +61
Impacted Files Coverage Δ
...puppetlabs_spec_helper/puppetlabs_spec/metadata.rb 19.51% <19.51%> (ø)
lib/puppetlabs_spec_helper/tasks/fixtures.rb 31.96% <21.42%> (-3.08%) ⬇️
...bs_spec_helper/puppetlabs_spec/puppet_internals.rb 92.5% <0%> (-2.5%) ⬇️
lib/puppetlabs_spec_helper/puppet_spec_helper.rb 65.51% <0%> (-1.73%) ⬇️
lib/puppetlabs_spec_helper/rake_tasks.rb 47.61% <0%> (-0.25%) ⬇️
lib/puppetlabs_spec_helper/tasks/check_symlinks.rb 100% <0%> (ø) ⬆️
...puppetlabs_spec_helper/puppetlabs_spec/matchers.rb 21.27% <0%> (+0.44%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0797846...d337c07. Read the comment docs.

@cardil cardil force-pushed the feature/metadata-dependencies branch 2 times, most recently from 0f3db62 to dfec662 Compare July 2, 2019 22:24
Adding support to install modules from remote Puppet Forge,
automatically, by reading contents of `metadata.json`. There
are some configuration options added, like option to define
`forge` address. Automatic installation is disabled by default
to keep backward compatibility - in next major version it should
be enabled by default.

Adding installed module tree display after dependencies
installation.

Added more tests, including acceptance, so that rake spec using
this module will be asserted.
@cardil cardil force-pushed the feature/metadata-dependencies branch from dfec662 to d337c07 Compare July 2, 2019 22:26
@cardil
Copy link
Contributor Author

cardil commented Jul 3, 2019

@Cosaquee I'm notifying you as you always wanted this feature 😉

@cardil
Copy link
Contributor Author

cardil commented Jul 4, 2019

Due to PUP-9813 installation is rather slow. Merging PR puppetlabs/puppet#7602 should provide a walkaround, until minitar performance can be enhanced.

@logicminds
Copy link
Contributor

#284 should speed up the downloads greatly.

@cardil
Copy link
Contributor Author

cardil commented Jul 9, 2019

But it's not download that are a problem but extraction of archives. Especially large like stdlib.

Parallel execution might help, but not with this PR as it pass installation of modules and their dependencies to puppet.

@daianamezdrea
Copy link
Contributor

Hi @cardil, this looks nice! Can you rebase it, please ? Thank you! Cheers!

@DavidS
Copy link
Contributor

DavidS commented Nov 16, 2020

As much as I'd like to have the changes, I've tried rebasing this and didn't get anywhere as the core changes in fixtures download are clashing hard with the other changes that have went in.

If anyone gets around to resurrecting this code, please do open a new PR referencing this one.

@DavidS DavidS closed this Nov 16, 2020
@DavidS DavidS self-assigned this Nov 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants