First build of Node.JS application in TFS 2015 Update2 - javascript

I'm trying to build my first (Hello world) app in Node.js.
I was reading following tutorial:
https://www.visualstudio.com/en-us/docs/build/apps/node/nodejs-to-azure
My problem is that after clicking Queue Build I have following alert:
"No agent could be found with the following capabilities: npm, node.js".
And actually... this is true.
Where I can found a specific version to be installed on my TFS server?
Thank you for any help.

It was so easy :-).
I installed Node.Js from official site, and then I restarted VSO Agent in services.msc

Related

Strapi deployment

I am new to Strapi and I found it really good, I got my website in development mode locally working perfectly fine but I can not get my head around or find any good guide how to host Strapi on Debian Linux server, that I have, to be part of website and to access Strapi control panel for example mywebiste.com/admin so I can add content as blog posts directly by logging in to website admin part. Is that possible or I must use some services like Heroku. if someone can provide in short step by step what to do I will really appreciate that. I tried already create new Strapi project inside public_html folder but its not working
I use strapi on my project . I hosted strapi on pm2 package. Its very easy.
this documention https://docs.strapi.io/developer-docs/latest/guides/process-manager.html#install-pm2
don't forget add startup Ubuntu to pm2. Otherwise when Ubuntu started then not starting pm2
I suggest use Ubuntu.
Nginx Configuration
In order to deploy it to a Linux server, you need to install nginx, and set it up. You can find instructions in official documentation: https://docs.strapi.io/developer-docs/latest/setup-deployment-guides/deployment/optional-software/nginx-proxy.html#nginx-virtual-host

Launching on android WEBAPP with ADB

Is there a method to launch a web app using adb?
The web app is created using manifest.json and save on android using chrome browser.
I've tried to get the package name of the web application using adb shell pm list packages but nothing seems to match.
I want to launch my web app this way adb shell am start -n com.package.name/com.package.name.ActivityName
I've also tried this way adb shell am start -a android.intent.action.VIEW -d "url". This works but it is not what I am looking for.
Assuming you are coming from Javascript world (as you could have done this by looking at adb logs), this should be what you are looking for
adb shell am start -a com.google.android.apps.chrome.webapps.WebappManager.ACTION_START_WEBAPP -n com.android.chrome/org.chromium.chrome.browser.webapps.WebappLauncherActivity --es "org.chromium.chrome.browser.webapp_url" "{your_url}" --es "org.chromium.chrome.browser.webapp_mac" "{webapp_mac}"
Note that this url has to match the url/url-ending you have mentioned in the start_url that you have mentioned in the manifest.json of yours, else it will just open it as another chrome tab.
Another caveat here is you have to pass web app mac validation check, which is done by the core android class mentioned here - WebappAuthenticator
Chrome does not keep a store of valid URLs for installed web apps
(because it cannot know when any have been uninstalled). Therefore,
upon installation, it tells the Launcher a message authentication code
(MAC) along with the URL for the web app, and then Chrome can verify
the MAC when starting e.g. {#link #FullScreenActivity}. Chrome can
thus distinguish between legitimate, installed web apps and arbitrary
other URLs.
I gave it a shot to open one of the webapps I own. I gave up after a bit, getting lost in the cryptic algos. Maybe you will have some luck with it. All the best!!!

How can i start WebRTC sample application?

I've read a lot of documents about webRTC. Now I want to implement a sample application. I went through this useful stack overflow question.
And I got some client, a server in Javascript. I don't know how to start to see this demo . What are the steps should I take?
They explained like :
signaling technology: WebSockets
client: pure html/javascript
server: node.js, ws
last tested on: Firefox 40.0.2, Chrome 44.0.2403.157 m, Opera 31.0.1889.174
I understand this but I don't have much practical knowledge on this. These are my questions to setup this demo ?
Should I have a hosting account ? or can I use this with my
localhost ?
Next , where should I done this node.js, ws ? can I use with linux
machine and install npm and run the server.js file on that ?
How can I start client.js code on my Linux machine ?
Only server.js and client.js file is required to setup this
application ?
I am new with WebRTC too, but i hope my answer can satisfy you
You can use that demo in localhost
You can install nodejs in linux machine and run server.js on that.
To run the demo
run server.js through nodejs. Make sure you installed ws package first.
then you create a directory name static and put client-side code in there.
open your browser and go to localhost:80 to see the demo.
Yes, you just need 2 files to setup that application. The client file in Working Hello World WebRTC DataChannel Examples with Signaling Implemented is a html file not javascript.
You can see another tutorial in here: http://www.tutorialspoint.com/webrtc/webrtc_environment.htm
Sorry for my bad English.

Yeoman angularjs-cordova app - what is next?

I created the app according to this article: https://www.npmjs.com/package/generator-angularjs-cordova with yeoman and angularjs-cordova generator.
At creation app time, I was prompted to choose plugins that I want to use in my app.
I added next cordova plugins:
cordova.device, cordova.camera and cordova.vibration.
I run the app in browser with "grunt serve" command and it works!
Now, how can I get the device data?
I tried to check the device global object in app\js\application.js but it's undefined...
EDIT:
In firebug console I get the next errors:
"NetworkError: 404 Not Found - http://127.0.0.1:9000/cordova.js"
"ReferenceError: jQuery is not defined"
Why those modules were not connected automatically?
Where do I need to place the connection to the modules?
The answer is simple!
Device is not exists on the web browser.
When I run it on the android smartphone - everything is OK.
* Remember to copy all files from the app folder to the www folder!

installing tools for apache cordova for visual studio 2013 - CTP3

I am using visual studio 2013 ultimate running on a 64-bit windows 7 home premium. I wanted to write JavaScript code, when I tried to create a new JavaScript Project, It redirected me to Install the "Tools for Apache Cordova for Visual Studio". The installation completed successfully but showed an error in the end. The error was:
Joyent Node.js:
Invalid command line argument. Consult the Windows Installer SDK for detailed command line help. "
Now, I tried to create a new Project by selecting "JavaScript" form the "New Project" window. There was only one sub-option called "Blank App (Apache Cordova)". I selected it and clicked finish, bit then it showed all these errors:
We've detected issues with your system's environment configuration
Joyent node.js - software is missing from your computer.
Apple iTunes - software is missing from your computer.
WebSocket4Net - software is missing from you computer.
You may also have to configure it after installation.
I fixed the error related to joyent node.js and iTunes by manually installing the two, but the problem with the WebSocket4Net still persists.
I've already installed WebSocket4Net, using both the "vs2013_mda0.3" setup and manually. This has not worked. I even tried to repair the installation, by using the "vs2013_mda0.3" setup, but it made things even worse.
It was a problem with the installer, a bug maybe. The latest update (Visual Studio Update 5 (2013.5)) fixes these bugs. After updating, I didn't get any of these errors.
Also, TypeScript Projects cannot be created on Windows 7 using visual studio 2013 or lower. You have to either upgrade the OS to windows 8 or later.

Categories