无法在厨师中安装食谱

我刚开始了我的厨师之旅,我有两个Ubuntu的EC2实例运行,我已经安装了厨师客户端,也configuration了节点。 我试图运行一个入门的食谱,我正在关注这个wiki

knife cookbook site install getting-started 

但是,当我运行这个命令时,我在我的笔记本电脑上运行的Ubuntu 12.10中得到这个错误

 Installing getting-started to /var/chef/cookbooks ERROR: The default branch 'master' does not exist If this is a new git repo, make sure you have at least one commit before installing cookbooks 

我只是一个初学者,我无法弄清楚如何将一个简单的食谱部署到我的所有实例。

请帮助我

你必须

 > git add --all > git commit -a -m "updates" > git stash save 

您必须查看https://docs.chef.io/errors.html

我必须提交git / var / chef / cookbooks目录,首先添加一个readme.txt文件,所以实际上在git仓库中有一些东西。

之后,运行weblogic的安装

  sudo su - cd /var/chef/cookbook git init echo "New repo!" > readme.txt git add readme.txt git commit -a -m "initializing repo for chef" cd /home/your-username/chef-repo knife cookbook site install weblogic