Firebase hosting : unable to verify first certificate - node.js

Is anybody here to help me with this ?
Whenever I try to initiate firebase hosting, I get this error.
Error is "Server Error. unable to verify the first certificate".
Two months passed but I haven't got the solution. Even I contacted Firebase Support Team, but they didn't help.
Please, help me.
Firebase-debug.log :
You're about to initialize a Firebase project in this directory:
F:\cv_web\build
[info]
=== Project Setup
[info]
[info] First, let's associate this project directory with a Firebase project.
[info] You can create multiple project aliases by running firebase use --add,
[info] but for now we'll just set up a default project.
[info]
[debug] [2019-12-04T21:11:12.162Z] >>> HTTP REQUEST GET https://firebase.googleapis.com/v1beta1/projects?pageSize=100
[debug] [2019-12-04T21:11:13.569Z] <<< HTTP RESPONSE 200
[info] i Using project abhijeetbharti-b42e1 (abhijeetbharti)
[info]
=== Hosting Setup
[info]
[info] Your public directory is the folder (relative to your project directory) that
[info] will contain Hosting assets to be uploaded with firebase deploy. If you
[info] have a build process for your assets, use your build's output directory.
[info]
[info] + Wrote build/404.html
[debug] [2019-12-04T21:11:25.792Z] >>> HTTP REQUEST GET https://www.gstatic.com/firebasejs/releases.json
[debug] [2019-12-04T21:11:27.490Z] Error: unable to verify the first certificate
at TLSSocket.onConnectSecure (_tls_wrap.js:1321:34)
at TLSSocket.emit (events.js:210:5)
at TLSSocket.EventEmitter.emit (domain.js:478:20)
at TLSSocket._finishInit (_tls_wrap.js:794:8)
at TLSWrap.ssl.onhandshakedone (_tls_wrap.js:608:12)
[error]
[error] Error: Server Error. unable to verify the first certificate

Related

Firebase login throws Error: spawn cmd ENOENT in NodeJS

I am trying to set up my Firebase TypeScript application on another system. When I execute firebase login, it throws the following exception:
[debug] [2020-07-10T12:35:28.031Z] ----------------------------------------------------------------------
[debug] [2020-07-10T12:35:28.034Z] Command: C:\Program Files\nodejs\node.exe C:\Users\gp\AppData\Roaming\npm\node_modules\firebase-tools\lib\bin\firebase.js login
[debug] [2020-07-10T12:35:28.034Z] CLI Version: 8.5.0
[debug] [2020-07-10T12:35:28.034Z] Platform: win32
[debug] [2020-07-10T12:35:28.035Z] Node Version: v12.18.2
[debug] [2020-07-10T12:35:28.036Z] Time: Fri Jul 10 2020 18:05:28 GMT+0530 (India Standard Time)
[debug] [2020-07-10T12:35:28.036Z] ----------------------------------------------------------------------
[debug] [2020-07-10T12:35:28.037Z]
[info] i Firebase optionally collects CLI usage and error reporting information to help improve our products. Data is collected in accordance with Google's privacy policy (https://policies.google.com/privacy) and is not used to identify you.
[info] i To change your data collection preference at any time, run `firebase logout` and log in again.
[info]
[info] Visit this URL on this device to log in:
[info] https://accounts.google.com/o/oauth2/auth?client_id=563584335869-fgrhgmd47bqnekij5i8b5pr03ho849e6.apps.googleusercontent.com&scope=email%20openid%20https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fcloudplatformprojects.readonly%20https%3A%2F%2Fwww.googleapis.com%2Fauth%2Ffirebase%20https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fcloud-platform&response_type=code&state=3839&redirect_uri=http%3A%2F%2Flocalhost%3A
[info]
[info] Waiting for authentication...
[debug] [2020-07-10T12:57:25.170Z] Error: spawn cmd ENOENT
at Process.ChildProcess._handle.onexit (internal/child_process.js:267:19)
at onErrorNT (internal/child_process.js:469:16)
at processTicksAndRejections (internal/process/task_queues.js:84:21)
[error]
[error] Error: An unexpected error has occurred.
On the new system, I am using the following software:
node v12.18.2
npm v6.14.5
On the old system, I was using the following software:
node v10.16.3
npm v6.12.0
I have also tried the following:
executing npm install -g firebase-tools#latest
executing all steps in a separate cmd running as admin.
Everything was working perfectly in my old workspace.
Fixed the issue by adding 'C:\Windows\System32' in my environment variable.

