diff --git a/copy-xfce-files.fish b/copy-xfce-files.fish index b2fb540..5d9e6b3 100755 --- a/copy-xfce-files.fish +++ b/copy-xfce-files.fish @@ -1,2 +1,2 @@ #!/usr/bin/fish -rsync -a vorlage@testkita-31:/home/vorlage/.config/xfce4/ files/xdg/xfce4/ +rsync -a vorlage@testkita-31:/home/leitung/.config/xfce4/ files/xdg/xfce4/ diff --git a/defaults/main.yml b/defaults/main.yml index ed97d53..2ada8aa 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -1 +1,13 @@ --- +application_starters: + - exo-web-browser + - exo-mail-reader + - exo-file-manager + - libreoffice-writer + - libreoffice-calc + - libreoffice-impress + - fotowall + - org.kde.gwenview + +install_fotowall: true +install_cewe_fotobuch: true diff --git a/files/xdg/xfce4/kiosk/kioskrc b/files/xdg/xfce4/kiosk/kioskrc index db90916..b2bd204 100644 --- a/files/xdg/xfce4/kiosk/kioskrc +++ b/files/xdg/xfce4/kiosk/kioskrc @@ -1,5 +1,2 @@ -[xfce4-panel] -CustomizePanel=NONE - [xfce4-session] SaveSession=NONE diff --git a/files/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-desktop.xml b/files/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-desktop.xml new file mode 100644 index 0000000..e627052 --- /dev/null +++ b/files/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-desktop.xml @@ -0,0 +1,170 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/files/xdg/xfce4/xfconf/xfce-perchannel-xml/xfwm4.xml b/files/xdg/xfce4/xfconf/xfce-perchannel-xml/xfwm4.xml new file mode 100644 index 0000000..9118cc3 --- /dev/null +++ b/files/xdg/xfce4/xfconf/xfce-perchannel-xml/xfwm4.xml @@ -0,0 +1,87 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/files/xdg/xfce4/xfconf/xfce-perchannel-xml/xsettings.xml b/files/xdg/xfce4/xfconf/xfce-perchannel-xml/xsettings.xml new file mode 100644 index 0000000..049d685 --- /dev/null +++ b/files/xdg/xfce4/xfconf/xfce-perchannel-xml/xsettings.xml @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tasks/backgrounds.yaml b/tasks/backgrounds.yaml new file mode 100644 index 0000000..518a427 --- /dev/null +++ b/tasks/backgrounds.yaml @@ -0,0 +1,36 @@ +--- + +- name: background packages + apt: + pkg: "{{ item }}" + with_items: + - mate-backgrounds + - gnome-backgrounds + +- name: directory for backgrounds + file: + path: /opt/backgrounds + state: directory + +- name: copy kita-pro backgrounds + synchronize: + src: background/ + dest: /opt/backgrounds + perms: false + +- name: find all other backgrounds + find: + paths: + - /usr/share/backgrounds/gnome + - /usr/share/backgrounds/mate/nature + - /usr/share/backgrounds/mate/abstract + recurse: yes + excludes: "{{_excluded_backgrounds}}" + register: _find_backgrounds + +- name: link background files + file: + src: "{{item}}" + dest: "/opt/backgrounds/{{item|basename}}" + state: link + with_items: "{{_find_backgrounds|json_query('files[].path')}}" diff --git a/tasks/cewe_fotobuch.yaml b/tasks/cewe_fotobuch.yaml new file mode 100644 index 0000000..ee328df --- /dev/null +++ b/tasks/cewe_fotobuch.yaml @@ -0,0 +1,71 @@ +--- + +- name: cewe fotobuch installation user + user: + name: cewe-fotobuch-setup + system: yes + shell: /usr/bin/fish + home: /opt/cewe-fotobuch + +- name: download cewe fotobuch archive + get_url: + url: https://dls.photoprintit.com/api/getClient/24441-de_DE/hps/om_seo_goo_x_24441_x_24441-UehoUbeYPPMDm/linux + dest: /opt/cewe-fotobuch/setup_Mein_CEWE_FOTOBUCH.tgz + checksum: sha256:c556db58f409c7d3d615d95295edac0263d1490bffd0da2a06e5ddb2517b7ec5 + owner: cewe-fotobuch-setup + group: cewe-fotobuch-setup + +- name: extract cewe fotobuch archive + unarchive: + src: /opt/cewe-fotobuch/setup_Mein_CEWE_FOTOBUCH.tgz + remote_src: yes + dest: /opt/cewe-fotobuch + owner: cewe-fotobuch-setup + group: cewe-fotobuch-setup + +- name: cewe fotobuch temp dir + file: + path: /opt/cewe-fotobuch/tmp + state: directory + owner: cewe-fotobuch-setup + group: cewe-fotobuch-setup + +- name: install cewe fotobuch + shell: yes ja | ./install.pl -i /opt/cewe-fotobuch -w /opt/cewe-fotobuch/tmp/ -k -v + args: + chdir: /opt/cewe-fotobuch + creates: /opt/cewe-fotobuch/hps-16523-6.3.4.desktop + become: true + become_user: cewe-fotobuch-setup + become_method: su + +- name: find desktop file + find: + paths: /opt/cewe-fotobuch/.local/share/applications/ + excludes: + - defaults.list + recurse: yes + file_type: file + register: _find_cewe_fotobuch_shares + +- name: copy desktop file + copy: + src: "{{_find_cewe_fotobuch_shares|json_query('files[].path')|first}}" + remote_src: yes + dest: "/usr/share/applications/cewe-fotobuch.desktop" + mode: 0644 + +- name: find all icon files + find: + paths: /opt/cewe-fotobuch/.local/share/icons/ + recurse: yes + file_type: file + register: _find_cewe_fotobuch_shares + +- name: copy icon files + copy: + src: "/opt/cewe-fotobuch/.local/share/{{item}}" + remote_src: yes + dest: "/usr/share/{{item}}" + mode: 0644 + with_items: "{{_find_cewe_fotobuch_shares|json_query('files[].path')|map('relpath','/opt/cewe-fotobuch/.local/share/')|list}}" diff --git a/tasks/desktop_apps.yaml b/tasks/desktop_apps.yaml new file mode 100644 index 0000000..3cab9ea --- /dev/null +++ b/tasks/desktop_apps.yaml @@ -0,0 +1,18 @@ +--- + +- import_role: + name: desktop_apps + +- import_tasks: fotowall.yaml + when: install_fotowall + +- import_tasks: cewe_fotobuch.yaml + when: install_cewe_fotobuch + +- name: additional desktop apps + apt: + pkg: "{{ item }}" + with_items: + - simple-scan + - gwenview + - kipi-plugins diff --git a/tasks/fotowall.yaml b/tasks/fotowall.yaml new file mode 100644 index 0000000..e8532ff --- /dev/null +++ b/tasks/fotowall.yaml @@ -0,0 +1,37 @@ +--- + +- name: download fotowall binary + get_url: + url: https://github.com/enricoros/fotowall/releases/download/v1.0/Fotowall-1.0-RETRO-Linux_static-x86_64.x86_64 + checksum: sha256:17d43106a3487dbd3853fff3421145b11bad86360fc96757f76cc8904bb0ed03 + dest: /usr/local/bin/fotowall + mode: 0755 + +- name: download fotowall archive + get_url: + url: https://github.com/enricoros/fotowall/releases/download/v1.0/Fotowall-1.0-RETRO.tar.bz2 + checksum: sha256:bbd8c6108ecbac1943122a8398475381865d9833a8bba8c10f0d3262a578fb9f + dest: /opt/fotowall.tar.bz2 + +- name: fotowall directory + file: + path: /opt/fotowall + state: directory + +- name: unpack fotowall archive + unarchive: + src: /opt/fotowall.tar.bz2 + remote_src: yes + dest: /opt/fotowall + +- name: fotowall desktop file + file: + src: /opt/fotowall/fotowall.desktop + dest: /usr/share/applications/fotowall.desktop + state: link + +- name: fotowall icon + file: + src: /opt/fotowall/fotowall.png + dest: /usr/share/icons/fotowall.png + state: link diff --git a/tasks/main.yaml b/tasks/main.yaml index 3b4fa6f..3d3ade3 100644 --- a/tasks/main.yaml +++ b/tasks/main.yaml @@ -1,18 +1,17 @@ --- - import_tasks: xfce.yaml -# - import_tasks: wallpapers.yaml -# -# - import_role: -# name: desktop_apps -# -# - import_role: -# name: libreoffice -# -# - import_role: -# name: firefox -# -# - import_role: -# name: display_manager -# vars: -# display_manager_background_image: "background/{{ kitapro_background_image }}" +- import_tasks: backgrounds.yaml + +- import_tasks: desktop_apps.yaml + +- import_role: + name: libreoffice + +- import_role: + name: firefox + +- import_role: + name: display_manager + vars: + display_manager_background_image: "background/{{ kitapro_background_image }}" diff --git a/tasks/wallpapers.yaml b/tasks/wallpapers.yaml deleted file mode 100644 index 26fd336..0000000 --- a/tasks/wallpapers.yaml +++ /dev/null @@ -1,21 +0,0 @@ ---- - -- name: xfce packages - apt: - pkg: "{{ item }}" - with_items: - - xfce4 - -- name: wallpaper packages - apt: - pkg: "{{ item }}" - with_items: - - kde-wallpapers - - mate-backgrounds - - gnome-backgrounds - - propaganda-debian - -- name: copy xfce configuration - copy: - src: xfce4/ - dest: /etc/xdg/xfce4/ diff --git a/tasks/xfce.yaml b/tasks/xfce.yaml index 0709562..d0e4639 100644 --- a/tasks/xfce.yaml +++ b/tasks/xfce.yaml @@ -1,12 +1,23 @@ --- -- name: xfce packages +- name: desktop packages apt: pkg: "{{ item }}" with_items: - xfce4 + - task-desktop + - task-xfce-desktop + - task-german + - task-german-desktop + - eog + - dmz-cursor-theme -- name: copy xdg configuration - synchronize: +- name: xdg config + copy: src: xdg/ dest: /etc/xdg/ + +- name: xfce panel config + template: + src: xfce4-panel.xml.j2 + dest: /etc/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-panel.xml diff --git a/files/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-panel.xml b/templates/xfce4-panel.xml.j2 similarity index 54% rename from files/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-panel.xml rename to templates/xfce4-panel.xml.j2 index 276f2a6..6dd9e71 100644 --- a/files/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-panel.xml +++ b/templates/xfce4-panel.xml.j2 @@ -1,6 +1,8 @@ - +{% set i = 10 %} + + @@ -11,20 +13,17 @@ +{% for app in application_starters %} + +{% endfor %} - - - - - - @@ -36,71 +35,42 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +{% for app in application_starters %} + - + +{% endfor %} - + - + - + - + - + - + - + - + diff --git a/vars/main.yml b/vars/main.yml index 8704ccc..7a7ed1c 100644 --- a/vars/main.yml +++ b/vars/main.yml @@ -13,3 +13,6 @@ _kitapro_background_image: 10: River_through_an_Autumn_Forest-William_Mason_Brown.jpg 11: Theodor_Philipsen_-_A_Late_Autumn_Day_in_Dyrehaven,_Sunshine.JPG 12: Albert_Bredow_-_Romantic_Winter_Landscape_with_Ice_Skaters_by_a_Castle.jpg + +_excluded_backgrounds: + - adwaita-timed.xml