Coder Social home page Coder Social logo

Comments (4)

jborean93 avatar jborean93 commented on September 3, 2024

The PR #37 exposes all the connection options for LDAP into their own environment variables. Unfortunately lookups are disabled as part of any inventory plugin by default which is why your example won't work.

from microsoft.ad.

fabricesemti80 avatar fabricesemti80 commented on September 3, 2024

thanks.
so adding

export MICROSOFT_AD_LDAP_username="[email protected]"
export MICROSOFT_AD_LDAP_password="password"

Should be the way? (if so, a bit limiting since I manage 3x domains, but I can work with it), or can only do kinit? (As in your demo )

from microsoft.ad.

jborean93 avatar jborean93 commented on September 3, 2024

You'll have to use the upper case USERNAME and PASSWORD but yes.

(if so, a bit limiting since I manage 3x domains, but I can work with it

That is a good point, I'll have a closer look and see what can be done to enable lookups for the options. If it is I might just add a note saying this is possible but be careful of where the values are sourced from.

or can only do kinit

This should also be another option. At least with MIT krb5 you can use a directory ccache that contains multiple tickets for different principals. It should be possible to checkout all your krb5 tickets into the one ccache for your various principals and krb5 will select the correct ticket for the realm you are talking to. I have not tested this option but it should theoretically work.

from microsoft.ad.

jborean93 avatar jborean93 commented on September 3, 2024

I've talked about this internally with some other Ansible devs and right now the only real option is to set the option in your inventory plugin config. You can vault the whole yml file and Ansible will be able to decrypt it if provided with the vault secret at runtime.

A more practical solution is to follow ansible/ansible#79244 which is designed to allow templating on config options. This should enable things like the env lookup plugin to be used in your plugin config allowing you to do custom logic for deriving these values. Unfortunately I don't want to add even more custom handling to the inventory plugin itself so I'm hoping that PR will be ready shortly (bcoca said he was going to look into it again soon).

from microsoft.ad.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.