-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfirefox_nightly.yml
67 lines (61 loc) · 1.92 KB
/
firefox_nightly.yml
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
- name: Download Firefox Nightly
get_url:
url: "https://download.mozilla.org/?product=firefox-nightly-latest-ssl&os=linux64&lang=en-US"
dest: "/tmp/firefox-nightly.tar.bz2"
mode: "0755"
- name: Create directory for Firefox Nightly
file:
path: "/opt/firefox"
state: directory
mode: "0755"
owner: "{{ ansible_user_id }}"
group: "{{ ansible_user_id }}"
- name: Extract Firefox Nightly
unarchive:
src: "/tmp/firefox-nightly.tar.bz2"
dest: "/opt/firefox"
remote_src: yes
creates: "/opt/firefox/firefox-bin"
- name: Remove the downloaded tarball
file:
path: "/tmp/firefox-nightly.tar.bz2"
state: absent
- name: Create desktop entry for Firefox Nightly
copy:
dest: "~/.local/share/applications/firefox-nightly.desktop"
content: |
[Desktop Entry]
Version=1.0
Name=Firefox Nightly
Exec=env MOZ_ENABLE_WAYLAND=1 /opt/firefox/firefox-bin --name=firefox-nightly -P nightly %u
Icon=firefox-nightly
Terminal=false
Type=Application
MimeType=text/html;text/xml;application/xhtml+xml;application/vnd.mozilla.xul+xml;text/mml;x-scheme-handler/http;x-scheme-handler/https;
Categories=Network;WebBrowser;
Keywords=web;browser;internet;
StartupNotify=true
StartupWMClass=firefox-nightly
- name: Set up Firefox Nightly icons
block:
- name: Create icon directory
file:
path: "~/.local/share/icons/hicolor/{{ item }}/apps"
state: directory
with_items:
- "16x16"
- "32x32"
- "48x48"
- "64x64"
- "128x128"
- name: Link icons to correct path
file:
src: "/opt/firefox/browser/chrome/icons/default/default{{ item.split('x')[0] }}.png"
dest: "~/.local/share/icons/hicolor/{{ item }}/apps/firefox-nightly.png"
state: link
with_items:
- "16x16"
- "32x32"
- "48x48"
- "64x64"
- "128x128"