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

Add Ansible instructions to CONTRIBUTING.md #379

Closed
smlambert opened this issue Jun 7, 2018 · 6 comments
Closed

Add Ansible instructions to CONTRIBUTING.md #379

smlambert opened this issue Jun 7, 2018 · 6 comments

Comments

@smlambert
Copy link
Contributor

Add a section to the contributing doc for users to be able to easily use the ansible scripts from this repo. This serves several purposes:

  • helps sanitize the ansible scripts
  • offloads some pressure from infra team with requests for rerunning ansible scripts
  • empowers others to be able to easily setup build/test environments (in both Adopt farm, or in their local machines and/or build farms)

A good goal to have a table containing succinct commands/steps for each platform that is supported.

@sxa sxa self-assigned this Jun 7, 2018
@pshipton
Copy link
Contributor

I tried the instructions. They suggest running ansible-playbook -s playbooks/AdoptOpenJDK_Linux_Playbook/main.yml however AdoptOpenJDK_Linux_Playbook doesn't exist. I tried running AdoptOpenJDK_Unix_Playbook/main.yml instead, but got the following error

ERROR! no action detected in task

The error appears to have been in '/root/openjdk-infrastructure/ansible/playbooks/AdoptOpenJDK_Unix_Playbook/roles/Common/tasks/main.yml': line 81, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

##############################
- name: Perform OS setup and configuration
  ^ here

@pshipton
Copy link
Contributor

pshipton commented Jun 18, 2018

I find the instructions confusing.
Step 2 suggests added ansible_connection=local to /etc/ansible/hosts
The Where can I run the playbooks? section suggests adding the following to /etc/ansible/hosts

[local]
127.0.0.1

It also mentions "Running ansible --version will display your Ansible configuration folder that contains the hosts file you can modify". This shows me the following. The first is a configuration file, not folder. The second is a folder but doesn't contain any hosts file.

ansible 2.0.0.2
  config file = /root/openjdk-infrastructure/ansible/ansible.cfg
  configured module search path = plugins/library

fyi my cd is ~/openjdk-infrastructure/ansible

@karianna
Copy link
Contributor

@pshipton I'm not sure what happened to the Linux Playbooks. IIRC @neomatrix369 put them there specifically so people could try out ansible on an Ubuntu Linux VM bought up by Vagrant if they didn't have their own host to try ansible out on. Sadly I can't see an obvious commit message that talks about removing those (or renaming them to Unix). So I suspect these instructions have bit rotted significantly.

Is there an ansible linter that we can run to check that syntax error?

@sxa
Copy link
Member

sxa commented Nov 6, 2018

Related: #532 #423

@Willsparker
Copy link
Contributor

A lot of this has been implemented via #1184 and #1066
Does anyone feel there's any other holes in the docs specific to Ansible ?

@karianna
Copy link
Contributor

karianna commented Sep 8, 2020

A lot of this has been implemented via #1184 and #1066
Does anyone feel there's any other holes in the docs specific to Ansible ?

I think we can close this and open up specific doc bugs.

@karianna karianna modified the milestones: Backlog, September 2020 Sep 8, 2020
@karianna karianna closed this as completed Sep 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants