forked from anthonywalters/blogcode
-
Notifications
You must be signed in to change notification settings - Fork 0
/
google-chrome-stable.cf
39 lines (31 loc) · 1.14 KB
/
google-chrome-stable.cf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# See https://www.google.com/linuxrepositories/
# for an example promise bundle where apt sources and keys are added see here
# https://github.com/dnaeon/proxmoxve-cfengine-debian/blob/master/inputs/apt.cf
bundle agent install_latest_chrome
{
vars:
"chrome_repo_file" string => "/etc/apt/sources.list.d/google-chrome.list";
"add_key_command" string => "/usr/bin/apt-key add $(this.promise_dirname)/files/chromekey.txt";
packages:
debian::
"google-chrome-stable"
package_policy => "add",
package_method => generic;
files:
"$(chrome_repo_file)"
comment => "Define latest chrome source",
create => "true",
edit_defaults => empty,
perms => mo("644", "root"),
edit_line => add_chrome_repo,
classes => if_repaired("chrome_repo_added");
commands:
chrome_repo_added::
"$(add_key_command)";
}
bundle edit_line add_chrome_repo
{
insert_lines:
debian::
"deb http://dl.google.com/linux/chrome/deb/ stable main";
}