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

initial galaxy.yml #388

Merged
merged 10 commits into from
Jan 19, 2024
Merged

initial galaxy.yml #388

merged 10 commits into from
Jan 19, 2024

Conversation

egandro
Copy link
Contributor

@egandro egandro commented Oct 27, 2023

Proposed Changes

Add a galaxy.yml file to use as collection in bigger ansible projects.

Instructions:

  • create a file collections/requirements.yml
collections:
  - name: ansible.utils
  - name: community.general
  - name: ansible.posix
  - name: kubernetes.core
  - name: https://github.com/techno-tim/k3s-ansible.git
    type: git
    version: master
  • install via ansible-galaxy collection install -r ./collections/requirements.yml
  • every role is now available via the prefix techno_tim.k3s_ansible. e.g. techno_tim.k3s_ansible.lxc

Checklist

  • No code changed :)

@timothystewart6
Copy link
Contributor

this closes #198

@timothystewart6
Copy link
Contributor

lint, after that's fixed I will make some modifications to this file

@bdsoha
Copy link
Contributor

bdsoha commented Oct 29, 2023

@egandro Great PR.
IMO, might be nice to also add instructions to the README.md.

@egandro
Copy link
Contributor Author

egandro commented Oct 31, 2023

lint, after that's fixed I will make some modifications to this file

I have no clue how / what you want to lint me. The file was created with the ansible-galaxy command. There is really nothing we can make better, as all of the ansible galaxy files have this layout.

Please clearify what I should do.

@egandro
Copy link
Contributor Author

egandro commented Oct 31, 2023

@egandro Great PR. IMO, might be nice to also add instructions to the README.md.

Done. Please check if that is ok.

@timothystewart6
Copy link
Contributor

timothystewart6 commented Nov 1, 2023

lint, after that's fixed I will make some modifications to this file

I have no clue how / what you want to lint me. The file was created with the ansible-galaxy command. There is really nothing we can make better, as all of the ansible galaxy files have this layout.

Please clearify what I should do.

The build is failing because linting is failing. You can see it here

https://github.com/techno-tim/k3s-ansible/actions/runs/6707725821/job/18248637705

You can also check and fix these locally by using pre-commit https://github.com/techno-tim/k3s-ansible#pre-commit-hooks

@egandro
Copy link
Contributor Author

egandro commented Nov 1, 2023

The build is failing because linting is failing. You can see it here

I fixed it - by ignoring it :)

Copy link
Contributor

@bdsoha bdsoha left a comment

Choose a reason for hiding this comment

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

@egandro You can batch accept the suggestions.

galaxy.yml Outdated Show resolved Hide resolved
galaxy.yml Outdated Show resolved Hide resolved
galaxy.yml Outdated Show resolved Hide resolved
# A list of the collection's content authors. Can be just the name or in the format 'Full Name <email> (url)
# @nicks:irc/im.site#channel'
authors:
- your name <[email protected]>
Copy link
Contributor

@bdsoha bdsoha Nov 1, 2023

Choose a reason for hiding this comment

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

Should be filled out, probably by @timothystewart6.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes that's on Tim - I see no point for all authors putting emails here. That's all done with the git repo.

galaxy.yml Outdated Show resolved Hide resolved
egandro and others added 4 commits November 1, 2023 17:01
Co-authored-by: Dov Benyomin Sohacheski <[email protected]>
Co-authored-by: Dov Benyomin Sohacheski <[email protected]>
Co-authored-by: Dov Benyomin Sohacheski <[email protected]>
Co-authored-by: Dov Benyomin Sohacheski <[email protected]>
@egandro
Copy link
Contributor Author

egandro commented Nov 2, 2023

I have no idea what is breaking.

@timothystewart6
Copy link
Contributor

timothystewart6 commented Nov 2, 2023

I have no idea what is breaking.

Check the build logs, it's in there. Lint. The first step.

https://github.com/techno-tim/k3s-ansible/actions/runs/6722041556/job/18304808757?pr=388#step:7:149

@timothystewart6
Copy link
Contributor

@egandro

see this comment, it's the same thing. Just install pre-commit and you won't have these issues

#388 (comment)

@egandro
Copy link
Contributor Author

egandro commented Nov 2, 2023

@egandro

see this comment, it's the same thing. Just install pre-commit and you won't have these issues

#388 (comment)

Edit:

Legit ... "ansible-galaxy collection init techno_tim.k3s_ansible"

It creates 2 empty lines at the end of the galaxy.yml file ... it's "them" not "us".

@timothystewart6
Copy link
Contributor

timothystewart6 commented Nov 2, 2023

@egandro
see this comment, it's the same thing. Just install pre-commit and you won't have these issues
#388 (comment)

Edit:

Legit ... "ansible-galaxy collection init techno_tim.k3s_ansible"

It creates 2 empty lines at the end of the galaxy.yml file ... it's "them" not "us".

Well I have strict lint code style on this repo. It's pretty common with all code bases. Just because something else generated it does not mean it matches the target's code style.

again, just install pre-commit like the docs show and it will fix it

@egandro
Copy link
Contributor Author

egandro commented Nov 2, 2023

Well I have strict lint code style on this repo. It's pretty common with all code bases. Just because something else generated does not mean it matches the target's code style.

I totally understand the reasons and the why you are doing this. 100% legit and I agree.

I haven't got beaten up by ansible galaxy when trying to actually deploy it to their repos.

There might be good resons - not - to mess a lot with galaxy.yml (which is a fair guestimation) with my knowledge at this point.

@timothystewart6
Copy link
Contributor

timothystewart6 commented Nov 2, 2023

Well I have strict lint code style on this repo. It's pretty common with all code bases. Just because something else generated does not mean it matches the target's code style.

I totally understand the reasons and the why you are doing this. 100% legit and I agree.

I haven't got beaten up by ansible galaxy when trying to actually deploy it to their repos.

There might be good resons - not - to mess a lot with galaxy.yml (which is a fair guestimation) with my knowledge at this point.

yaml is yaml, fixing lint does not change the schema 😄

@timothystewart6
Copy link
Contributor

Thanks for sticking with it @egandro ! We're having some issues with the CI job running the rest of the tests. As soon as it's resolved I will merge this!

@timothystewart6 timothystewart6 merged commit 7669fd4 into techno-tim:master Jan 19, 2024
5 checks passed
@fresh2dev
Copy link

Thanks for this! Very helpful addition 👍

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.

4 participants