Composer安装\更新身份验证失败

ScayTrase

当我尝试从私有存储库安装依赖项时,出现以下错误:

> php.exe composer.phar update
Loading composer repositories with package information

  [RuntimeException]                                                           
  Failed to clone https://my.stash.repo/scm/lib/my-super-lib.git, could no  
  t read packages from it                                                      

  fatal: Authentication failed for 'https://my.stash.repo/scm/lib/my-super-lib.git/'                                                                   

update [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--lock] [--no-plugins] [--no-custom-installers] [--no-scripts] [--no-progress] [--with-dependencies] [-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [packages1] ... [packagesN]

Process finished with exit code 1 at 10:57:04.
Execution time: 1 996 ms.

相关composer.json部分如下:

   "require": {
        "php": ">=5.3.0",
        "scaytrase/my-super-lib": "1.1"
    },
    "repositories": [
        {
            "type": "vcs",
            "url":  "https://my.stash.repo/scm/lib/my-super-lib.git"
        }
    ],

如果我直接设置用户名和密码,例如

"url":  "https://username:[email protected]/scm/lib/my-super-lib.git"

作曲家的运作正常。但是我不想存储纯文本凭证。

有没有办法让作曲家每次询问用户名和密码?

仓库是Atlassian Stash,前面是https nginx(https和http都经过了测试)

Composer version 70a20ebcc19f1ea8ab0954a4fbdce208b30085e7 2014-03-12 16:07:58

编辑:

现在,我git clone --mirror自己执行操作以填充作曲家的缓存,然后像往常一样运行作曲家安装或作曲家更新(但是它说有时无法更新软件包信息)

代码

            $command = sprintf('git clone --mirror %s %s', escapeshellarg($this->url), escapeshellarg($this->repoDir));
            if (0 !== $this->process->execute($command, $output)) {
                $output = $this->process->getErrorOutput();

                if (0 !== $this->process->execute('git --version', $ignoredOutput)) {
                    throw new \RuntimeException('Failed to clone '.$this->url.', git was not found, check that it is installed and in your PATH env.' . "\n\n" . $this->process->getErrorOutput());
                }

                throw new \RuntimeException('Failed to clone '.$this->url.', could not read packages from it' . "\n\n" .$output);
            }

手册git clone --mirror工作正常,并要求我提供证书。但是作曲家(显然会执行相同的命令)-不会。

编辑2

我正在使用的似乎是PHP Storm 8 EAP问题。最新的稳定版本要求在验证正确composer install,而在验证期间不需要composer update

ScayTrase

似乎是最新的PhpStorm 8 EAP 134.1456中的错误。PhpStorm 7.1.3可与命令行(相同行为)之类的作曲器一起使用,并且运行composer install良好(但不行composer update,但命令行也无法通过此操作)。

I'have提交错误报告

编辑

我的错误报告给作曲家已经换成这个

UPD2

目前,问题完全是不实际的。Composer可以正确处理身份验证,还要求将凭据存储在COMPOSER_HOME/auth.json

本文收集自互联网,转载请注明来源。

如有侵权,请联系[email protected] 删除。

编辑于
0

我来说两句

0条评论
登录后参与评论

相关文章

来自分类Dev

Ecto Postgres安装错误密码身份验证失败

来自分类Dev

新的Arch安装上的身份验证失败

来自分类Dev

Freenx身份验证失败/安装错误?

来自分类Dev

SslStream身份验证失败

来自分类Dev

PHPMailer身份验证失败

来自分类Dev

Heroku身份验证失败

来自分类Dev

MongoDB身份验证失败?

来自分类Dev

Shiro身份验证失败

来自分类Dev

MongoError:身份验证失败

来自分类Dev

身份验证失败:omniauth

来自分类Dev

VNC身份验证失败

来自分类Dev

LightDM:“身份验证失败”

来自分类Dev

Paramiko身份验证失败/身份验证异常

来自分类Dev

使用 nestjs 身份验证时身份验证失败

来自分类Dev

SonarQube安装-Github身份验证插件失败,“ PKIX路径构建失败”

来自分类Dev

严重的:身份验证失败,Git Bash

来自分类Dev

基于JBoss表单的身份验证失败

来自分类Dev

RestSharp BitStamp身份验证失败

来自分类Dev

MongoDB-CR身份验证失败

来自分类Dev

FEDEX API,身份验证失败

来自分类Dev

身份验证失败-权限被EmberFire拒绝

来自分类Dev

ftp_login身份验证失败

来自分类Dev

SASL LDAP身份验证失败

来自分类Dev

ASP:JMail的SMTP身份验证失败

来自分类Dev

Web身份验证代理总是失败?

来自分类Dev

用户身份验证失败:null

来自分类Dev

git push身份验证失败

来自分类Dev

Payflow报告“用户身份验证失败”

来自分类Dev

来自Capistrano的Postgresql身份验证失败