How do I get a job for working with Cloudbees Jenkins cloud construction?

I am trying to build Jenkins and work on Cloudbees. I successfully received NodeJs and my source was extracted from my BitBucket repository. I am trying to run my grunt task to minimize and merge my JS and CSS files before deployment. However, I cannot run the grunt program, even if it is successfully installed. Below is my build script:

curl -s -o use-node https://repository-cloudbees.forge.cloudbees.com/distributions/ci-addons/node/use-node
NODE_VERSION=0.8.0 \
 source ./use-node
npm install
npm install grunt
grunt

I tried installing grunt with the -g option and without it without success. Here is the console output for the rough part of my assembly:

+ npm install grunt
...
npm http GET https://registry.npmjs.org/grunt
npm http 200 https://registry.npmjs.org/grunt
...
grunt@0.4.0 node_modules/grunt
β”œβ”€β”€ dateformat@1.0.2-1.2.3
β”œβ”€β”€ colors@0.6.0-1
β”œβ”€β”€ hooker@0.2.3
β”œβ”€β”€ eventemitter2@0.4.11
β”œβ”€β”€ which@1.0.5
β”œβ”€β”€ iconv-lite@0.2.7
β”œβ”€β”€ coffee-script@1.3.3
β”œβ”€β”€ lodash@0.9.2
β”œβ”€β”€ nopt@1.0.10 (abbrev@1.0.4)
β”œβ”€β”€ rimraf@2.0.3 (graceful-fs@1.1.14)
β”œβ”€β”€ minimatch@0.2.11 (sigmund@1.0.0, lru-cache@2.2.2)
β”œβ”€β”€ glob@3.1.21 (graceful-fs@1.2.0, inherits@1.0.0)
β”œβ”€β”€ findup-sync@0.1.2 (lodash@1.0.1)
└── js-yaml@1.0.3 (argparse@0.1.12)
+ grunt
/tmp/hudson3382014549646667419.sh: line 8: grunt: command not found
Build step 'Execute shell' marked build as failure
Finished: FAILURE

Any ideas on how to make this work? Is this possible in Cloudbees?

+5
source share
2 answers

Grunt , , cli. , , cli grunt.

:

curl -s -o use-node https://repository-cloudbees.forge.cloudbees.com/distributions/ci-addons/node/use-node
NODE_VERSION=0.8.0 \
 source ./use-node
npm install
npm install grunt
npm install grunt-cli
export PATH=$PATH:node_modules/grunt-cli/bin/
grunt

, , , .

: http://gruntjs.com/getting-started

+5

jenkins, ssh/command line:

Jenkins

  • Git - git
  • Git - git
  • Git - git
  • GitHub API Plugin - github
  • NodeJS - javascript NodeJS npm

Git/Ant/ Maven/NodeJS

  • SERVER/jenkins/configure
Git
  • Git β†’ git β†’ git β†’ JGit
  • Git β†’ user.name = "Anthony Mckale", user.email Value = "anthony.mckale@bskyb.com"
NodeJS
  • NodeJS- > NodeJS β†’ NodeJS β†’ Name = "NodeJS 0.11.10", " ", " nodejs.org", "grunt-cli"

TADA

, , git/nodejs grunt

. wiki , grunt/ node jenkins β†’ https://wiki.jenkins-ci.org/display/JENKINS/NodeJS+Plugin

:)

no ssh loggin jenkins

0

All Articles