Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why does @angular/fire show: 'Server Error. certificate has expired', when I run: ng add @angular/fire?

Angular version:

@angular-devkit/architect         0.803.22
@angular-devkit/build-angular     0.803.22
@angular-devkit/build-optimizer   0.803.22
@angular-devkit/build-webpack     0.803.22
@angular-devkit/core              8.3.22
@angular-devkit/schematics        8.3.22
@angular/cli                      8.3.22
@angular/fire                     5.3.0
@ngtools/webpack                  8.3.22
@schematics/angular               8.3.22
@schematics/update                0.803.22
rxjs                              6.4.0
typescript                        3.5.3
webpack                           4.39.2

1.What does 'Server Error. certificate has expired' mean?
2. How can I fix it?

~~~~EDIT~~~~

  • I erased my hard drive and installed a fresh operating system; still not working.
  • Opened an issue on the angular/angularfire git page: https://github.com/angular/angularfire/issues/2285
  • Found that the angular/fire package.JSON uses firebase tools 6.10.0 when firebase tools is up to 7.12.1 tried to fix by forcing the project to resolve a newer version of firebase-tools using resolutions in package.json with yarn at the suggestion of @wSedlacek on GitHub. Didn't work.
  • I changed the system time to before this issue started happening and it now works, issue still not fixed because it is a minor inconvenience to roll system time back to January 4th, 2020 every time you want to start a project.
  • @wSedlacek found that an HTTPS cert is expiring the due to the older version of firebase-tools in the package.json had a cert that expired on either January 5th 2020.

This issue might be related since it started happening at the same time : Why is angular fire saying I'm not logged in even though firebase tools says I am?

Here is a picture of the error: error picture

like image 242
Raphael Castro Avatar asked Jan 12 '20 03:01

Raphael Castro


1 Answers

This could be issue due to older version of Firebase CLI .
Try this command first npm i -g firebase-tools@latest and then run ng add @angular/fire

like image 188
Pushprajsinh Chudasama Avatar answered Sep 28 '22 22:09

Pushprajsinh Chudasama