Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
- Loading branch information
Swaagie
committed
Mar 22, 2013
1 parent
cda9194
commit 597e3ae
Showing
3 changed files
with
119 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,9 @@ | ||
# Configuring Jitsu | ||
|
||
Also include temporary flags here, like --release | ||
|
||
## Flags | ||
|
||
### Release | ||
|
||
[meta:title]: <> (Configuration) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,95 @@ | ||
# Deploying your application | ||
|
||
Deploying your application is easy, it should only take a few seconds. | ||
`jitsu deploy` can be executed from the root of the application. This is where | ||
the *package.json* is located. Deployment will iterate through the following | ||
steps. | ||
|
||
1. Creates the application (if necessary) | ||
2. Creates or validates the package.json | ||
3. Packages and creates a new snapshot | ||
4. Stops the application (if necessary) | ||
5. Starts the application | ||
|
||
If you deploy for the first time, you'll be prompted for a subdomain and | ||
confirm the changes to [package.json][package]. By default your username will be | ||
prepended before the application name. After a succesful deploy `Nodejitsu ok` | ||
will be returned. | ||
|
||
``` | ||
info: Welcome to Nodejitsu [user] | ||
info: jitsu v0.12.8, node v0.8.22 | ||
info: It worked if it ends with Nodejitsu ok | ||
info: Executing command deploy | ||
warn: | ||
warn: The package.json file is missing required fields: | ||
warn: | ||
warn: Subdomain name | ||
warn: | ||
warn: Prompting user for required fields. | ||
warn: Press ^C at any time to quit. | ||
warn: | ||
prompt: Subdomain name: (subdomain) | ||
warn: About to write /var/www/test/helloworld/package.json | ||
... | ||
prompt: Is this ok?: (yes) | ||
info: Skipping require-analyzer because noanalyze option is set | ||
info: Checking app availability nodeapps-helloworld | ||
info: Creating app nodeapps-helloworld | ||
info: Creating snapshot 0.2.2 | ||
info: Uploading: [=============================] 100% | ||
info: Updating app nodeapps-helloworld | ||
info: Activating snapshot 0.2.2 for nodeapps-helloworld | ||
info: Starting app nodeapps-helloworld | ||
info: App nodeapps-helloworld is now started | ||
info: http://subdomain.nodejitsu.com on Port 80 | ||
info: Nodejitsu ok | ||
``` | ||
## Repeated deployments | ||
|
||
After an initial deploy you can redeploy as often as you would like. Note | ||
however that `jitsu` will ask to increase the package build version, e.g the | ||
`x` in `0.0.z-x` will be incremented. A manual increase of the patch `z` | ||
version will skip the step below and immediatly deploy your application. | ||
|
||
``` | ||
info: Welcome to Nodejitsu [user] | ||
info: jitsu v0.12.8, node v0.8.22 | ||
info: It worked if it ends with Nodejitsu ok | ||
info: Executing command apps deploy | ||
info: Skipping require-analyzer because noanalyze option is set | ||
info: Skipping require-analyzer because noanalyze option is set | ||
warn: Local package version appears to be old | ||
warn: The package.json version will be incremented automatically | ||
warn: About to write /var/www/test/helloworld/package.json | ||
... | ||
data: version: '0.2.2-1', | ||
... | ||
prompt: Is this ok?: (yes) | ||
``` | ||
|
||
You can also do `jitsu deploy --release patch` to force `jitsu deploy` to | ||
increase the patch version number. For more fine-grained versioning control | ||
see [jitsu config --release][release]. | ||
|
||
## Continuous integration | ||
|
||
Nodejitsu also supports continuous integration (CI) for deployments. For more | ||
information about CI check the [getting started page][gettingstarted] or | ||
relevant [handbook section][handbook]. | ||
|
||
## What is deployed | ||
|
||
Deploy will normally include all files, excluding the *node_modules* directory. | ||
The content that is deployed is dependant on `npm pack`. This command is | ||
executed by `jitsu deploy` and governs the snapshots we use for deployment. | ||
`npm pack` by default ignores files and folders starting with an dot, e.g. | ||
*.DS_Store*. In addition, it also takes *.gitignore* and *.npmignore* into | ||
account. More information about this subject can be found in the [FAQ][faq]. | ||
|
||
[release]: /jitsu/config/#release | ||
[faq]: /a-quickstart/faq/#why-is-the-subdirectory-or-its-content-not-deployed-to-nodejitsu | ||
[handbook]: /features/webhooks/ | ||
[gettingstarted]: https://www.nodejitsu.com/getting-started-with-github/ | ||
[package]: /appendix/package-json/ | ||
[meta:title]: <> (Deploying apps) |