azure-webapp-maven-plugin config in Azure CLI doesn't execute

I am trying to follow the steps in https://spring.io/guides/gs/spring-boot-for-azure/. Under Config and deploy the app to Azure, when I run the "mvn com.microsoft.azure:azure-webapp-maven-plugin:1.8.0:config" command, the execution starts but doesn't complete. It stops where it is supposed to take user inputs but doesn't accept any values. Please find the execution logs below -
PS C:\Users\rthan\OneDrive\Documents\code\rest-service> mvn com.microsoft.azure:azure-webapp-maven-plugin:1.8.0:config
[INFO] Scanning for projects...
[INFO]
[INFO] -------------------< com.rainbowhomes:rest-service >--------------------
[INFO] Building rest-service 0.0.1-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- azure-webapp-maven-plugin:1.8.0:config (default-cli) # rest-service ---
[WARNING] The plugin may not work if you change the os of an existing webapp.
Define value for OS(Default: Linux):
1. linux [*]
2. windows
3. docker
Not sure what caused the issue, but if you want to deploy a Spring Boot app to Azure, you could refer to this doc, I successfully deployed the application via this doc last time, see this post.

Unable to init new firebase project from console

I'm trying to host my webapp on firebase and am currently running into this issue:
My order of operations:
(in root) > npm install -g firebase-tools
> firebase login
> $ npm run build
> cd dist
> firebase init iq18
> (select my desired app in FB dropdown)
> returns: Error: An unexpected error has occurred.
No matter what I try, after running init from my /dist directory, I can not get it to actually deploy to firebase. Full error from the logs:
[info]
=== Project Setup
[info]
[info] First, let's associate this project directory with a Firebase project.
[info] You can create multiple project aliases by running firebase use --add,
[info] but for now we'll just set up a default project.
[info]
[debug] [2018-06-04T19:03:39.456Z] >>> HTTP REQUEST GET https://admin.firebase.com/v1/projects
Mon Jun 04 2018 15:03:39 GMT-0400 (EDT)
[debug] [2018-06-04T19:03:39.812Z] <<< HTTP RESPONSE 200
[info]
=== Iq17 Setup
[debug] [2018-06-04T19:03:42.715Z] TypeError: features[nextFeature] is not a function
at init (/usr/local/lib/node_modules/firebase-tools/lib/init/index.js:13:49)
at /usr/local/lib/node_modules/firebase-tools/lib/init/index.js:14:14
at process._tickDomainCallback (internal/process/next_tick.js:135:7)
[error]
[error] Error: An unexpected error has occurred.
Things I've tried:
Deleted my /dist directory and rebuilt the app
Logged out of firebase and relogged in
Deleted the placeholder app from firebase account
Not quite sure what else I can do to fix this deploy issue.

Can't build production package

