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

MUNI_TECH_WRITERS: Better documented local collections for playbooks #1129 #1315

Merged
merged 6 commits into from
Apr 30, 2024

Conversation

Devids10
Copy link
Contributor

This is a solution for the issue #1129.

@ansible-documentation-bot ansible-documentation-bot bot added the new_contributor This PR is the first contribution by a new community member. label Apr 24, 2024
@ansible-documentation-bot
Copy link
Contributor

Thanks for your Ansible docs contribution! We talk about Ansible documentation on matrix at #docs:ansible.im and on libera IRC at #ansible-docs if you ever want to join us and chat about the docs! We meet there on Tuesdays (see the Ansible calendar) and welcome additions to our weekly agenda items - scroll down to find the upcoming agenda and add a comment to put something new on that agenda.

@Devids10 Devids10 marked this pull request as draft April 24, 2024 07:11
@oraNod oraNod added backport-2.15 Automatically create a backport for the stable-2.15 branch backport-2.14 Automatically create a backport for the stable-2.14 branch backport-2.16 Automatically create a backport for the stable-2.16 branch MUNI tech writers backport-2.17 Automatically create a backport for the stable-2.17 branch labels Apr 24, 2024
Installing collections adjacent to playbooks
--------------------------------------------

.. include:: ../shared_snippets/installing_collections_playbooks.txt
Copy link
Contributor

Choose a reason for hiding this comment

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

Hi @Devids10 I think the idea is to get rid of the shared snippets .txt file and put the content directly in the .rst file.

@Devids10 Devids10 force-pushed the better_documented_local_collections branch from ace8404 to a2641f4 Compare April 24, 2024 18:00
@Devids10 Devids10 marked this pull request as ready for review April 24, 2024 18:06
@Devids10
Copy link
Contributor Author

@oraNod I think this is what you all were thinking about.
(Ignore all the pushes, I forgot to add files to the commit)

Copy link
Contributor

@oraNod oraNod left a comment

Choose a reason for hiding this comment

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

Looks better @Devids10 Thanks for the updates. Left some comments.

--------------------------------------------

You can install collections locally next to your playbooks inside your project instead of in a global location on your system or on your AWX.
This approach has these added benefits:
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
This approach has these added benefits:
Using locally installed collections adjacent to playbooks has some benefits, such as:

Copy link
Contributor

Choose a reason for hiding this comment

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

Please add an empty line above this to separate it from the first sentence.


You can install collections locally next to your playbooks inside your project instead of in a global location on your system or on your AWX.
This approach has these added benefits:
* Ensures that all users of the project use the same collection version.
Copy link
Contributor

Choose a reason for hiding this comment

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

A tip with list items is to use parallelism. The starting verb in each list item should use the same tense.

@oraNod oraNod requested review from felixfontein and samccann April 25, 2024 09:33
Copy link
Contributor

@oraNod oraNod left a comment

Choose a reason for hiding this comment

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

LGTM. Thanks @Devids10

@oraNod oraNod requested a review from samccann April 30, 2024 14:39
@samccann samccann merged commit ba04139 into ansible:devel Apr 30, 2024
8 checks passed
Copy link

patchback bot commented Apr 30, 2024

Backport to stable-2.15: 💔 cherry-picking failed — conflicts found

❌ Failed to cleanly apply ba04139 on top of patchback/backports/stable-2.15/ba04139aaa7a178eed1ccda037f962bea1dd5594/pr-1315

Backporting merged PR #1315 into devel

  1. Ensure you have a local repo clone of your fork. Unless you cloned it
    from the upstream, this would be your origin remote.
  2. Make sure you have an upstream repo added as a remote too. In these
    instructions you'll refer to it by the name upstream. If you don't
    have it, here's how you can add it:
    $ git remote add upstream https://github.com/ansible/ansible-documentation.git
  3. Ensure you have the latest copy of upstream and prepare a branch
    that will hold the backported code:
    $ git fetch upstream
    $ git checkout -b patchback/backports/stable-2.15/ba04139aaa7a178eed1ccda037f962bea1dd5594/pr-1315 upstream/stable-2.15
  4. Now, cherry-pick PR MUNI_TECH_WRITERS: Better documented local collections for playbooks #1129 #1315 contents into that branch:
    $ git cherry-pick -x ba04139aaa7a178eed1ccda037f962bea1dd5594
    If it'll yell at you with something like fatal: Commit ba04139aaa7a178eed1ccda037f962bea1dd5594 is a merge but no -m option was given., add -m 1 as follows instead:
    $ git cherry-pick -m1 -x ba04139aaa7a178eed1ccda037f962bea1dd5594
  5. At this point, you'll probably encounter some merge conflicts. You must
    resolve them in to preserve the patch from PR MUNI_TECH_WRITERS: Better documented local collections for playbooks #1129 #1315 as close to the
    original as possible.
  6. Push this branch to your fork on GitHub:
    $ git push origin patchback/backports/stable-2.15/ba04139aaa7a178eed1ccda037f962bea1dd5594/pr-1315
  7. Create a PR, ensure that the CI is green. If it's not — update it so that
    the tests and any other checks pass. This is it!
    Now relax and wait for the maintainers to process your pull request
    when they have some cycles to do reviews. Don't worry — they'll tell you if
    any improvements are necessary when the time comes!

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

