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

Cluster Rollout to Baremetal #663

Open
loewa opened this issue Oct 18, 2019 · 2 comments
Open

Cluster Rollout to Baremetal #663

loewa opened this issue Oct 18, 2019 · 2 comments

Comments

@loewa
Copy link

loewa commented Oct 18, 2019

I would like to request a feature, where the elasticluster is simply using the given inventory for the rollout. This would be used in conjunction with a Ubuntu Maas bare metal provisioning.
A switch to skip the cloud deployment would be sufficient. An adequate inventory file needs to be provided to rollout the various roles.

What do you think? Anyone like this idea, to extend to baremetal?

@riccardomurri
Copy link
Contributor

Hello @loewa

thanks for your suggestion! It is actually already possible to use ElastiCluster's playbooks with a custom inventory, except it's not really advertised :-)

If you run elasticluster start (or setup) in full debug mode, you'll see a line like this in the logs:

    DEBUG Running Ansible command `ansible-playbook --private-key=.../.ssh/id_rsa .../elasticluster/elasticluster/share/playbooks/main.yml --inventory=.../.elasticluster/storage/spark.inventory --become --become-user=root -vv -e @extra_vars.yml` ...

To run on an existing cluster, you can simply:

  1. Replace the --inventory=.../.elasticluster/storage/cluster.inventory option with the path to an inventory file you provide: --inventory=/path/to/my/inventory.ini

  2. Provide an extra_vars.yml file containing the minimal amount of
    information that ElastiCluster playbooks need. It basically
    contains a YAML dump of the configuration; you can just have a look
    at any extra_vars.yml file created in a ElastiCluster working
    directory.

    Most keys are actually unused; a minimal extra_vars.yml file
    would look like this:

     elasticluster:
       cloud: {}
       nodes:
         # add one line per node
         master: {}
         worker001: {}
         # ...
       # replace with actual writable directory
       output_dir: /tmp
    

Might it be worth exposing this functionality through the command-line? If yes, how?

@loewa
Copy link
Author

loewa commented Oct 22, 2019 via email

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

No branches or pull requests

2 participants