-
Notifications
You must be signed in to change notification settings - Fork 900
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
Replace embedded ansible git repos with GitRepository #19013
Conversation
ca2b465
to
7695ffc
Compare
6667554
to
8acf7cc
Compare
@carbonin @NickLaMuro This is ready to go. |
8acf7cc
to
5882eb2
Compare
Fixed a couple of rubocops...I'm leaving the rest because they were either already there or I don't agree with them (going to open some guides discussions on the latter) |
|
||
extra_vars = merge_extra_vars(vars[:extra_vars]) | ||
|
||
checkout_dir = checkout_git_repository # TODO: what will cleanup this dir? |
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.
Could you add a state to the workflow to cleanup the repo?
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 can, but it would have to be optional based on a parameter or something. AnsiblePlaybookWorkflow was written expecting the directory to be owned outside of it (i.e. playbooks stored in the manageiq plugins themselves).
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 was going to do that in a followup.
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.
👍
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.
LGTM
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 think most of this makes sense. I don't think most of the comments should hold up the merge.
One general question/ask: Can you link to the migration PR that handles adding git_repository_id
in this PR? I don't think I got a chance to review that one, though I think it is already merged if it is not
app/models/manageiq/providers/embedded_ansible/automation_manager/configuration_script.rb
Show resolved
Hide resolved
From PR description:
Related PR: ManageIQ/manageiq-ui-classic#5848 Update: Probably should be in the PR description now. |
Migration PR that added git_repository_id - ManageIQ/manageiq-schema#393 |
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.
Approving just to make it official @agrare
(though, I guess there are merge conflicts now...)
@Fryguy can you rebase? |
Put together a branch that fixes the conflicts: master...NickLaMuro:git_repo_embedded_ansible And explained what happened with the issue with the private method in the last commit: Can turn it into a PR if you want, or you can just use it as a reference to how to fix the conflicts. |
Additionally, this changes the clone path to use the GitRepository#id to avoid name clashes between URLs that are similar.
5882eb2
to
f878007
Compare
Some comments on commits Fryguy/manageiq@d892810~...f878007 spec/models/manageiq/providers/embedded_ansible/automation_manager/job_spec.rb
|
Checked commits Fryguy/manageiq@d892810~...f878007 with ruby 2.4.6, rubocop 0.69.0, haml-lint 0.20.0, and yamllint 1.10.0 app/models/git_repository.rb
app/models/manageiq/providers/embedded_ansible/automation_manager/configuration_script_source.rb
lib/git_worktree.rb
|
@carbonin @NickLaMuro Please review
Some "known" issues for future PRs: