Commit Graph

23 Commits

Author SHA1 Message Date
Guillaume Chauvel 83b2d68a91 tutorial: Rework quick-start and prepare for other tutorials
-quick-start steps are modified and fit more to what a reader would do
-quick-start test code is mainly splitted into 2 files, one which is a
 setup part as a role, the second one starts with cloning the test
 repository, just like all followings tutorial will do
-some elementary steps when manipulating or checking gerrit are being
 added as roles

tutorial ssh config: test ssh configuration has been modified to allow
 using a known_hosts file for both someone executing localtest and
 opendev.org's zuul. A reader executing the tutorial would still have to
 accept the fingerprint. To do so, commit-msg hook is fetched manually,
 otherwise it would be downloaded by git-review throught scp. Alas,
 git-review doesn't allow to pass options to scp to provide a new
 known_hosts file.
 User's ssh key is used if ~/.ssh/id_rsa.pub is available, otherwise use
 a generated one.

- "to_json | from_json | json_query" in test is due to an issue between
 ansible and jmespath [1]

[1] https://github.com/ansible-collections/community.general/issues/320

Change-Id: Id5c669537ff5afc7468352139980ebade167d534
2021-01-11 17:02:38 +01:00
Monty Taylor dc445242bc Shift docker and pip setup to pre-playbook for quick-start
Installing docker and pip are pre-reqs and we're using zuul roles
to do them, so they're not really testing explicit quick-start
steps. Move them to pre-run.

Change-Id: I374dac18b9b7e376d924b11f4661355ea7c4d149
2020-06-16 09:12:48 -05:00
Monty Taylor ca63ba72a8 Add ensure-pip to quick-start job
We assume pip exists and were getting it from opendev images before.
Add ensure-pip so that pip exists.

Depends-On: https://review.opendev.org/735904
Change-Id: Ifbd32f11f09c518062ffa350f9ebbe597493df67
2020-06-16 07:58:20 -05:00
vass 6148f60c2b Use ensure-* roles
The install-* roles in zuul-jobs have been renamed to ensure-*, follow
the rename.

Change-Id: I6e75fe3562c1197e5c7335b8ce3773867e352036
2020-04-07 16:27:52 +02:00
Mohammed Naser 143ac07788 cleanup: install docker-compose via role
install-docker allows us to install docker-compose, so why not just use
that instead and test our roles.

Depends-On: https://review.opendev.org/707902
Change-Id: Ie45cbcd6ad05d035e708fed45348e498a35a8eac
2020-02-14 21:34:36 +01:00
James E. Blair 674540dca8 Fix path in quick-start localtest
This catches the localtest playbook up with the recent moves.

Change-Id: Ib87e7e9fc91e56bcbf6390d1e130dacfdb2302e6
2020-01-27 10:31:35 -08:00
David Shrewsbury e6d8b210cc Documentation reorg
Reorganizing docs as recommended in:

https://www.divio.com/blog/documentation/

This is simply a reorganization of the existing documents and changes
no content EXCEPT to correct the location of sphinx doc references.
Expect followup changes to change document names (to reflect the new
structure) and to move content from existing guides (e.g., to move the
pipeline/project/job structure definitions out of the "Project Configuration"
reference guide into their own reference documents for easier locatability).

All documents are now located in either the "overview", "tutorials",
"discussions", or "references" subdirectories to reflect the new structure
presented to the user. Code examples and images are moved to "examples" and
"images" root-level directories.

Developer specific documents are located in the "references/developer"
directory.

Change-Id: I538ffd7409941c53bf42fe64b7acbc146023c1e3
2020-01-14 12:47:23 -05:00
Clark Boylan 27579ce456 Handle new default of uncompressed job-output
The quick start test assumes a compressed job output file but we don't
compress it by default anymore. Handle this new behavior change.

Change-Id: I9db270ae5ceaa98afcd078af0d99460d406295f3
2019-10-01 16:02:41 -07:00
James E. Blair 4a719d0fe4 Collect more information from quickstart failures
When the quickstart job fails, make sure that we get stderr from
the docker logs.  Also, add timestamps to the waiting to start
script so that we can compare when it gave up to when systems
came online.

Change-Id: I632c794de7fb792fbe7d0b8e095701a5d7fd1af7
2019-08-16 08:48:11 -07:00
Jeremy Stanley 5bf838db68 Install latest git-review from PyPI in quickstart
With the removal[*] of refs/publish in Gerrit 3.0.0, git-review
1.27.1 or later is needed to avoid attempting a push there and
ultimately failing. The git-review package in Ubuntu 18.04 LTS is
too old (1.26.0), so use latest from PyPI instead.

