Inlining fonts behind HTTP proxy

See original GitHub issue

🐞 Bug report

Command (mark with an x)

  • new
  • build
  • serve
  • test
  • e2e
  • generate
  • add
  • update
  • lint
  • extract-i18n
  • run
  • config
  • help
  • version
  • doc

Is this a regression?

No

Description

Since 11.0.0 there is the new feature to inline fonts. The problem is that it does not work behind HTTP proxy. We have correctly set HTTP_PROXY/http_proxy and NO_PROXY/no_proxy environment variables, but it is ignored.

🔬 Minimal Reproduction

There is no support for proxy: https://github.com/angular/angular-cli/blob/871dd6a434fdd9674905bde307b5ad79d5d59603/packages/angular_devkit/build_angular/src/utils/index-file/inline-fonts.ts#L107

There is not really a reproduction scenario. It fails only when running behind HTTP proxy.

🔥 Exception or Error


✖ Index html generation failed.
Inlining of fonts failed. An error has occurred while retrieving https://fonts.googleapis.com/icon?family=Material+Icons over the internet.
connect ETIMEDOUT 172.217.16.202:443

🌍 Your Environment


Angular CLI: 11.0.1
Node: 14.15.0
OS: linux x64

Angular: 
... 
Ivy Workspace: 

Package                      Version
------------------------------------------------------
@angular-devkit/architect    0.1100.1 (cli-only)
@angular-devkit/core         11.0.1 (cli-only)
@angular-devkit/schematics   11.0.1 (cli-only)
@schematics/angular          11.0.1 (cli-only)
@schematics/update           0.1100.1 (cli-only)

Anything else relevant?

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:16
  • Comments:17

github_iconTop GitHub Comments

github_iconTop Results From Across the Web

Angular 11 Inlining of fonts failed - Stack Overflow
It works for me behind the corporate proxy (don't forget http:// ): SET HTTPS_PROXY=http://<server-name>:<server-port> ng build.
Read more >
[Solved]-Angular 11 Inlining of fonts failed-angular.js
Coding example for the question Angular 11 Inlining of fonts failed-angular.js. ... It works for me behind the corporate proxy (don't forget http://...
Read more >
Resource inlining in JavaScript frameworks
Learn about the latest optimizations implemented in JavaScript frameworks in collaboration with project Aurora.
Read more >
ng build発生時のエラー(Inlining of fonts failed) プロキシ設定の ...
Inlining fonts behind HTTP proxy ... 🐞 Bug report Command (mark with an x) new build serve test e2e generate add update lint...
Read more >
Avoiding The Pitfalls Of Automatically Inlined Code
By printing the code already in the HTML output, inlining avoids render-blocking requests and executes the code before the page is rendered. As ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found