-
Notifications
You must be signed in to change notification settings - Fork 11
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
Add container jobs performing chores #31
Conversation
This will avoid repeating this operation multiple times. Technically auto[run|build|test].sh create a dir for output in 'spdk/../', but making it explicit makes it more clear. Additionally the output_dir is set by default one directory up from spdk. Use that to shorten the already unwieldy one-liner. Signed-off-by: Tomasz Zawadzki <[email protected]>
Some of the tests perform git operations on the submodules. Signed-off-by: Tomasz Zawadzki <[email protected]>
This is intended to match unittest-main-docker-autotest. Originaly this job was intended to run inside a container to make better use of resources than VMs. For jobs that do not run functional tests with SPDK. Meanwhile container images are not ready for spdk-ci, this is still executed in VM. Job was renamed to better match the intent: - 'main' to 'gcc', other jobs will be similar and have 'clang' and 'vagrant' - 'docker' to 'container' As for the steps, they do not use autorun.sh in order to skip parts that are required for functional tests - ex. setup.sh. On old CI setup it was demonstrably faster in execution, than just full autorun.sh. Yet it might not hold up today. To keep changes on SPDK repo to minimum, container jobs will still call functions from tests scripts directly. At some point it will need to re-evaluted if this is best approach. One note here is that $rootdir is usually set by autorun.sh script. Since we are not calling it, we need to set it manually. OCF is turned on, to match prior CI setup. Signed-off-by: Tomasz Zawadzki <[email protected]>
Signed-off-by: Tomasz Zawadzki <[email protected]>
s/main/gcc s/docker/container Signed-off-by: Tomasz Zawadzki <[email protected]>
Note that empty.conf was added to avoid creating empty config files for jobs that require no such file. We might want to revist this requirement on some of the scripts in SPDK. s/docker/container Signed-off-by: Tomasz Zawadzki <[email protected]>
Signed-off-by: Tomasz Zawadzki <[email protected]>
Signed-off-by: Tomasz Zawadzki <[email protected]>
Signed-off-by: Tomasz Zawadzki <[email protected]>
Tests like release build or scan-build jobs take around ~30min already, with longest running one I've seen at 32min. Let's extend it for now, and once we manage to get all required jobs in - figure out how to reduce the execution time. Signed-off-by: Tomasz Zawadzki <[email protected]>
Probably '*-autotest_artifacts' would be better in the future, but still need to change the nvme job to match. Signed-off-by: Tomasz Zawadzki <[email protected]>
- name: autorun_nvme | ||
run: | | ||
/opt/spdk/autorun.sh /opt/configs/nvme.conf | ||
|
||
- name: unittest-gcc-container-autotest | ||
run: | | ||
rootdir=/opt/spdk && cd $rootdir && source ./test/common/autobuild_common.sh /opt/configs/unittest-gcc-container-autotest.conf && ocf_precompile && unittest_build && ./test/unit/unittest.sh |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Total nit: break the line a bit?
It's ~190 chars, so a bit unwieldy when displayed in editor with split scree.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see jobs in other commits having similar line length, so applies there as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
https://cijoe.readthedocs.io/en/latest/workflows/index.html#inline-commands
Each line is separate command intentionally. This implies all the variables being set and workdir has to be in one line.
I could have created separate script that does all of that, but then it goes a bit against the simplicity we wanted here. We are already three 'workflows' deep.
|
||
- name: check-so-deps-container-autotest | ||
run: | | ||
rootdir=/opt/spdk && cd $rootdir && source ./test/common/autobuild_common.sh /opt/configs/check-so-deps-container-autotest.conf && ocf_precompile && SPDK_ABI_DIR=/opt/spdk-abi check_so_deps |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a lot of repetitions of this rootdir=/opt/spdk && cd $rootdir && source ./test/common/autobuild_common.sh
.
This is ci-joe specific config so I have no idea how to handle that. Using yaml's aliases may reduce the number of repetitions, but overall generates more total lines in this file (lol). Something to clean up later I guess.
This PR adds following jobs to the per-patch:
Series on SPDK here, along with image rebuild is required.
This part of the work on spdk/spdk#3615