added thunderbird state
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
014d7fba46
commit
a35e7dd298
10
states/thunderbird/defaults.yaml
Normal file
10
states/thunderbird/defaults.yaml
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
---
|
||||||
|
thunderbird:
|
||||||
|
enabled: true
|
||||||
|
mirror: "https://ftp.mozilla.org/pub/thunderbird/releases"
|
||||||
|
install_dir: "/usr/local/apps"
|
||||||
|
release_dir: "/usr/local/apps/releases"
|
||||||
|
dest_path: "/usr/local/apps/thunderbird-"
|
||||||
|
version: "125.0"
|
||||||
|
platform: "linux-x86_64"
|
||||||
|
lang: "en-GB"
|
3
states/thunderbird/init.sls
Normal file
3
states/thunderbird/init.sls
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
---
|
||||||
|
include:
|
||||||
|
- .install
|
53
states/thunderbird/install.sls
Normal file
53
states/thunderbird/install.sls
Normal file
@ -0,0 +1,53 @@
|
|||||||
|
---
|
||||||
|
{%- from "thunderbird/map.jinja" import thunderbird with context %}
|
||||||
|
thunderbird-archive-extract:
|
||||||
|
archive.extracted:
|
||||||
|
- name: {{ thunderbird.release_dir }}/thunderbird-{{ thunderbird.version }}
|
||||||
|
- source: {{ thunderbird.mirror }}/{{ thunderbird.version }}/{{ thunderbird.platform }}/{{ thunderbird.lang }}/thunderbird-{{ thunderbird.version }}.tar.bz2
|
||||||
|
- skip_verify: true
|
||||||
|
- archive_format: tar
|
||||||
|
- enforce_toplevel: false
|
||||||
|
- options: --strip 1
|
||||||
|
- keep: true
|
||||||
|
- if_missing: {{ thunderbird.release_dir }}/thunderbird-{{ thunderbird.version }}/thunderbird
|
||||||
|
|
||||||
|
thunderbird-symlink:
|
||||||
|
file.symlink:
|
||||||
|
- name: {{ thunderbird.install_dir }}/thunderbird
|
||||||
|
- target: {{ thunderbird.release_dir }}/thunderbird-{{ thunderbird.version }}
|
||||||
|
- force: true
|
||||||
|
- require:
|
||||||
|
- archive: thunderbird-archive-extract
|
||||||
|
|
||||||
|
thunderbird-bin-symlink:
|
||||||
|
file.symlink:
|
||||||
|
- name: /usr/bin/thunderbird
|
||||||
|
- target: {{ thunderbird.install_dir }}/thunderbird/thunderbird
|
||||||
|
- force: true
|
||||||
|
- require:
|
||||||
|
- archive: thunderbird-archive-extract
|
||||||
|
|
||||||
|
thunderbird-shortcut:
|
||||||
|
file.managed:
|
||||||
|
- name: /usr/share/applications/thunderbird.desktop
|
||||||
|
- source: salt://thunderbird/templates/thunderbird.desktop.j2
|
||||||
|
- user: root
|
||||||
|
- group: root
|
||||||
|
- mode: 644
|
||||||
|
- template: jinja
|
||||||
|
- require:
|
||||||
|
- archive: thunderbird-archive-extract
|
||||||
|
|
||||||
|
thunderbird-icon:
|
||||||
|
file.managed:
|
||||||
|
- name: /usr/share/icons/thunderbird.png
|
||||||
|
- source: /usr/local/apps/thunderbird/chrome/icons/default/default128.png
|
||||||
|
- user: root
|
||||||
|
- group: root
|
||||||
|
- mode: 644
|
||||||
|
|
||||||
|
thunderbird-cleanup:
|
||||||
|
software.cleanup:
|
||||||
|
- name: thunderbird
|
||||||
|
- path: {{ thunderbird.release_dir }}
|
||||||
|
- version: "{{ thunderbird.version }}"
|
5
states/thunderbird/map.jinja
Normal file
5
states/thunderbird/map.jinja
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
{%- import_yaml "thunderbird/defaults.yaml" as default_settings -%}
|
||||||
|
|
||||||
|
{%- set defaults = salt['grains.filter_by'](default_settings, default='thunderbird') -%}
|
||||||
|
|
||||||
|
{%- set thunderbird = salt['pillar.get']('thunderbird', default=defaults, merge=True) -%}
|
13
states/thunderbird/templates/thunderbird.desktop.j2
Normal file
13
states/thunderbird/templates/thunderbird.desktop.j2
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
## Managed by PaulBSD Salt (https://git.paulbsd.com/paulbsd/paulbsd-salt)
|
||||||
|
[Desktop Entry]
|
||||||
|
Encoding=UTF-8
|
||||||
|
Version=1.0
|
||||||
|
Name=Thunderbird
|
||||||
|
Comment=Thunderbird mail client
|
||||||
|
Exec=/usr/local/apps/releases/thunderbird/thunderbird
|
||||||
|
Icon=/usr/local/apps/releases/thunderbird/chrome/icons/default/default128.png
|
||||||
|
Terminal=false
|
||||||
|
StartupWMClass=Thunderbird
|
||||||
|
Type=Application
|
||||||
|
Categories=Network;
|
||||||
|
X-Desktop-File-Install-Version=0.22
|
Loading…
Reference in New Issue
Block a user