Comments (14)
Hi,
please can you confirm:
Which distribution and release?
that you're running from a git checkout of the cookbook?
the output of dpkg -l apt*
from apt.
and: dpkg -S /etc/apt/apt.conf.d/
from apt.
I am running on ec2, amazon linux Amazon Linux 2014.09
I do not have dpkg installed
this is from chef
Fetching 'apt' from https://github.com/opscode-cookbooks/apt.git (at master)
Using apt (2.6.1) from https://github.com/opscode-cookbooks/apt.git (at master)
Vendoring apt (2.6.1) to /opt/aws/opsworks/current/berkshelf-cookbooks/apt
[2015-03-23T14:42:34+00:00] INFO: Processing file[/var/lib/apt/periodic/update-success-stamp] action nothing (apt::default line 30)
[2015-03-23T14:42:34+00:00] INFO: Processing cookbook_file[/etc/apt/apt.conf.d/15update-stamp] action create (apt::default line 53)
Error executing action create
on resource 'cookbook_file[/etc/apt/apt.conf.d/15update-stamp]'
Chef::Exceptions::EnclosingDirectoryDoesNotExist
Parent directory /etc/apt/apt.conf.d does not exist.
Resource Declaration:
In /var/lib/aws/opsworks/cache.stage2/cookbooks/apt/recipes/default.rb
53: cookbook_file '/etc/apt/apt.conf.d/15update-stamp' do
54: source '15update-stamp'
55: end
56:
Compiled Resource:
Declared in /var/lib/aws/opsworks/cache.stage2/cookbooks/apt/recipes/default.rb:53:in `from_file'
cookbook_file("/etc/apt/apt.conf.d/15update-stamp") do
provider Chef::Provider::CookbookFile
action "create"
retries 0
retry_delay 2
path "/etc/apt/apt.conf.d/15update-stamp"
backup 5
atomic_update true
source "15update-stamp"
cookbook_name "apt"
recipe_name "default"
end
from apt.
OK. Well, the fix is easy. But can I ask what you're using the apt cookbook for on amazon linux?
from apt.
deploying elastic search
The example we started from had apt in the recipes list for setup
from apt.
Well, you shouldn't see this error any more. But I can't imagine that including the apt cookbook on amazon linux is doing much besides making your converges more fragile and slower.
from apt.
here is the article, it's on AWS Blog
http://blogs.aws.amazon.com/application-management/post/Tx3MEVKS0A4G7R5/Deploying-Elasticsearch-with-OpsWorks
from apt.
Thanks. That blog seems to be a little incorrect, as they're using a cookbook that's not intended for their distribution of linux. If they were using debian or ubuntu, they'd want to have the apt cookbook. But since the blog post is using a red hat derived distribution, like centos or amazon linux, they ought to be using the yum cookbook.
I'd recommend you remove the apt cookbook from your deployment and test it.
from apt.
Hi @thommay ,
I'm not sure if it isn't my mistake, but I think there is still some issue when running apt on amazon( I know it doesn`t make any sense to run it, but some cookbook is doing it.
I have APT version 2.7.0 and:
Recipe: apt::default
* file[/var/lib/apt/periodic/update-success-stamp] action nothing (skipped due to action :nothing)
* directory[/etc/apt/apt.conf.d] action create (up to date)
* cookbook_file[/etc/apt/apt.conf.d/15update-stamp] action create
================================================================================
Error executing action `create` on resource 'cookbook_file[/etc/apt/apt.conf.d/15update-stamp]'
================================================================================
RuntimeError
------------
File files/default/15update-stamp does not exist for cookbook apt
Resource Declaration:
---------------------
# In /home/ec2-user/chef/cookbooks/apt-2.7.0/recipes/default.rb
57: cookbook_file '/etc/apt/apt.conf.d/15update-stamp' do
58: source '15update-stamp'
59: end
60:
Compiled Resource:
------------------
# Declared in /home/ec2-user/chef/cookbooks/apt-2.7.0/recipes/default.rb:57:in `from_file'
from apt.
well, I just checked that the file exists in the download from supermarket. If you look in /home/ec2-user/chef/cookbooks/apt-2.7.0/files/default
what do you see? (I'd strongly recommend you fix your cookbook though.)
from apt.
15update-stamp is there actually, I also tried copiing it into etc/apt/apt.conf.d/ directly, but it didn't help either.
Also it isn't in my cookbook, it is in dropwizard, and mongodb, but yeah I`ll probably remove it from those dependencies.
EDIT: apt-prox~v2.conf is in files/default as well, since you asked.
(Weird is though, I tried my cookbook on centos locally with chef-zero through kitchen. Also I tried it with chef-server and knife bootstrap, and it worked fine. But it does fail with chef-solo on amazon aws.)
from apt.
I removed apt dependency, and got same error for dropwizard cookbook, so I guess it's probably a chef-solo, or my setup issue... :/
from apt.
Ah, so it was my setup :) , cookbook has to be named "apt" not "apt-2.7.3",
Sorry...
from apt.
I seem to face this issue with apt version 2.7.0 installed via berkshelf. Ubuntu 12.04LTS. the file 15update-stamp
is however present in files/default
dir.
Chef Development Kit Version: 0.10.0
chef-client version: 12.5.1
berks version: 4.0.1
kitchen version: 1.4.2
Recipe: apt::default
* file[/var/lib/apt/periodic/update-success-stamp] action nothing (skipped due to action :nothing)
* directory[/etc/apt/apt.conf.d] action create (up to date)
* cookbook_file[/etc/apt/apt.conf.d/15update-stamp] action create
================================================================================
Error executing action `create` on resource 'cookbook_file[/etc/apt/apt.conf.d/15update-stamp]'
================================================================================
RuntimeError
------------
File files/default/15update-stamp does not exist for cookbook apt
Resource Declaration:
---------------------
# In /opt/tm-infrastructure-chef/cookbooks/apt-2.7.0/recipes/default.rb
57: cookbook_file '/etc/apt/apt.conf.d/15update-stamp' do
58: source '15update-stamp'
59: end
60:
Compiled Resource:
------------------
# Declared in /opt/tm-infrastructure-chef/cookbooks/apt-2.7.0/recipes/default.rb:57:in `from_file'
cookbook_file("/etc/apt/apt.conf.d/15update-stamp") do
provider Chef::Provider::CookbookFile
action [:create]
retries 0
retry_delay 2
default_guard_interpreter :default
path "/etc/apt/apt.conf.d/15update-stamp"
backup 5
atomic_update true
source "15update-stamp"
declared_type :cookbook_file
cookbook_name :apt
recipe_name "default"
end
from apt.
Related Issues (20)
- apt_repository should honour the components values given, regardless of whether it's a ppa repository HOT 2
- Issue with v3.0.0 execute[apt-get update] HOT 5
- Truncating URI HOT 1
- apt_repository with key option creates ~/.gnupg owned by root in Vagrant's homedir HOT 2
- Add a warning on the README that https://github.com/chef/chef/pull/4782 supersedes this cookbook's `apt_repository` LWRP HOT 6
- execute[apt-cache gencaches] cannot be found in the resource collection HOT 6
- Apt update fails on Chef < 12.4.0 HOT 1
- Port apt_preference to chef/chef HOT 3
- Adding apt key doesn't work on Ubuntu 16.10 HOT 2
- apt update fails with "STDERR: E: The method driver /usr/lib/apt/methods/deb https could not be found."
- 6.1.0 removal of apt_update isn't actually in 6.1.0 supermarket code. HOT 3
- Request to add attribute allow-unauthenticated config option HOT 4
- apt_repository needs dirmngr installed HOT 1
- origins_patterns not applied for unattended_upgrades HOT 6
- master build fails with "undefined method contains"
- unattended-upgrades forced to check daily HOT 3
- apt_package resource should support source HOT 4
- Converge of apt::default fails as it tries to install version of a package that does not exist HOT 1
- Dependency Dashboard
- apt-key deprecated - use signed-by
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from apt.