Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run apt-get update before installing packages #1

Open
cespare opened this issue Apr 26, 2012 · 3 comments
Open

Run apt-get update before installing packages #1

cespare opened this issue Apr 26, 2012 · 3 comments

Comments

@cespare
Copy link
Collaborator

cespare commented Apr 26, 2012

ensure_packages should run apt-get update once, the first time it is used. This is because if the system hasn't been updated for a while, there could be server changes that will cause regular apt-get installs to fail, and will be fixed with an apt-get update.

@cespare
Copy link
Collaborator Author

cespare commented Apr 26, 2012

I suppose that alternatively, it could detect failure, run apt-get update, and retry once.

@philc
Copy link
Owner

philc commented Apr 26, 2012

I've been doing this as part of Fezzik, but it makes sense in Terraform. I'm worried about the overhead though -- on one of our ec2 machines it took 6.35s to run. How would the failure detection work?

@cespare
Copy link
Collaborator Author

cespare commented Oct 9, 2013

We could also allow the user to specify how stale the apt cache can be before an update is needed, like ansible does.

Another approach is to use ansible for this kind of stuff :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants