Ошибка кулинарной книги AWS OpsWorks в s3.rb

Я создавал стек AWS OpsWorks, а затем получил эту ошибку:

[2016-02-23T00:25:05+00:00] INFO: Processing execute[create git repository] action run (opsworks_custom_cookbooks::checkout line 58)

================================================================================
Error executing action `run` on resource 'execute[create git repository]'
================================================================================


Mixlib::ShellOut::ShellCommandFailed
------------------------------------
Expected process to exit with [0], but received '1'
---- Begin output of find . -type d -name .git -exec rm -rf {} \;; find . -type f -name .gitignore -exec rm -f {} \;; git init; git add .; git config user.name 'AWS OpsWorks'; git config user.email 'root@localhost'; git commit -m 'Create temporary repository from downloaded contents.' ----
STDOUT: Initialized empty Git repository in /tmp/opsworks20160223-1192-1ursi1c/archive.d/.git/
On branch master

Initial commit

nothing to commit
STDERR: 
---- End output of find . -type d -name .git -exec rm -rf {} \;; find . -type f -name .gitignore -exec rm -f {} \;; git init; git add .; git config user.name 'AWS OpsWorks'; git config user.email 'root@localhost'; git commit -m 'Create temporary repository from downloaded contents.' ----
Ran find . -type d -name .git -exec rm -rf {} \;; find . -type f -name .gitignore -exec rm -f {} \;; git init; git add .; git config user.name 'AWS OpsWorks'; git config user.email 'root@localhost'; git commit -m 'Create temporary repository from downloaded contents.' returned 1


Resource Declaration:
---------------------
# In /var/lib/aws/opsworks/cache.stage1/cookbooks/scm_helper/libraries/s3.rb

58:         execute 'create git repository' do
59:           cwd "#{tmpdir}/archive.d"
60:           command "find . -type d -name .git -exec rm -rf {} \\;; find . -type f -name .gitignore -exec rm -f {} \\;; git init; git add .; git config user.name 'AWS OpsWorks'; git config user.email 'root@localhost'; git commit -m 'Create temporary repository from downloaded contents.'"
61:         end
62: 
63:         "#{tmpdir}/archive.d"
64:       end
65:     end



Compiled Resource:
------------------
# Declared in /var/lib/aws/opsworks/cache.stage1/cookbooks/scm_helper/libraries/s3.rb:58:in `prepare_s3_checkouts'

execute("create git repository") do
action "run"
retries 0
retry_delay 2
command "find . -type d -name .git -exec rm -rf {} \\;; find . -type f -name .gitignore -exec rm -f {} \\;; git init; git add .; git config user.name 'AWS OpsWorks'; git config user.email 'root@localhost'; git commit -m 'Create temporary repository from downloaded contents.'"
backup 5
cwd "/tmp/opsworks20160223-1192-1ursi1c/archive.d"
returns 0
cookbook_name "opsworks_custom_cookbooks"
recipe_name "checkout"
end

Что-то не так с командой find, которая возвращает код 1, что приводит к сбою стека.

Что мне не хватает? Я новичок в Chef и Opsworks, что посоветуете? Спасибо


person Casper    schedule 23.02.2016    source источник
comment
Ничего общего с командой find IMO, но из такого чистого вакуума трудно сказать, что не так.   -  person Tensibai    schedule 23.02.2016
comment
Это была просто предварительная настройка AWS, ее невозможно отладить   -  person Casper    schedule 23.02.2016
comment
У OpsWorks есть свой способ использования шеф-повара, который не всегда легко отлаживать с обычными знаниями шеф-повара, пингуя @coderanger, который может лучше понять это.   -  person Tensibai    schedule 23.02.2016


Ответы (1)


Похоже, ваш файл архива S3 пуст. Вы можете попробовать еще раз с архивом S3 с файлами внутри него.

person Wenbing Li    schedule 24.03.2016