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

docker: Upgrade container packages before running tests #1748

Merged
merged 5 commits into from
Aug 17, 2018

Conversation

mudler
Copy link
Member

@mudler mudler commented Aug 14, 2018

We need something like this - or either rebuild the docker image more frequently (assuming that it's upgrading packages during docker build phase).

This is for a later discussion @foursixnine, just opening the PR just to give a rough idea of what we do already in os-autoinst (but there we rebuild the docker image each time, not here, thus tests will fail anyway).

@mudler
Copy link
Member Author

mudler commented Aug 14, 2018

But i would rather drop the cpanm mechanisms to make it fail when trying to upgrade packages, it's rather annoying than useful

@codecov
Copy link

codecov bot commented Aug 15, 2018

Codecov Report

Merging #1748 into master will decrease coverage by 13.69%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1748      +/-   ##
==========================================
- Coverage   80.91%   67.22%   -13.7%     
==========================================
  Files         139      123      -16     
  Lines        9679     9021     -658     
==========================================
- Hits         7832     6064    -1768     
- Misses       1847     2957    +1110
Impacted Files Coverage Δ
lib/OpenQA/File.pm 8.14% <0%> (-91.86%) ⬇️
lib/OpenQA/Client/Upload.pm 11.62% <0%> (-88.38%) ⬇️
lib/db_profiler.pm 12% <0%> (-88%) ⬇️
lib/OpenQA/Resource/Locks.pm 10.52% <0%> (-84.22%) ⬇️
lib/OpenQA/Task/Asset/Limit.pm 17.24% <0%> (-82.76%) ⬇️
lib/OpenQA/Task/Job/Modules.pm 17.24% <0%> (-82.76%) ⬇️
lib/OpenQA/Parser.pm 17.92% <0%> (-82.08%) ⬇️
lib/OpenQA/Client/Handler.pm 18.18% <0%> (-81.82%) ⬇️
lib/OpenQA/Worker/Cache.pm 5.28% <0%> (-78.88%) ⬇️
lib/OpenQA/Parser/Results.pm 21.73% <0%> (-78.27%) ⬇️
... and 73 more

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 1ded71a...0cd6265. Read the comment docs.

@mudler mudler force-pushed the docker_upgrade_packages branch 6 times, most recently from 99f8d58 to 3d853a5 Compare August 15, 2018 13:12
@mudler mudler changed the title (Example) docker: Upgrade container packages before running tests (WIP) docker: Upgrade container packages before running tests Aug 15, 2018
- add UPGRADE_FROM_ZYPPER
@mudler
Copy link
Member Author

mudler commented Aug 16, 2018

The errors in the CI are gone when #1747 is applied, but it's hanging on developer mode tests https://travis-ci.org/mudler/openQA/jobs/416778791

@mudler mudler changed the title (WIP) docker: Upgrade container packages before running tests docker: Upgrade container packages before running tests Aug 17, 2018
Copy link
Member

@foursixnine foursixnine left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still needs some improvements, but lets start to move on

cpanm -n --mirror http://no.where/ --installdeps .
[ "$INSTALL_FROM_CPAN" -eq 1 ] && \
(cpanm --local-lib=~/perl5 local::lib && cpanm -n --installdeps . ) || \
cpanm -n --mirror http://no.where/ --installdeps .
if ! [ $? -eq 0 ]; then
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in this case, if INSTALL_FROM_CPAN is not set, the exit of the cd that is previous is what's evaluated right?... I think we can remove then the check

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

right, will address this in another PR


echo ">> Running tests"

dbus-run-session -- sh -c "$*"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@foursixnine foursixnine merged commit 7164c58 into os-autoinst:master Aug 17, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants