0

Here's our node configuration:

{
  "run_list": [
    "recipe[apt]",
    "recipe[build-essential]",
    [
      "rackbox"
    ]
  ],
  "rackbox": {
    "jenkins": {
      "job": "job1",
      "git_repo": "https://github.com/hayesmp/railsgirls-app.git",
      "command": "bundle exec rake",
      "ip_address": "192.237.181.154",
      "host": "subocean-southerner"
    },
    "ruby": {
      "versions": [
        "2.0.0-p247"
      ],
      "global_version": "2.0.0-p247"
    },
    "apps": {
      "unicorn": [
        {
          "appname": "app1",
          "hostname": "app1"
        }
      ]
    },
    "db_root_password": "iloverandompasswordsbutthiswilldo",
    "databases": {
      "postgresql": [
        {
          "database_name": "app1_production",
          "username": "app1",
          "password": "app1_pass"
        }
      ]
    }
  }
}

I'm just not sure where to insert the build essential compiletime = true attribute for my configuration.

This is the sample code for this stack overflow post: Chef: Why are resources in an "include_recipe" step being skipped?

name "myapp"
run_list(
  "recipe[build-essential]",
  "recipe[myapp]"
)
default_attributes(
  "build_essential" => {
    "compiletime" => true
  }
)
4

1 回答 1

1

将此粘贴到您的节点配置中:

"build_essential": {
    "compiletime": true
}

顺便说一句:你应该recipe[rackbox][rackbox]你的run_list

于 2013-10-04T01:17:38.610 回答