纱线安装失败了" 403 Forbidden"在公司代理后面运行时出错

时间:2017-09-29 13:16:44

标签: maven proxy yarnpkg

当通过企业代理后面的maven-front-end插件运行纱线安装时,安装失败了目标" yarn"出现以下错误:

  

[ERROR]错误发生意外错误:   " https://registry.yarnpkg.com/@angular/forms/-/forms-4.4.3.tgz:   请求失败\" 403 Forbidden \""。

pom.xml的相应部分

    <plugin>
        <groupId>com.github.eirslett</groupId>
        <artifactId>frontend-maven-plugin</artifactId>
        <version>1.6</version>
        <executions>
          <execution>
            <id>install node and yarn</id>
            <phase>generate-resources</phase>
            <goals>
              <goal>install-node-and-yarn</goal>
            </goals>
            <configuration>
              <nodeVersion>${node.version}</nodeVersion>
              <yarnVersion>${yarn.version}</yarnVersion>
            </configuration>
          </execution>
          <execution>
            <id>yarn set proxy config</id>
            <phase>generate-resources</phase>
            <goals>
              <goal>yarn</goal>
            </goals>
            <configuration>
              <arguments>config set strict-ssl false -g</arguments>
            </configuration>
          </execution>              
          <execution>
            <id>yarn install</id>
            <phase>generate-resources</phase>
            <goals>
              <goal>yarn</goal> --- Fails here
            </goals>
          </execution>
        </executions>
     </plugin>

任何人都可以指出可能是什么问题吗?这是日志:

  

[INFO] --- maven-clean-plugin:2.5:clean(default-clean)@ plmapp-web2

     

[INFO] --- frontend-maven-plugin:1.6:install-node-and-yarn(安装   节点和纱线)@ plmapp-web2 ---

     

[INFO] Found foundies:[optional {protocol =&#39; http&#39;,host =&#39; proxy&#39;,   port = 8080},optional_https {protocol =&#39; https&#39;,host =&#39; proxy&#39;,port = 8080}]

     

[INFO]已安装节点v6.11.3。 [INFO]纱线1.1.0是   已安装。

     

[INFO] Found foundies:[optional {protocol =&#39; http&#39;,host =&#39; proxy&#39;,   port = 8080},optional_https {protocol =&#39; https&#39;,host =&#39; proxy&#39;,port = 8080}]

     

[INFO]运行&#39; yarn config set strict-ssl false -g   --https-proxy = http://proxy:8080 --proxy = http://proxy:8080&#39;在/ tmp / plm / build-dir / PWA-PWA-JOB1 / plmapp-web2

     

[INFO] yarn config v1.1.0

     

[INFO]成功Set&#34; strict-ssl&#34;到&#34;假&#34;。 [INFO]完成0.09秒。

     

[INFO] [INFO] --- frontend-maven-plugin:1.6:纱线(纱线安装)@   plmapp-web2 ---

     

[INFO] Found foundies:[optional {protocol =&#39; http&#39;,host =&#39; proxy&#39;,   port = 8080},optional_https {protocol =&#39; https&#39;,host =&#39; proxy&#39;,port = 8080}]

     

[INFO]跑步&#39;纱线   --https-proxy = http://proxy:8080 --proxy = http://proxy:8080&#39;在/ tmp / plm / build-dir / PWA-PWA-JOB1 / plmapp-web2

     

[INFO] yarn install v1.1.0

     

[INFO] [1/4]解决方案......

     

[INFO] [2/4]获取包裹......

     

[INFO] info如果您认为这是一个错误,请打开错误报告   提供的信息   &#34; /tmp/plm/build-dir/PWA-PWA-JOB1/plmapp-web2/yarn-error.log" ;.

     

[INFO] info访问https://yarnpkg.com/en/docs/cli/install   有关此命令的文档。

     

[ERROR]错误发生意外错误:   &#34; https://registry.yarnpkg.com/@angular/forms/-/forms-4.4.3.tgz:   请求失败\&#34; 403 Forbidden \&#34;&#34;。

0 个答案:

没有答案