Adjust the quick-start document to install git-review with pip, and
on Debian/Ubuntu suggest including the python3-pip distro package
since it's split out separate from the interpreter packages.

[*] https://gerrit-review.googlesource.com/c/gerrit/+/192494

Change-Id: I247fb761667a99cf9f25478b49c5a1fe5d11a6cf
2019-05-20 17:46:33 +00:00
Tristan Cacqueray 41178c4aae zuul-quick-start: run docker-compose as regular user
To use the buildset registry we need the docker-compose command to
be executed as the zuul user, otherwise the auth configuration is
not set and the test pulls the images from docker.io.
This change also adds the --digests argument to docker image ls.

Change-Id: I62970cae4851b06ff79cdc953f90772c550000bd
2019-05-14 02:10:51 +00:00
Monty Taylor b0252eef9d Update references for opendev
Change-Id: I3c1ac5478efed4dee1d525deb036d457287fa136
2019-04-24 12:59:17 +00:00
James E. Blair 333f1e03b6 Use the buildset registry in zuul-quick-start
The job no longer needs to build duplicate copies of the images,
it can fetch them from the buildset registry instead.

Change-Id: Ibcca12c20d29b9b45a67b65934e5a02087c8cdf8
2019-04-04 15:27:06 -07:00
Monty Taylor 7fe0e780cf
Build zuul containers with dockerfile not pbrx
While pbrx is nice and all, it's quite the divergence from how
the rest of the container ecosystem works. Switch to using
Dockerfile and the python-builder image.

Bind mount ld.so.cache into bwrap context

When using images based on the python:slim base image, python
is installed in /usr/local and the linker needs to know to look
in /usr/local/lib for shared libraries.

Depends-On: https://review.openstack.org/632187
Change-Id: I84f6dd2a8e3222f7807103dcbb61bdadedfdd22d
2019-01-24 16:11:31 +00:00
Quique Llorente ac168d1e40 Do a proper wait for zuul at quickstart
Replace plain timeout with retries over tenant status API

Change-Id: I741f3cdc3a042af9775998c72ce6fb5d9c552f8b
2018-11-26 10:44:47 +01:00
James E. Blair dec8eacc6e Collect docker logs after quick-start run
Change-Id: I492841fea5a3d3c48b38bde30d73ad12353553af
2018-10-25 06:25:05 -07:00
Zuul 8b1fcb8f11 Merge "Add mysql to quick-start" 2018-10-18 05:10:01 +00:00
James E. Blair 03259e78b0 Temporary fix for race in quick start job
We should wait until Zuul has loaded its configuration before
performing the status check.  That's slightly complicated right
now, so stabilize the job with a sleep until we work through
the correct solution.

Change-Id: Ia94b14deae16786e5f88507dde637198fceb7707
2018-10-17 18:57:29 -07:00
James E. Blair 8bca70aadc Add mysql to quick-start
This allows us to show build history in the web ui.

Also add a local test playbook for the quickstart which basically
does what the zuul-quick-start job does, but expects to run locally
on a workstation (ie, does not install the docker registry and
docker).

Change-Id: Id62dcf69f48399dab3d1259679bf2fc2ce50460e
2018-10-16 11:13:41 -07:00
James E. Blair 45724a42ae Add status page to the quick-start
Tell users that the status page exists and point them to it during
the quick-start documentation.

Also, verify that it is served in the quick-start test job.

Change-Id: I8783ac731112af7752e8a7fc34e3337b52c382d9
2018-10-15 09:46:58 -07:00
James E. Blair 98d9e2538d Build new container images for quick-start
This makes the job suitable for gating.

Depends-On: https://review.openstack.org/609844
Change-Id: I4f32a35ddb9f880bb617a4896429e4cb05b0c2f1
2018-10-11 15:45:01 -07:00
James E. Blair 20b2c01e99 Remove disable-recommends in quick-start test
This test is trying to test a user process on a typical VM/workstation
so make sure that apt behaves in the default manner and installs
recommended packages (such as docker itself).

Change-Id: I62b1367f9d4311deedf16176fa3f97cf0b3a74f1
2018-10-11 12:53:23 -07:00
James E. Blair 011d765915 Add a quick-start test job
This playbook performs approximately the same steps documented in
the quick-start tutorial.  Use it to verify that things still function.

Note that it does not yet build the images from the current source
(rather, it downloads them from dockerhub) so it is not suitable
as a gate check (it does not use the change under test in zuul).
It does, however,  use the sample config files from the change under
test, so can be used to verify changes to those.

Incidentally, this is the first-ever live functional test between
Zuul, Nodepool, and Gerrit.

Change-Id: I5b3dc4b8a8d409787d07b4ad155898f97f1e9eb9
2018-10-11 12:53:05 -07:00