Permalink
Browse files

[doc refactor] Continue work editing and refactoring content files fo…

…r blacksmith-based rendering
  • Loading branch information...
1 parent 13a5127 commit 670f9ab75f676357eba4801d7550ab7110b1b243 @indexzero indexzero committed Nov 26, 2012
@@ -1,7 +1,6 @@
-# Frequently Asked Questions
-<a name='faq'></a>
-
+<hr>
**For more information about pricing, see [the pricing FAQ](http://nodejitsu.com/paas/faq.html).**
+<hr>
## "How do I reset my password?"
@@ -11,20 +10,24 @@ One way is to use jitsu. Simply type:
where `:username` is your username. Alternately, go to <http://develop.nodejitsu.com/> and click the "forgot password" link, where you will be prompted for your username. Either process will send you an email with further instructions.
+<hr>
## "Is there a cheatsheet somewhere?"
There sure is! Check out <http://cheatsheet.nodejitsu.com>.
+<hr>
## "How are programs kept alive? Do I need to use Forever?"
Nodejitsu's cloud services watch your programs for you! You shouldn't have to do anything special to keep your apps running, much less use Forever.
+<hr>
## "How can I make my app use a port other than port 80?"
Connecting to other servers using arbitrary ports requires no special considerations. However, *listening* for outside connections is currently limited to port 80 on the Nodejitsu platform because we require http host headers for domain name resolution of subdomains. Consequentially, each subdomain may only host one listening service.
The ability to host TCP applications on nodejitsu and listen on non-80 ports is on our roadmap but has no associated timeline.
+<hr>
## "How do I make Koding work with jitsu?"
By default, Koding will not install packages globally, due to a permission error. You can fix this by setting the
@@ -36,16 +39,17 @@ And then you can install jitsu normally:
`npm i jitsu -g`
+<hr>
## "Can I use jitsu with Cloud9 IDE (<http://c9.io>)?"
Yes! Follow these steps to install jitsu.
1. Install the latest npm globally: `npm install -g npm`
-
2. Install the latest jitsu locally: `npm install jitsu`
Now you can use jitsu as usual. If you get error, try `npm rm -g jitsu && npm cache clean`.
+<hr>
## "How can I turn off the require-analyzer in jitsu? I want to manage my own dependencies!"
There are three ways to disable the require-analyzer:
@@ -54,24 +58,30 @@ There are three ways to disable the require-analyzer:
* Add `"analyze": false` to your package.json to disable it on a per-app basis.
* Set "analyze" to `false` in your `~/.jitsuconf` to disable it on a global level.
+<hr>
## "How Do I add my GitHub repository as a dependency?"
Use the following format: `https://github.com/:user/:repo/tarball/:branch`
+<hr>
## "Why won't this C++ addon compile?"
Many [C++ addons](http://nodejs.org/docs/latest/api/addons.html) require libraries that are not included in Nodejitsu's infrastructure by default. For example, [node-canvas](https://github.com/learnboost/node-canvas) requires [cairo](http://cairographics.org/). Nodejitsu has cairo and many other such libraries, but may not have some more obscure ones.
+<hr>
## "How do I specify which files not to bundle? How do I know what files are getting bundled?"
-Jitsu uses npm to bundle files, meaning that jitsu bundles files in exactly the same manner than npm bundles published modules. You can read about this in [npm's documentation](http://npmjs.org/doc/developers.html).
+`jitsu` uses npm to bundle files, meaning that jitsu bundles files in exactly the same manner than npm bundles published modules. You can read about this in [npm's documentation](http://npmjs.org/doc/developers.html).
In more detail: npm uses a file called `.npmignore`, which should contain a list of files and folders to ignore for the purpose of bundling. If this file does not exist, npm will use git's ignore file, called `.gitignore`, instead. This means that, if you want to bundle files that are ignored by git, you should create an `.npmignore` even if it's blank.
Finally, jitsu has the ability to bundle your app without deploying with the `jitsu package create` command. You can use this to make sure that the resulting .tgz file is as you expect.
+<hr>
## "How do I fix `Error: package.json error: can't find starting script`?"
Nodejitsu requires a starting script in the package.json to know which script to run to start your application. You need to make sure that the scripts.start field in your package.json points to the correct starting script.
A common issue is using "node app" as the value of scripts.start in your package.json. This won't work on Nodejitsu because the file extension is not specified. You'll need to do something along the lines of "node app.js".
+
+[meta:title]: <> (FAQ)
@@ -1,101 +1,75 @@
-# Hello World: A Tutorial
-<a name="hiworld"></a>
-
-In this tutorial, you will write a simple "hello world" web application in
-Node.js, and then deploy it using jitsu, Nodejitsu's command line interface.
-
-Before you get started, you should have
-[node.js](https://github.com/joyent/node/wiki) installed. If you are using
-a node.js version older than v0.6.0 (not recommended) you will also need to
-separately install
-[Node Package Manager](https://github.com/isaacs/npm/#readme) (npm).
+In this tutorial, you will write a simple "hello world" web application in Node.js, and then deploy it using jitsu, Nodejitsu's command line interface. Before you get started, you should have [node.js](https://github.com/joyent/node/wiki) installed.
+<hr>
## Write A Server
-Let's start with a very basic Node.js http server. Create a folder called
-`myapp/` and then create a file inside the folder called `server.js`. Inside
-this file, write the following code:
+Let's start with a very basic Node.js http server. Create a folder called `myapp/` and then create a file inside the folder called `server.js`. Inside this file, write the following code:
-
- // requires node's http module
- var http = require('http');
-
- // creates a new httpServer instance
- http.createServer(function (req, res) {
- // this is the callback, or request handler for the httpServer
-
- // respond to the browser, write some headers so the
- // browser knows what type of content we are sending
- res.writeHead(200, {'Content-Type': 'text/html'});
-
- // write some content to the browser that your user will see
- res.write('<h1>hello, i know nodejitsu.</h1>');
+``` js
+ // requires node's http module
+ var http = require('http');
- // close the response
- res.end();
- }).listen(8080); // the server will listen on port 8080
-
-
-
-That's all the code you'll need for starters. Save your server and get ready to
-deploy!
-
-## Deploy with Jitsu
-
-In this tutorial, we will use [jitsu](http://github.com/nodejitsu/jitsu) to deploy
-our "hello world" application. Jitsu is a
-[Command Line Interface](http://en.wikipedia.org/wiki/Command-line_interface)
-for using Nodejitsu's platform. We've designed jitsu to be
-suitable for command line beginners, but still be powerful and extensible
-enough for production usage. If you aren't a fan of the command line or don't
-have terminal access you can still do app deployments through the
-[Nodejitsu Web Application](https://webops.nodejitsu.com/).
-
-If this is your first time deploying an application and you are eager to get
-started, we recommend using jitsu: it has a one line installer, it's
-self-documenting, and with it you'll be able to deploy your app in seconds.
-Plus, it's what's in the tutorial.
-
-## Installation
+ // creates a new httpServer instance
+ http.createServer(function (req, res) {
+ // this is the callback, or request handler for the httpServer
+
+ // respond to the browser, write some headers so the
+ // browser knows what type of content we are sending
+ res.writeHead(200, {'Content-Type': 'text/html'});
+
+ // write some content to the browser that your user will see
+ res.write('<h1>hello, i know nodejitsu.</h1>');
+
+ // close the response
+ res.end();
+ }).listen(8080); // the server will listen on port 8080
+```
+
+That's all the code you'll need for starters. Save your server and get ready todeploy!
+
+<hr>
+## Deploy with `jitsu`
+
+In this tutorial, we will use [jitsu](http://github.com/nodejitsu/jitsu) to deploy our "hello world" application. `jitsu` is a
+[Command Line Interface](http://en.wikipedia.org/wiki/Command-line_interface) for using Nodejitsu's platform. We've designed jitsu to be suitable for command line beginners, but still be powerful and extensible enough for production usage.
+
+If this is your first time deploying an application and you are eager to get started, we recommend using jitsu: it has a one line installer, it's self-documenting, and with it you'll be able to deploy your app in seconds. Plus, it's what's in the tutorial.
+
+### Installation
In order to install jitsu, open a terminal and type:
- [sudo] npm install jitsu -g
+```
+ [sudo] npm install jitsu -g
+````
-This command will install jitsu on your system; the `-g` makes npm install it
-globally, rather than as a local module.
+This command will install jitsu on your system; the `-g` makes npm install it globally, rather than as a local module.
![](https://github.com/nodejitsu/jitsu/raw/master/assets/jitsu.png)
-After installation, run the `jitsu` command from your command line. Since it's
-your first time using jitsu, you will be prompted to log in with an existing
-account or to create a new account.
+After installation, run the `jitsu` command from your command line. Since it's your first time using jitsu, you will be prompted to log in with an existing account or to create a new account.
![](https://github.com/nodejitsu/jitsu/raw/master/assets/login.png)
**Once you've logged in, you can deploy your app immediately.**
-## One Line Deployment
+### One Line Deployment
Open a terminal:
- cd /home/me/myapp
- jitsu deploy
-
-This will create a new application snapshot, generate and/or update project
-metadata, and deploy the project in the current path to
-[Nodejitsu](http://nodejitsu.com). If it's your first deployment, you'll be
-prompted for some information such as *<u>your app's name</u>*, its
-*<u>nodejitsu subdomain</u>*, and its *<u>start script</u>*. It's really easy and we promise it will
-only take a few seconds.
-
+```
+ cd /home/me/myapp
+ jitsu deploy
+```
- prompt: subdomain (myapp): myapp
- prompt: scripts.start (server.js):
- prompt: version (0.0.0):
+This will create a new application snapshot, generate and/or update project metadata, and deploy the project in the current path to [Nodejitsu](http://nodejitsu.com). If it's your first deployment, you'll be prompted for some information such as *<u>your app's name</u>*, its *<u>nodejitsu subdomain</u>*, and its *<u>start script</u>*. It's really easy and we promise it will only take a few seconds.
+```
+ prompt: subdomain (myapp): myapp
+ prompt: scripts.start (server.js):
+ prompt: version (0.0.0):
+```
-Now just open up your favorite browser, and go to
-`myapp.nodejitsu.com`. If everything has been set up correctly, then
-you, too, are on the path of nodejitsu!
+Now just open up your favorite browser, and go to `myapp.nodejitsu.com`. If everything has been set up correctly, then you too, are on the path of nodejitsu!
+[meta:title]: <> (Hello World: A Tutorial)
@@ -0,0 +1,2 @@
+
+[meta:title]: <> (Quickstart)
@@ -1,6 +1,3 @@
-# JSON API
-<a name='api'></a>
-
Nodejitsu provides a web API for developers who want to interact with the Nodejitsu platform programatically. This API is built to be [RESTful](http://en.wikipedia.org/wiki/Representational_State_Transfer) and communicates via [JSON]. The API is the most low-level way of interacting with the Nodejitsu platform. For most deployment scenarios you should use our command line tool, [jitsu], the [online administrative interface][webops], or use our [WebHook API][webhooks] when integrating with third party services.
## API Clients
@@ -184,4 +181,6 @@ Nodejitsu provides integrated logging solutions for your applications. Your logs
[webops]: https://webops.jit.su
[webhooks]: https://webhooks.nodejitsu.com
[nodejitsu]: http://nodejitsu.com
-[curl]: http://curl.haxx.se/
+[curl]: http://curl.haxx.se/
+
+[meta:title]: <> (JSON API)
@@ -1,55 +1,47 @@
-# Create Your Own Cloud With Haibu
-<a name='haibu'></a>
-
-Haibu is an open-source tool for spawning and managing several node.js
-applications on a single server. It's an integral part of Nodejitsu's
-production stack and is fully supported by a dedicated team of core node.js
-developers.
-
-By installing haibu, a user creates a development environment for themselves
-that mirrors the functionality of Nodejitsu's cloud platform! Any project that
-can be deployed on Nodejitsu can be ran by haibu.
-
-Haibu, which is Japanese for "hive", wraps node.js applications in a "carapace"
-and converts them into managed "drones". This approach allows haibu to directly
-interact with node.js applications and add all sorts of additional
-functionality. Haibu also contains a plugin system, so you can easily add even
-more functionality.
-
-Haibu builds on this concept of "drones" and exposes a robust and granular API
-for interacting with your node.js applications. At a low level, haibu's API is
-exposed as a RESTFul HTTP webservice. Any system that supports basic HTTP
-requests can communicate with a haibu server. If you are working in Node.js,
-haibu comes with a high-level Node.js API client.
+Haibu is an open-source tool for spawning and managing several node.js applications on a single server. It's an integral part of Nodejitsu's production stack and is fully supported by a dedicated team of core node.js developers.
+By installing haibu, a user creates a development environment for themselves that mirrors the functionality of Nodejitsu's cloud platform! Any project that can be deployed on Nodejitsu can be ran by haibu.
+
+Haibu, which is Japanese for "hive", wraps node.js applications in a "carapace" and converts them into managed "drones". This approach allows haibu to directly interact with node.js applications and add all sorts of additional functionality. Haibu also contains a plugin system, so you can easily add even more functionality.
+
+Haibu builds on this concept of "drones" and exposes a robust and granular API for interacting with your node.js applications. At a low level, haibu's API is exposed as a RESTFul HTTP webservice. Any system that supports basic HTTP requests can communicate with a haibu server. If you are working in Node.js, haibu comes with a high-level Node.js API client.
+
+<hr>
## Installation
- [sudo] npm install haibu -g
+```
+ [sudo] npm install haibu -g
+```
This will install haibu globally. You can also grab the source [directly from git](https://github.com/nodejitsu/haibu).
+<hr>
## Usage
To start haibu, all you have to do is run `haibu`:
- $ haibu
- __ __
- / /_ ______ __ / /_ __ __
- / __ \ / __ / / / / __ \ / / / /
- / / / / / /_/ / / / / /_/ / / /_/ /
- /_/ /_/ \__,_/ /_/ /_/\___/ \__,_/
-
- This is Open Source Software available under
- the MIT License.
-
- © 2010 Nodejitsu Inc.
- All Rights Reserved - www.nodejitsu.com
- haibu started @ 10.0.1.4 on port 9002 as api-server
- using plugins: config, exceptions, directories, log, http
-
-Haibu is an http server that exposes a REST api on port 9002. You can either
-access this API client with a regular HTTP client, or use our [haibu-api](https://github.com/nodejitsu/haibu-api/tree/master/node.js) module. Unfortunately, jitsu does not work with haibu's HTTP API, only the nodejitsu API.
-
+```
+ $ haibu
+ __ __
+ / /_ ______ __ / /_ __ __
+ / __ \ / __ / / / / __ \ / / / /
+ / / / / / /_/ / / / / /_/ / / /_/ /
+ /_/ /_/ \__,_/ /_/ /_/\___/ \__,_/
+
+ This is Open Source Software available under
+ the MIT License.
+
+ © 2010 Nodejitsu Inc.
+ All Rights Reserved - www.nodejitsu.com
+ haibu started @ 10.0.1.4 on port 9002 as api-server
+ using plugins: config, exceptions, directories, log, http
+```
+
+Haibu is an http server that exposes a REST api on port 9002. You can either access this API client with a regular HTTP client, or use our [haibu-api](https://github.com/nodejitsu/haibu-api/tree/master/node.js) module. Unfortunately, jitsu does not work with haibu's HTTP API, only the nodejitsu API.
+
+<hr>
## Additional Documentation
For more documentation, visit haibu's [github page](https://github.com/nodejitsu/haibu).
+
+[meta:title]: <> (Run it yourself With Haibu)
@@ -0,0 +1,2 @@
+
+[meta:title]: <> (Appendix)
@@ -1,6 +1,4 @@
-# Open Source Projects
-<a name='opensource'></a>
-
+<hr>
## Why Open Source
Most of Nodejitsu's technology stack is released as open source software. We
@@ -10,6 +8,7 @@ developers to review and improve our software. We've already received invaluable
contributions to our platform from developers who would have never seen our code
if we had not open-sourced it.
+<hr>
## Where To Find Our Projects
Nodejitsu hosts its open-source projects on [Github](https://github.com):
@@ -25,10 +24,12 @@ github, and if you want to create an account it's free. You will need a
[git client](http://git-scm.com/download) if you wish to clone any of our
code repositories.
+<hr>
## How To Contribute
Anyone can contribute to any of our open-source projects at any time.
Our [github site](https://github.com/nodejitsu) has the facilities for managing
patches, issues, code comments, version control, and just about anything else an
open source developer could need.
+[meta:title]: <> (Open Source Projects)
Oops, something went wrong. Retry.

0 comments on commit 670f9ab

Please sign in to comment.