NPM version (npm --v): 5.4.2
Gulp version (gulp -v): CLI#1.4.0, Local#3.9.1
JHipster version: 4.6.1
Node version: 6.11.3
I'm unable to build a production package. Running the application completes without issues and the same goes for building a package with 'dev' profile.
For some reason when I run ".\mvnw -Pprod package" on the project's root directory I get this error:
[INFO] [17:15:22] Starting 'inject:vendor'...
[INFO] [17:15:22] Starting 'ngconstant:prod'...
[INFO] [17:15:22] Starting 'copy:languages'...
[ERROR] events.js:160
[ERROR] throw er; // Unhandled 'error' event
[ERROR] ^
[ERROR]
[ERROR] Error: File not found with singular glob: D:\GitHub\Agora\AgoraWeb\src\main\webapp\.htaccess
[ERROR] at Glob.<anonymous> (D:\GitHub\Agora\AgoraWeb\node_modules\glob-stream\index.js:41:11)
[ERROR] at Glob.g (events.js:292:16)
[ERROR] at emitOne (events.js:96:13)
[ERROR] at Glob.emit (events.js:188:7)
[ERROR] at Glob._finish (D:\GitHub\Agora\AgoraWeb\node_modules\glob-stream\node_modules\glob\glob.js:172:8)
[ERROR] at done (D:\GitHub\Agora\AgoraWeb\node_modules\glob-stream\node_modules\glob\glob.js:159:12)
[ERROR] at Glob._processSimple2 (D:\GitHub\Agora\AgoraWeb\node_modules\glob-stream\node_modules\glob\glob.js:652:12)
[ERROR] at D:\GitHub\Agora\AgoraWeb\node_modules\glob-stream\node_modules\glob\glob.js:640:10
[ERROR] at Glob._stat2 (D:\GitHub\Agora\AgoraWeb\node_modules\glob-stream\node_modules\glob\glob.js:736:12)
[ERROR] at lstatcb_ (D:\GitHub\Agora\AgoraWeb\node_modules\glob-stream\node_modules\glob\glob.js:728:12)
[ERROR] at RES (D:\GitHub\Agora\AgoraWeb\node_modules\inflight\inflight.js:31:16)
[ERROR] at f (D:\GitHub\Agora\AgoraWeb\node_modules\once\once.js:25:25)
[ERROR] at FSReqWrap.oncomplete (fs.js:123:15)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 25.257 s
[INFO] Finished at: 2017-10-02T17:15:22+02:00
[INFO] Final Memory: 38M/467M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.github.eirslett:frontend-maven-plugin:1.4:gulp (gulp build) on project agora: Failed to run task: 'gulp build --no-notification' failed. org.apache.commons.exec.ExecuteException: Process exited with an error: 1 (Exit value: 1) -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
I understand what it's telling me, I'm missing the .htaccess file but I never needed it before. I recently moved the project from my main drive to the backup drive and since then I can't generate a production package.
If I create an empty ".htaccess" where gulp needs it I get this other error:
[INFO] [17:21:43] Finished 'inject:app' after 2.94 s
[INFO] [17:21:43] Starting 'inject:troubleshoot'...
[INFO] [17:21:43] 'inject:troubleshoot' errored after 1.01 ms
[INFO] [17:21:43] Error: Invalid glob argument:
[INFO] at Gulp.src (D:\GitHub\Agora\AgoraWeb\node_modules\vinyl-fs\lib\src\index.js:32:11)
[INFO] at Gulp.troubleshoot (D:\GitHub\Agora\AgoraWeb\gulp\inject.js:61:27)
[INFO] at module.exports (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\lib\runTask.js:34:7)
[INFO] at Gulp.Orchestrator._runTask (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\index.js:273:3)
[INFO] at Gulp.Orchestrator._runStep (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\index.js:214:10)
[INFO] at Gulp.Orchestrator.start (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\index.js:134:8)
[INFO] at runNextSet (D:\GitHub\Agora\AgoraWeb\node_modules\run-sequence\index.js:123:15)
[INFO] at Gulp.onTaskEnd (D:\GitHub\Agora\AgoraWeb\node_modules\run-sequence\index.js:101:4)
[INFO] at emitOne (events.js:101:20)
[INFO] at Gulp.emit (events.js:188:7)
[INFO] at Gulp.Orchestrator._emitTaskDone (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\index.js:264:8)
[INFO] at D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\index.js:275:23
[INFO] at finish (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\lib\runTask.js:21:8)
[INFO] at D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\lib\runTask.js:52:4
[INFO] at f (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\node_modules\once\once.js:17:25)
[INFO] at DestroyableTransform.onend (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\node_modules\end-of-stream\index.js:31:18)
[INFO] [17:21:43] 'build' errored after 3.98 s
[INFO] [17:21:43] Error in plugin 'run-sequence(inject:troubleshoot)'
[INFO] Message:
[INFO] Invalid glob argument:
[INFO] Stack:
[INFO] Error: Invalid glob argument:
[INFO] at Gulp.src (D:\GitHub\Agora\AgoraWeb\node_modules\vinyl-fs\lib\src\index.js:32:11)
[INFO] at Gulp.troubleshoot (D:\GitHub\Agora\AgoraWeb\gulp\inject.js:61:27)
[INFO] at module.exports (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\lib\runTask.js:34:7)
[INFO] at Gulp.Orchestrator._runTask (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\index.js:273:3)
[INFO] at Gulp.Orchestrator._runStep (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\index.js:214:10)
[INFO] at Gulp.Orchestrator.start (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\index.js:134:8)
[INFO] at runNextSet (D:\GitHub\Agora\AgoraWeb\node_modules\run-sequence\index.js:123:15)
[INFO] at Gulp.onTaskEnd (D:\GitHub\Agora\AgoraWeb\node_modules\run-sequence\index.js:101:4)
[INFO] at emitOne (events.js:101:20)
[INFO] at Gulp.emit (events.js:188:7)
[INFO] at Gulp.Orchestrator._emitTaskDone (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\index.js:264:8)
[INFO] at D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\index.js:275:23
[INFO] at finish (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\lib\runTask.js:21:8)
[INFO] at D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\lib\runTask.js:52:4
[INFO] at f (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\node_modules\once\once.js:17:25)
[INFO] at DestroyableTransform.onend (D:\GitHub\Agora\AgoraWeb\node_modules\orchestrator\node_modules\end-of-stream\index.js:31:18)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 17.220 s
[INFO] Finished at: 2017-10-02T17:21:43+02:00
[INFO] Final Memory: 36M/367M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.github.eirslett:frontend-maven-plugin:1.4:gulp (gulp build) on project agora: Failed to run task: 'gulp build --no-notification' failed. org.apache.commons.exec.ExecuteException: Process exited with an error: 1 (Exit value: 1) -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
(Sorry for the long logs)
I have tried many things, including the full deletion of the repo and cloning it again. I've also tried clearing NPM's cache as advised in this answer. At this point I don't know what else to try.
Thanks !!
I have solved this problem. Gaël Marziou put me in the right track to investigate conflicting versions of node or gulp.
After testing various versions of node, both local and global I tried disabling gulp tasks one by one, none of them helped me really even though the error messages did change. So I tried messing with gulp versions, and that was the answer.
I solved my problem by changing the following line in my package.json:
"gulp": "^3.9.1",
to this:
"gulp": "3.9.1",
And now everything builds perfectly.
Thank you very much :)

