Code Monkey home page Code Monkey logo

Comments (9)

xorpaul avatar xorpaul commented on August 17, 2024

There is currently no support for any authentication for git repositories except SSH key authentication.

Do you know how r10k deals with this issue? Given that r10k usually does these things in sequence you should also get multiple password prompts.

from g10k.

TheMeier avatar TheMeier commented on August 17, 2024

the authentication works in g10k, its just when multiple authentications are needed that you get multiple password prompts simultaniously.
since r10k is serial there is no problem there

from g10k.

ntnn avatar ntnn commented on August 17, 2024

No tool acting with ssh sessions handles this.
The user is responsible for setting up the environment with e.g. GIT_ASKPASS or via shared connections.

from g10k.

TheMeier avatar TheMeier commented on August 17, 2024

This is https. If I could use ssh I wouldn't run into this issue

from g10k.

ntnn avatar ntnn commented on August 17, 2024

Same problem. Without g10k starting to handle HTTPS/SSH/... itself, rather than using libraries or executing external commands, there is no easy way to know if there is a prompt coming up waiting for input.

Another possibility (for https) would be to template u/p data into the uri before passing the puppetfile to g10k or to add a format which allows g10k to retrieve the credentials from somewhere to deliver as a payload for the specified uris.

E.g.

mod 'somemodule',
    :uri => 'https://some.uri/somemodule',
    :user => 'someuser',
    :password => 'somepass'

But I'm still not convinced that this is g10k's job to handle.

from g10k.

xorpaul avatar xorpaul commented on August 17, 2024

Yeah, I was thinking about adding some module attributes for this, which should be a quick fix.

Would that solve your problem?

from g10k.

xorpaul avatar xorpaul commented on August 17, 2024

Although if I keep thinking about it, something like

mod 'somemodule',
    :uri => 'https://some.uri/somemodule',
    :auth_file => '/home/foobar/.config/somemodule.auth'

should be better. Otherwise everyone with read access to the control repository can access the module.

from g10k.

TheMeier avatar TheMeier commented on August 17, 2024

Hmm, un this special scenario the repos are actually configured with uri: => 'git@...' but in an devel environment i use git config --global url."https://....".insteadOf git@... because the devel system is not allowed git-over-ssh.

So what actually might help me here would be passing in the auth (or better authfile) information via command line argument or environment variable.

from g10k.

xorpaul avatar xorpaul commented on August 17, 2024

Is the addition of the git module paramter :use_ssh_agent in #171 which skips the explicit ssh-add commands before each git command a possible solution for this or do you still want to enter the SSH key password?

from g10k.

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.