Copy link

patchback bot commented Apr 30, 2024

Backport to stable-2.14: 💔 cherry-picking failed — conflicts found

❌ Failed to cleanly apply ba04139 on top of patchback/backports/stable-2.14/ba04139aaa7a178eed1ccda037f962bea1dd5594/pr-1315

Backporting merged PR #1315 into devel

  1. Ensure you have a local repo clone of your fork. Unless you cloned it
    from the upstream, this would be your origin remote.
  2. Make sure you have an upstream repo added as a remote too. In these
    instructions you'll refer to it by the name upstream. If you don't
    have it, here's how you can add it:
    $ git remote add upstream https://github.com/ansible/ansible-documentation.git
  3. Ensure you have the latest copy of upstream and prepare a branch
    that will hold the backported code:
    $ git fetch upstream
    $ git checkout -b patchback/backports/stable-2.14/ba04139aaa7a178eed1ccda037f962bea1dd5594/pr-1315 upstream/stable-2.14
  4. Now, cherry-pick PR MUNI_TECH_WRITERS: Better documented local collections for playbooks #1129 #1315 contents into that branch:
    $ git cherry-pick -x ba04139aaa7a178eed1ccda037f962bea1dd5594
    If it'll yell at you with something like fatal: Commit ba04139aaa7a178eed1ccda037f962bea1dd5594 is a merge but no -m option was given., add -m 1 as follows instead:
    $ git cherry-pick -m1 -x ba04139aaa7a178eed1ccda037f962bea1dd5594
  5. At this point, you'll probably encounter some merge conflicts. You must
    resolve them in to preserve the patch from PR MUNI_TECH_WRITERS: Better documented local collections for playbooks #1129 #1315 as close to the
    original as possible.
  6. Push this branch to your fork on GitHub:
    $ git push origin patchback/backports/stable-2.14/ba04139aaa7a178eed1ccda037f962bea1dd5594/pr-1315
  7. Create a PR, ensure that the CI is green. If it's not — update it so that
    the tests and any other checks pass. This is it!
    Now relax and wait for the maintainers to process your pull request
    when they have some cycles to do reviews. Don't worry — they'll tell you if
    any improvements are necessary when the time comes!

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

Copy link

patchback bot commented Apr 30, 2024

Backport to stable-2.16: 💚 backport PR created

✅ Backport PR branch: patchback/backports/stable-2.16/ba04139aaa7a178eed1ccda037f962bea1dd5594/pr-1315

Backported as #1380

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

patchback bot pushed a commit that referenced this pull request Apr 30, 2024
…1129 (#1315)

* feat: remove the reused snippet

* feat: add new shared_snippet and add description of local installation next to playbooks

* feat: add new section for installing collections locally

* fix: fix nox check error

* fix: remove shared txt files, add them to their included space, add an anchor to the new section

* fix: comments from the pull request

---------

Co-authored-by: Dávid Németh <[email protected]>
(cherry picked from commit ba04139)
Copy link

patchback bot commented Apr 30, 2024

Backport to stable-2.17: 💚 backport PR created

✅ Backport PR branch: patchback/backports/stable-2.17/ba04139aaa7a178eed1ccda037f962bea1dd5594/pr-1315

Backported as #1381

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

patchback bot pushed a commit that referenced this pull request Apr 30, 2024
…1129 (#1315)

* feat: remove the reused snippet

* feat: add new shared_snippet and add description of local installation next to playbooks

* feat: add new section for installing collections locally

* fix: fix nox check error

* fix: remove shared txt files, add them to their included space, add an anchor to the new section

* fix: comments from the pull request

---------

Co-authored-by: Dávid Németh <[email protected]>
(cherry picked from commit ba04139)
@samccann
Copy link
Contributor

This is great, thanks! I opened #1315 to review and remove some more of these shared snippets. I put the muni writers label on it, but I don't know if there's still time in the schedule for folks to take that one on.

oraNod added a commit that referenced this pull request May 1, 2024
…/ba04139aaa7a178eed1ccda037f962bea1dd5594/pr-1315

[PR #1315/ba04139a backport][stable-2.16] MUNI_TECH_WRITERS: Better documented local collections for playbooks #1129
oraNod added a commit that referenced this pull request May 1, 2024
…/ba04139aaa7a178eed1ccda037f962bea1dd5594/pr-1315

[PR #1315/ba04139a backport][stable-2.17] MUNI_TECH_WRITERS: Better documented local collections for playbooks #1129
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-2.14 Automatically create a backport for the stable-2.14 branch backport-2.15 Automatically create a backport for the stable-2.15 branch backport-2.16 Automatically create a backport for the stable-2.16 branch backport-2.17 Automatically create a backport for the stable-2.17 branch MUNI tech writers new_contributor This PR is the first contribution by a new community member.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants