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

Ansible initiative #60

Closed
wants to merge 12 commits into from
Closed

Ansible initiative #60

wants to merge 12 commits into from

Conversation

saravanan30erd
Copy link
Contributor

@saravanan30erd saravanan30erd commented Sep 2, 2021

Description

Ansible scripts for opensearch setup

Issues Resolved

#14

Check List

  • Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@saravanan30erd
Copy link
Contributor Author

@peterzhuamazon

I have split the task into many phases, currently I have completed the single node opensearch setup.

I will work on below tasks in upcoming days,

  • opensearch multi-node cluster setup
  • opensearch dashbaords Installation
  • Performance analyzer plugin configuration

@saravanan30erd
Copy link
Contributor Author

saravanan30erd commented Sep 7, 2021

@peterzhuamazon

Completed the task for opensearch dashbaords Installation. I think we can start from here since pretty much I covered all which is necessary for single node installation.

@peterzhuamazon
Copy link
Member

peterzhuamazon commented Sep 8, 2021

Thanks @saravanan30erd sorry for the late responses.

@DandyDeveloper @TheAlgo Please review and comment when you have time.

xmx_value: 2

## Admin user credentials will be used for User & Roles management and cluster operations
admin_password: Test@123
Copy link
Member

Choose a reason for hiding this comment

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

@saravanan30erd can we encapsulate the credentials rather than adding it directly to yml?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ok

- name: Dashboards Install | create systemd service
template:
src: dashboards.service
dest: /etc/systemd/system/dashboards.service
Copy link
Member

Choose a reason for hiding this comment

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

@saravanan30erd Can we avoid hardcoding the paths?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ok

@peterzhuamazon
Copy link
Member

Adding @hyandell to co-proofread for any changes in the PR.

Copy link

@hyandell hyandell left a comment

Choose a reason for hiding this comment

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

Hi Saravanan,

As Ansible is GPL licensed and has many plugins under different licenses, did you base your work here on a pre-existing codebase? The concern with code that touches on other projects being that we don't want to confuse the licensing with different licenses that affect the overall licensing.

I did see that you had https://github.com/saravanan30erd/opendistro_standalone_installation - which I assume this is based partly on; I'm just concerned about any other repos either this PR or that earlier repo is based on.

@saravanan30erd
Copy link
Contributor Author

Hi @hyandell

I have created this opendistro repo from scratch, its not based on any external repo. Also this PR is using only few logics from opendistro one but major areas are created from scratch.

@saravanan30erd
Copy link
Contributor Author

@bbarani I have made the changes based on your feedback.

@peterzhuamazon
Copy link
Member

peterzhuamazon commented Sep 9, 2021

Thanks @saravanan30erd for the confirmation and the changes here.
Need more eyes to check this @smlx let me know if you can help with the approval.
I will test this in a few days as I am currently working on another OpenSearch releases.

@hyandell
Copy link

hyandell commented Sep 9, 2021

Hi @hyandell

I have created this opendistro repo from scratch, its not based on any external repo. Also this PR is using only few logics from opendistro one but major areas are created from scratch.

Thank you Saravanan :)

@DandyDeveloper
Copy link
Collaborator

@peterzhuamazon I think for this one, I don't see any problems, but I don't have the time to test this at this moment in time. So I'll pass on this specific PR for review.

@peterzhuamazon
Copy link
Member

Thanks @hyandell @DandyDeveloper for your inputs on this.
@saravanan30erd I will start the tests next week.
@TheAlgo please also take a look when you have time.

Thanks.

@@ -0,0 +1,45 @@
Deploy OpenSearch with Dashboards using Ansible
Copy link
Member

Choose a reason for hiding this comment

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

Nit : OpenSearch with OpenSearch Dashboards

server.host: "{{ hostvars[inventory_hostname]['ip'] }}"
opensearch.hosts: ["{{ os_nodes_dashboards }}"]
opensearch.ssl.verificationMode: none
opensearch.username: "kibanaserver"
Copy link
Member

Choose a reason for hiding this comment

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

Can we use a different name here , maybe dashboardserver?

Copy link
Contributor Author

@saravanan30erd saravanan30erd Sep 11, 2021

Choose a reason for hiding this comment

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

@TheAlgo kibanaserver is the name used in default configuration file from Opensearch dashboards source file(Tar file). Refer: https://opensearch.org/docs/dashboards/install/tls/

I suggest we should follow the default configuration from installation source to avoid confusions. May be it should be changed first in source files and official documentations then we can change it.

Copy link
Member

Choose a reason for hiding this comment

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

@peterzhuamazon Just curious , why are we using kibanaserver till now?

Copy link
Contributor Author

@saravanan30erd saravanan30erd Sep 11, 2021

Choose a reason for hiding this comment

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

@TheAlgo @peterzhuamazon kibanaserver is used in security plugin where it should be changed and then configuration. I raised the below PRs to fix this. Once this merged and released, then we can update here.

opensearch-project/security#1443
opensearch-project/opensearch-build#458

Copy link
Member

Choose a reason for hiding this comment

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

We are still in discussion with Security Team on this @saravanan30erd please hold on for some time before we make a decision on this.

Thanks.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@peterzhuamazon Sure, I think we can continue with kibanaserver here as of now.

Copy link
Member

Choose a reason for hiding this comment

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

We will keep this for now @TheAlgo.
@saravanan30erd please create an issue to track this.
Thanks.

@@ -0,0 +1,7 @@
---
# vars file for elasticsearch
Copy link
Member

Choose a reason for hiding this comment

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

Can we name all instances of elasticsearch to opensearch and kibana to dashboards here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ok

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@TheAlgo Done the changes.

@TheAlgo
Copy link
Member

TheAlgo commented Sep 11, 2021

@saravanan30erd I took a quick pass. PR looks good to me except some nitpicks regarding naming. Good work !!

@peterzhuamazon
Copy link
Member

peterzhuamazon commented Sep 13, 2021

Rename PR: opensearch-project/security#1443

@saravanan30erd
Copy link
Contributor Author

saravanan30erd commented Sep 13, 2021

@peterzhuamazon I think we will rename kibanaserver later in this project after its changed in security plugin and dashboard configuration, now we can continue the work here.

@peterzhuamazon
Copy link
Member

@peterzhuamazon I think we will rename kibanaserver later in this project after its changed in security plugin and dashboard configuration, now we can continue the work here.

I agree let us keep this in mind for now.
Can you create an issue to track this?
Thanks.

@saravanan30erd
Copy link
Contributor Author

@peterzhuamazon
Copy link
Member

Hi @saravanan30erd

We have recently created a ansible-playbook repo here: https://github.com/opensearch-project/ansible-playbook

To avoid migration issues like helm-charts, would you mind move this PR to there as well?
We can link this PR as reference.

This would be easier for people to access Ansible as a whole without mixing with other components.
You just need to add a pointer from devops repo to ansible repo once complete, so people knows where is ansible playbook.

This devops repo will serve as a central hub for all the OpenSearch Project related automations.

Let me know what you think.

Thanks.

@saravanan30erd
Copy link
Contributor Author

@peterzhuamazon Great, I will move this PR to new repo. Its better to maintain the separate repo as it gets complex when we add other features.

@peterzhuamazon
Copy link
Member

@peterzhuamazon Great, I will move this PR to new repo. Its better to maintain the separate repo as it gets complex when we add other features.

That is exactly the reason why we make the standalone repo.
Just take a bit time since Ansible itself is not Apache2 to start with, so we carefully review the use case and your PR content before we proceed with the repo creation.
Thanks.

@peterzhuamazon
Copy link
Member

Please close this PR once you raise the other one and link this one there.

@saravanan30erd
Copy link
Contributor Author

@peterzhuamazon I moved this PR to new ansible repo(opensearch-project/ansible-playbook#2).

@peterzhuamazon
Copy link
Member

peterzhuamazon commented Sep 16, 2021

Thanks @saravanan30erd I will close this one and lets work on the other one, I migrate opensearch-project/ansible-playbook#3 to ansible playbook repo as well.
I also create an new issue here #71 so you can take action to create pointer to point people from devops to ansible repo.

Thanks.

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.

6 participants