diff --git a/README.md b/README.md index 75a30bd63..aa96ee0a6 100644 --- a/README.md +++ b/README.md @@ -28,7 +28,6 @@ Fast, automated, modular installation/configuration/maintenance tool for persona * [Samba](https://www.samba.org/) file sharing server (public and private file shares) * [Apache](https://httpd.apache.org/) [web server](https://en.wikipedia.org/wiki/HTTP_Server) and Web applications: - [Nextcloud](https://nextcloud.com/): file/calendar/address book storage, synchronization and sharing, and more. - - [MinigalNano](https://github.com/sebsauvage/MinigalNano): simple image gallery. - [Shaarli](https://github.com/shaarli/Shaarli): save and share links, bookmarks, notes, and more. - [Tiny Tiny RSS](https://tt-rss.org/gitlab/fox/tt-rss/wikis/home): [News feed reader](https://en.wikipedia.org/wiki/News_aggregator) and aggregator (RSS/Atom) + plugins. - [Converse.js](https://conversejs.org/): Web chat client (XMPP). @@ -155,7 +154,6 @@ update-firewall: update firewall rules according to configuration update-services: update services status according to configuration upgrade: upgrade all software to latest versions webapp-conversejs-install: Install converse.js web chat client -webapp-minigalnano-install: Install MinigalNano image gallery webapp-nextcloud-install: Install nextcloud file sharing and collaboration platform webapp-shaarli-install: Install Shaarli link sharing service webapp-tt-rss-install: Install TT-RSS feed reader diff --git a/TODO.md b/TODO.md index 0ac7d4ac0..581934b33 100644 --- a/TODO.md +++ b/TODO.md @@ -3,11 +3,11 @@ _Note: more todo-list items can be found with `git grep -r TODO`_ * [bug] converse.js does not work on fresh install (error: require is not defined) + * [enh] replace conversejs with modern chat platform (riot/mattrermost/rocket.chat/jsxc/...) + * [doc] document installed owncloud apps #### Security -* [easy] [security] remove minigalnano (unmaintained, security issues: https://github.com/sebsauvage/MinigalNano/issues/123 - * [firewall] test that new fail2ban configuration w/ firehol is effective * [enh] [security] [firewall] add a mode to restrict services access to VPN only * [enh] [security] [firewall] restrictive OUTPUT policy (see firehol.conf) @@ -158,8 +158,6 @@ _Note: more todo-list items can be found with `git grep -r TODO`_ * [enh] store installed version number in status file * [enh] upgrades: only upgrade when the versions.yml version is > installed version number * [enh] report: check backups integrity (https://github.com/bit-team/backintime/wiki/FAQ#id24) -* [enh] minigalnano: customize titles/author -* [enh] minigalnano: populate photos directory with one dfeaault picture to prevent "new installation" message from showing * [enh] [cli] rename tasks as per TODOs in Makefile * [enh] backups: after backup: if configured backup drive is plugged in, display debug message, mount it and sync contents of the backup directory to it add doc on preparing the usb drive diff --git a/roles/webapp-minigalnano/files/etc_apache2_conf-available_minigalnano-password.conf b/roles/webapp-minigalnano/files/etc_apache2_conf-available_minigalnano-password.conf deleted file mode 100644 index 7f71f60cb..000000000 --- a/roles/webapp-minigalnano/files/etc_apache2_conf-available_minigalnano-password.conf +++ /dev/null @@ -1,6 +0,0 @@ - - AuthUserFile /etc/apache2/passwd - AuthName "Images" - AuthType Basic - require valid-user - \ No newline at end of file diff --git a/roles/webapp-minigalnano/files/var_www_images_config.php b/roles/webapp-minigalnano/files/var_www_images_config.php deleted file mode 100755 index 7f521af88..000000000 --- a/roles/webapp-minigalnano/files/var_www_images_config.php +++ /dev/null @@ -1,46 +0,0 @@ -"; // Breadcrumb parts separator - -//RSS SETTINGS -$description = "MiniGal Nano"; -$nb_items_rss = 100; // Number of elements to display in the feed. If you add a lot of pictures at the time, consider increasing this number -$rss_refresh_interval = 60;// Time, in seconds, between two RSS refresh. for example, 3600 = 1update max per hour, 86400 = 1/day. -$keep_extensions = array('jpg', 'jpeg', 'png', 'gif', 'webm', 'mp4', 'ogv'); // Only files with these extensions will be displayed on the RSS feed - -//ADVANCED SETTINGS -$thumb_size = 320; //Thumbnail height/width (square thumbs). Changing this will most likely require manual altering of the template file to make it look properly! -$label_max_length = 40; //Maximum chars of a folder name that will be displayed on the folder thumbnail -$display_exif = 0; //Take care, even if not diplayed EXIF are still readable for visitors. May be a good idea to erase EXIF data... -$display_filename = 0; //Show file names below the pictures -?> diff --git a/roles/webapp-minigalnano/handlers/main.yml b/roles/webapp-minigalnano/handlers/main.yml deleted file mode 100644 index 840ca74a3..000000000 --- a/roles/webapp-minigalnano/handlers/main.yml +++ /dev/null @@ -1,4 +0,0 @@ -##### MESSAGES - -- name: display minigalnano installation completion message - debug: msg="MinigalNano successfully installed, available at https://{{ srv01_fqdn }}/images/. Upload your pictures to sftp://{{ srv01_fqdn }}/PUB_IMAGES/" diff --git a/roles/webapp-minigalnano/tasks/cleanup.yml b/roles/webapp-minigalnano/tasks/cleanup.yml deleted file mode 100644 index f320b2ae8..000000000 --- a/roles/webapp-minigalnano/tasks/cleanup.yml +++ /dev/null @@ -1,9 +0,0 @@ -- name: optimize images - shell: find /var/www/images/photos/ -iname "*.{{ item.ext }}" -exec {{ item.tool }} '{}' \; - with_items: - - { ext: 'png', tool: 'optipng'} - - { ext: 'jpe?g', tool: 'jpegoptim'} - ignore_errors: True - -- name: clear minigalnano thumbnails cache - command: find /var/www/images/thumbs -type f -exec srm -llzv '{}' \; \ No newline at end of file diff --git a/roles/webapp-minigalnano/tasks/main.yml b/roles/webapp-minigalnano/tasks/main.yml deleted file mode 100644 index deca22e1d..000000000 --- a/roles/webapp-minigalnano/tasks/main.yml +++ /dev/null @@ -1,26 +0,0 @@ -# webapp-minigalnano role -- name: check minigalnano role installation status - stat: path=/var/lib/srv01/minigalnano-installed - register: minigalnano_installed - tags: - - webapp-minigalnano-install - - upgrade - - cleanup - -# srv01 - webapp-minigalnano-install: Install MinigalNano image gallery -- name: abort installation when minigalnano is already installed - fail: msg="ERROR minigalnano role has already been configured." - when: minigalnano_installed.stat.exists == True - tags: webapp-minigalnano-install - -- include: minigalnano.yml - tags: webapp-minigalnano-install - -# upgrade only when minigalnano is aleady installed -- include: minigalnano.yml - tags: upgrade - when: minigalnano_installed.stat.exists == True - -- include: cleanup.yml - tags: cleanup - when: minigalnano_installed.stat.exists == True \ No newline at end of file diff --git a/roles/webapp-minigalnano/tasks/minigalnano.yml b/roles/webapp-minigalnano/tasks/minigalnano.yml deleted file mode 100644 index 535fbf82c..000000000 --- a/roles/webapp-minigalnano/tasks/minigalnano.yml +++ /dev/null @@ -1,80 +0,0 @@ -##### PACKAGES ##### NONE - - -##### CHECK REQUIREMENTS ##### - -- name: check apache role installation status - stat: path=/var/lib/srv01/apache-installed - register: apache_installed - -- name: exit - apache is not installed - fail: msg="Aborting installation - apache role is not installed. Please run 'srv01 apache-install' to install it." - when: apache_installed.stat.exists != True - -##### DOWNLOADS ##### - -- name: clone minigalnano - git: repo=https://github.com/sebsauvage/MinigalNano - dest=/var/www/images - version='{{ minigalnano_version }}' - accept_hostkey=yes - force=yes - -##### APACHE CONFIG ##### NONE - -##### MYSQL ##### NONE - -##### FAIL2BAN ##### NONE - -# minigalnano has no password protection mechanism -# use apache2 password protection to restrict access -# apache2 auth module has its own fail2ban jail/filter - -##### BACKUPS ##### - -- name: copy minigalnano backup config - template: src=etc_rsnapshot.d_minigalnano.conf.j2 dest=/etc/rsnapshot.d/minigalnano.conf mode=0600 - notify: update backup configuration - -##### FILES IN WEBROOT ##### - -- name: copy minigalnano config - copy: src=var_www_images_config.php dest=/var/www/images/config.php - -- name: remove system_check.php (php version disclosure) - file: path=/var/www/images/system_check.php state=absent - -##### FILE PERMISSIONS ##### - -- name: set minigalnano files ownership to root:www-data - file: path=/var/www/images state=directory owner=root group=www-data recurse=yes - -- name: ensure files are mode 0640 and directories mode 0750 - shell: find /var/www/images -type {{ item.type }} -print0 | xargs -0 chmod -c {{ item.mode }} - register: chmod_result - changed_when: "chmod_result.stdout != \"\"" - with_items: - - { type: 'f', mode: '0640' } - - { type: 'd', mode: '0750' } - -- name: create thumbs directory with webserver write permissions - file: path=/var/www/images/thumbs state=directory owner=www-data group=www-data recurse=yes - -# sgid directory: all files created in the photos directory will inherit its group id (www-data) -- name: set minigalnano photos dir to sgid + owner rw + group r - file: path=/var/www/images/photos state=directory owner=root group=www-data mode=2770 - -- name: set/fix minigalnano image files permissions to owner rw + group r - shell: find /var/www/images/photos/ -type f -exec chmod 0640 "{}" \; - -##### COMMAND-LINE/MISC INSTALLATION STEPS ##### - -- name: create symlink to images directory in main users home - file: state=link dest="/home/{{ admin_username }}/PUB_IMAGES" src=/var/www/images/photos/ - -- name: create minigalnano-installed status file - template: src=var_lib_srv01_minigalnano-installed.j2 dest=/var/lib/srv01/minigalnano-installed owner=root group=root mode=0600 - notify: display minigalnano installation completion message - -#TODO: create a symlink ~/public_images/ -> /var/www/images/photos -#TODO: cleanup: clear minigalnano cache diff --git a/roles/webapp-minigalnano/templates/etc_rsnapshot.d_minigalnano.conf.j2 b/roles/webapp-minigalnano/templates/etc_rsnapshot.d_minigalnano.conf.j2 deleted file mode 100644 index 50bc3c021..000000000 --- a/roles/webapp-minigalnano/templates/etc_rsnapshot.d_minigalnano.conf.j2 +++ /dev/null @@ -1 +0,0 @@ -backup /var/www/images/ localhost/ diff --git a/roles/webapp-minigalnano/templates/var_lib_srv01_minigalnano-installed.j2 b/roles/webapp-minigalnano/templates/var_lib_srv01_minigalnano-installed.j2 deleted file mode 100644 index b5ad28268..000000000 --- a/roles/webapp-minigalnano/templates/var_lib_srv01_minigalnano-installed.j2 +++ /dev/null @@ -1 +0,0 @@ -{{ minigalnano_version }} \ No newline at end of file diff --git a/site.yml b/site.yml index a10cad3ab..ff39c683b 100644 --- a/site.yml +++ b/site.yml @@ -14,7 +14,6 @@ - samba - transmission - mumble - - webapp-minigalnano - webapp-conversejs - webapp-nextcloud - webapp-tt-rss diff --git a/versions.yml b/versions.yml index af342b7fe..495c6b773 100644 --- a/versions.yml +++ b/versions.yml @@ -12,6 +12,5 @@ nextcloud_contacts_version: 'v1.5.3' nextcloud_tasks_version: 'v0.9.5' # https://github.com/kucrut/ttrss-reader/tags.atom ttrss_reader_version: '1.3.0' -minigalnano_version: 'master' tt_rss_version: 'master' apaxy_version: 'master'