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

Jetlag CI stuff #511

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft

Jetlag CI stuff #511

wants to merge 1 commit into from

Conversation

webbnh
Copy link
Collaborator

@webbnh webbnh commented Jul 8, 2024

This PR creates a holding area for materials which might be used to create a Jetlag continuous integration (CI) system, to automate building and testing of Jetlag for development and quality assurance.

This PR, in addition to adding a CI subdirectory and a README.md for it, adds one file, deploy_sno.sh, which is an initial effort at scripting the deployment of a single-node OpenShift cluster using Jetlag. It is targeted at a Scale Lab deployment, but the techniques it uses should be applicable across all deployments. It is currently somewhat opinionated, but it should be straightforward to generalize it.

This PR is not necessarily intended to be merged; rather, it's a placeholder, to give visibility for this file in the event that someone wants to use it as the basis for a CI runner, e.g., for Jenkins.

@webbnh webbnh requested a review from dbutenhof July 8, 2024 19:21
@webbnh webbnh assigned webbnh and dbutenhof and unassigned webbnh Jul 8, 2024
Copy link
Collaborator

@dbutenhof dbutenhof left a comment

Choose a reason for hiding this comment

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

Cool, thanks for the "running start".

Comment on lines +30 to +31
ON_BASTION="${N} ssh -i ${ID_FILE} root@${BASTION} /bin/bash -e ${xtrace}"
N=${DEBUG:+'echo [DRY-RUN] '}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Expand ${N} into ON_BASTION and then define N? Interesting strategy. Or did you mean ON_BASTION='${N} ...' to defer substitution until later?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Those are excellent questions. I concur that the code as it stands looks suspiciously like a botch.

Unfortunately, the requirements for a "dry-run" are less than cut and...er...dried. In one conception, one would like to be able to run the script without it actually requiring or expending any resources. But, if that execution takes place only on the local node, it gets pretty boring pretty fast. A more interesting scenario involves doing a "dry run" but including the parts which execute on the bastion as well, but doing them as a dry-run. In that case, the code above does the "right thing": it actually executes the ssh command but the commands that that executes get the ${N} treatment. (However, once the mechanics of that work, then even that becomes boring...so, we should probably just tear out the whole ${N} thing altogether.)

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.

2 participants