Connecting Blob to Spark failing

I am trying to connect spark coming in Hortonworks 2.4 distribution to Azure Blob storage and I was getting error "wasb filesystem not recognized " . I checked and many suggested downloading azure-sdk-for-java and creating package.
I am trying to create package using mvn but while running both mvn test and mvn package ; the process is getting hanged while testing. There is no error given , it just failed to return anything. I had changed testconfiguration.xml to reflect my blob account name. Below is the log files I am getting.
Is there something else that needs to be done to get jars ?
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Microsoft Azure Storage Client SDK 4.3.0
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-resources-plugin:2.5:resources (default-resources) # azure-storage ---
[debug] execute contextualize
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /home/adminhorton/kspark/azure-storage-java-master/src/main/resources
[INFO]
[INFO] --- maven-compiler-plugin:2.3.2:compile (default-compile) # azure-storage ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-resources-plugin:2.5:testResources (default-testResources) # azure-storage ---
[debug] execute contextualize
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 2 resources
[INFO]
[INFO] --- maven-compiler-plugin:2.3.2:testCompile (default-testCompile) # azure-storage ---
[INFO] Compiling 52 source files to /home/adminhorton/kspark/azure-storage-java-master/target/test-classes
[INFO]
[INFO] --- maven-surefire-plugin:2.13:test (default-test) # azure-storage ---
[INFO] Surefire report directory: /home/adminhorton/kspark/azure-storage-java-master/target/surefire-reports
T E S T S
parallel='classes', perCoreThreadCount=true, threadCount=2, useUnlimitedThreads=false
Running com.microsoft.azure.storage.StorageAccountTests
Tests run: 33, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.057 sec
Running com.microsoft.azure.storage.StorageUriTests
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.071 sec
com.microsoft.azure.storage.StorageAccountTests.txt
com.microsoft.azure.storage.StorageUriTests.txt
com.microsoft.azure.storage.StorageAccountTests.txt
com.microsoft.azure.storage.StorageUriTests.txt
According to your description, I am not sure you have configured your Storage Configuration rightly in your project. So I recommend you can follow these steps to check your configurations:
1.Create your Azure storage Account and set it in core-site.xml as this format:
<property>
<name>fs.azure.account.key.youraccount.blob.core.windows.net</name>
<value>YOUR ACCESS KEY</value>
</property>
2.Restart the HDP service and use the Hadoop fs –ls wasb://**.blob.core.windows.net/ to list the files in the container.
I strongly recommend you can refer to this blog how-to-configure-hortonworks-hdp-to-access-azure-windows-storage and official document.
Meanwhile , #Yuval provided the great sample about how to connect to Azure blob with Java SDK.

Resources