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

baremetal: ci install scripts may have to get smarter about being re-run #78

Closed
grahamwhaley opened this issue Nov 8, 2018 · 2 comments

Comments

@grahamwhaley
Copy link
Contributor

I'm seeing an issue on my new metrics CI baremetal machine (below). I was trying to track down if this was a problem with our installation scripts or if an external service (docker ubuntu repos) were maybe down, when I found some other niggle with our install scripts on baremetal.

Here is what I saw:

13:52:34 Install haveged
13:52:35 manage_ctr_mgr.sh - WARNING: docker is not installed on this system
13:52:35 manage_ctr_mgr.sh - WARNING: docker is not installed on this system
13:52:35 <13>Nov  8 13:52:35 manage_ctr_mgr.sh: Installing docker v18.06-ce
13:52:35 Reading package lists...
13:52:36 Building dependency tree...
13:52:36 Reading state information...

13:52:36 apt-transport-https is already the newest version (1.2.29).
13:52:36 ca-certificates is already the newest version (20170717~16.04.1).
13:52:36 software-properties-common is already the newest version (0.96.20.7).
13:52:36 0 upgraded, 0 newly installed, 0 to remove and 27 not upgraded.
13:52:37 OK
13:52:38 Hit:1 https://download.docker.com/linux/ubuntu xenial InRelease
13:52:38 Hit:2 http://ppa.launchpad.net/alexlarsson/flatpak/ubuntu xenial InRelease
13:52:38 Hit:3 http://archive.ubuntu.com/ubuntu xenial InRelease
13:52:38 Ign:4 http://download.opensuse.org/repositories/home:/katacontainers:/release/xUbuntu_16.04  InRelease
13:52:39 Hit:5 http://archive.ubuntu.com/ubuntu xenial-updates InRelease
13:52:39 Hit:6 http://download.opensuse.org/repositories/home:/katacontainers:/release/xUbuntu_16.04  Release
13:52:39 Get:7 http://archive.ubuntu.com/ubuntu xenial-security InRelease [107 kB]
13:52:39 Fetched 107 kB in 1s (91.8 kB/s)
13:52:42 Reading package lists...
13:52:42 E: read, still have 1 to read but none left
13:52:42 Reading package lists...
13:52:42 Building dependency tree...
13:52:42 Reading state information...
13:52:42 E: Version '' for 'docker-ce' was not found
13:52:42 Build step 'Execute shell' marked build as failure

and then after looking at the /etc/apt/sources.list file on the baremetal machine, I see:

deb http://archive.ubuntu.com/ubuntu/ xenial main universe
deb http://archive.ubuntu.com/ubuntu/ xenial-updates main universe
deb http://archive.ubuntu.com/ubuntu/ xenial-security main universe
deb [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable
# deb-src [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable
# deb-src [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable
# deb-src [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable
# deb-src [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable
# deb-src [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable
# deb-src [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable
# deb-src [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable
# deb-src [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable
# deb-src [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable

I presume those deb-src lines are commented out, but it feels like we get an extra line every time we run the install scripts. We should probably make the install scripts smarter and only add a repo URL if it is not already registered.

(also see kata-containers/tests#868 (comment) and kata-containers/tests#895 - looks like docker has changed the package name etc.)

@chavafg
Copy link
Contributor

chavafg commented Nov 26, 2018

From an e-mail conversation with @zhiminghufighting:
As an enhancement for the CI setup.sh script, make it smarter so when it is re-executed (maybe because it failed on a step), re-execute from the failed step instead of doing it from the beginning.

I am not really sure what is the best way we can handle this as on our baremetal machines that run the CI we would want to execute all the steps from the beginning, but when a developer has a failed step, he may not want to re-execute everything. Maybe using the CI=true or CI=false envar...

GabyCT added a commit to GabyCT/ci that referenced this issue Feb 12, 2019
…_tests

tests: Add terminal and top tests
@GabyCT
Copy link
Contributor

GabyCT commented May 26, 2021

Closing this issue as it is not related with kata 2.x

@GabyCT GabyCT closed this as completed May 26, 2021
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

No branches or pull requests

3 participants