Skip to content

qa/tasks/cephadm: setup site based container registry - #35395

Merged
tchaikov merged 1 commit into
ceph:masterfrom
kshtsk:wip-registry-conf
Jun 17, 2020
Merged

tchaikov merged 1 commit into
ceph:masterfrom
kshtsk:wip-registry-conf

Conversation

@kshtsk

@kshtsk kshtsk commented Jun 4, 2020

Copy link
Copy Markdown
Contributor

Add containers registry mirror for 'docker.io' to the config
file /etc/containers/registries.conf

Since we need site based config, so each teuthology instance
could have own containers' mirror, store corresponding data
in /etc/teuthology.yaml under 'overrides/cephadm' task specific
section.

Signed-off-by: Kyr Shatskyy [email protected]

Checklist

  • References tracker ticket
  • Updates documentation if necessary
  • Includes tests for new functionality or reproducer for bug

Show available Jenkins commands
  • jenkins retest this please
  • jenkins test classic perf
  • jenkins test crimson perf
  • jenkins test signed
  • jenkins test make check
  • jenkins test make check arm64
  • jenkins test submodules
  • jenkins test dashboard
  • jenkins test dashboard backend
  • jenkins test docs
  • jenkins render docs
  • jenkins test ceph-volume all
  • jenkins test ceph-volume tox

@kshtsk

kshtsk commented Jun 6, 2020 •

Copy link
Copy Markdown
Contributor Author

@sebastian-philipp @tchaikov my question to you, what do you expect if there is no config is found for the mirror or and the image name, what you guys think the test should do when using defaults values? At this moment it is just fails because image name is underfined? I can add an exception that container/image should be declared in the config files, or just try and skip. If we want containers running out of our ceph-ci there should be some default values for image name at least in default registry, which are the correct values?

@sebastian-philipp

sebastian-philipp commented Jun 6, 2020 •

Copy link
Copy Markdown
Contributor

Tbh I don't want anyone to run into the same issues. I'd simply fail the task, if the registry is not set

@kshtsk

kshtsk commented Jun 10, 2020 •

Copy link
Copy Markdown
Contributor Author

guys, I've changed the code to take arguments from the defaults section of teuthology.yaml because if use overrides it might confuse the user since it is used for overriding the options provided in the test suite. Also added a code to make it possible to use overrides mechanism, for the case we want use another image name per run. This is good for flexibility, we use such methods downstream, when we just add build ids, repos, etc. specific to run.

@kshtsk

kshtsk commented Jun 10, 2020 •

Copy link
Copy Markdown
Contributor Author

Run using overrides has passed:
http://pulpito.ceph.com/kyr-2020-06-10_13:53:34-rados:cephadm:smoke-master-distro-basic-smithi/

2020-06-10T14:11:27.328 INFO:teuthology.run_tasks:Running task cephadm...
2020-06-10T14:11:27.437 INFO:tasks.cephadm:Config: {'conf': {'mgr': {'debug mgr': 20, 'debug ms': 1}, 'mon': {'debug mon': 20, 'debug ms': 1, 'debug paxos': 20}, 'osd': {'debug filestore': 20, 'debug journal': 20, 'debug ms': 20, 'debug osd': 25, 'osd shutdown pgref assert': True}}, 'log-whitelist': ['\\(MDS_ALL_DOWN\\)', '\\(MDS_UP_LESS_THAN_MAX\\)'], 'sha1': '5a7d75290f4480764b24c241ba11f93fe8917c4b', 'containers': {'image': 'quay.io/ceph-ci/ceph', 'registry_mirrors': {'docker.io': 'vossi04.front.sepia.ceph.com:5000'}}}
2020-06-10T14:11:27.438 INFO:tasks.cephadm:Cluster image is quay.io/ceph-ci/ceph:5a7d75290f4480764b24c241ba11f93fe8917c4b
.
.
.
2020-06-10T14:11:29.469 INFO:tasks.cephadm:Adding local image mirror vossi04.front.sepia.ceph.com:5000
2020-06-10T14:11:29.556 DEBUG:teuthology.orchestra.remote:smithi188:/etc/containers/registries.conf is 924B
2020-06-10T14:11:29.657 INFO:teuthology.orchestra.run.smithi188:> sudo sh -c 'cat > /etc/containers/registries.conf'
2020-06-10T14:11:29.888 DEBUG:teuthology.orchestra.remote:smithi124:/etc/containers/registries.conf is 924B
2020-06-10T14:11:29.994 INFO:teuthology.orchestra.run.smithi124:> sudo sh -c 'cat > /etc/containers/registries.conf'

@kshtsk

kshtsk commented Jun 10, 2020 •

Copy link
Copy Markdown
Contributor Author

Run using defaults has passed:
http://pulpito.ceph.com/kyr-2020-06-10_14:23:32-rados:cephadm:smoke-master-distro-basic-smithi/

2020-06-10T14:39:29.500 INFO:tasks.cephadm:Config: {'conf': {'mgr': {'debug mgr': 20, 'debug ms': 1}, 'mon': {'debug mon': 20, 'debug ms': 1, 'debug paxos': 20}, 'osd': {'debug filestore': 20, 'debug journal': 20, 'debug ms': 20, 'debug osd': 25, 'osd shutdown pgref assert': True}}, 'log-whitelist': ['\\(MDS_ALL_DOWN\\)', '\\(MDS_UP_LESS_THAN_MAX\\)'], 'sha1': '5a7d75290f4480764b24c241ba11f93fe8917c4b'}
2020-06-10T14:39:29.501 INFO:tasks.cephadm:Cluster image is quay.io/ceph-ci/ceph:5a7d75290f4480764b24c241ba11f93fe8917c4b
.
.
.
2020-06-10T14:39:31.427 INFO:tasks.cephadm:Adding local image mirror vossi04.front.sepia.ceph.com:5000
2020-06-10T14:39:31.541 DEBUG:teuthology.orchestra.remote:smithi061:/etc/containers/registries.conf is 924B
2020-06-10T14:39:31.668 INFO:teuthology.orchestra.run.smithi061:> sudo sh -c 'cat > /etc/containers/registries.conf'
2020-06-10T14:39:31.886 DEBUG:teuthology.orchestra.remote:smithi097:/etc/containers/registries.conf is 924B
2020-06-10T14:39:32.004 INFO:teuthology.orchestra.run.smithi097:> sudo sh -c 'cat > /etc/containers/registries.conf'

@kshtsk
kshtsk requested a review from tchaikov June 10, 2020 14:49
Add containers registry mirror for 'docker.io' to the config
file /etc/containers/registries.conf

Since we need site based config, so each teuthology instance
could have own containers' mirror, store corresponding data
in /etc/teuthology.yaml under 'overrides/cephadm' task specific
section.

Signed-off-by: Kyr Shatskyy <[email protected]>
@kshtsk

kshtsk commented Jun 10, 2020

Copy link
Copy Markdown
Contributor Author

Slightly modified the doc for the task.

@tchaikov

Copy link
Copy Markdown
Contributor

jenkins test dashboard backend

@tchaikov
tchaikov merged commit 48ee2b8 into ceph:master Jun 17, 2020
@kshtsk
kshtsk deleted the wip-registry-conf branch August 4, 2020 09:06
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.

3 participants