aboutsummaryrefslogtreecommitdiff
path: root/flakes/mypackages/pkgs/webapps
diff options
context:
space:
mode:
Diffstat (limited to 'flakes/mypackages/pkgs/webapps')
-rw-r--r--flakes/mypackages/pkgs/webapps/adminer/default.nix14
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/default.nix88
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/.htaccess9
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/footer.html31
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/header.html3
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/archive.pngbin0 -> 551 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/audio.pngbin0 -> 554 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/authors.pngbin0 -> 492 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/bin.pngbin0 -> 551 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/blank.pngbin0 -> 227 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/bmp.pngbin0 -> 663 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/c.pngbin0 -> 554 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/calc.pngbin0 -> 506 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/cd.pngbin0 -> 757 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/copying.pngbin0 -> 699 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/cpp.pngbin0 -> 599 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/css.pngbin0 -> 592 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/deb.pngbin0 -> 671 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/default.pngbin0 -> 311 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/diff.pngbin0 -> 586 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/doc.pngbin0 -> 535 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/draw.pngbin0 -> 679 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/eps.pngbin0 -> 619 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/exe.pngbin0 -> 846 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-home.pngbin0 -> 618 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-open.pngbin0 -> 431 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-page.pngbin0 -> 591 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-parent-old.pngbin0 -> 494 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-parent.pngbin0 -> 621 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder.pngbin0 -> 395 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/gif.pngbin0 -> 655 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/gzip.pngbin0 -> 551 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/h.pngbin0 -> 504 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/hpp.pngbin0 -> 530 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/html.pngbin0 -> 770 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/ico.pngbin0 -> 792 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/image.pngbin0 -> 671 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/install.pngbin0 -> 788 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/java.pngbin0 -> 658 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/jpg.pngbin0 -> 675 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/js.pngbin0 -> 540 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/json.pngbin0 -> 540 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/log.pngbin0 -> 423 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/makefile.pngbin0 -> 614 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/markdown.pngbin0 -> 627 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/package.pngbin0 -> 614 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/pdf.pngbin0 -> 799 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/php.pngbin0 -> 757 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/playlist.pngbin0 -> 610 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/png.pngbin0 -> 679 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/pres.pngbin0 -> 629 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/ps.pngbin0 -> 817 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/psd.pngbin0 -> 622 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/py.pngbin0 -> 743 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rar.pngbin0 -> 621 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rb.pngbin0 -> 781 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/readme.pngbin0 -> 384 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rpm.pngbin0 -> 660 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rss.pngbin0 -> 660 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rtf.pngbin0 -> 627 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/script.pngbin0 -> 613 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/source.pngbin0 -> 586 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/sql.pngbin0 -> 510 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/tar.pngbin0 -> 406 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/tex.pngbin0 -> 677 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/text.pngbin0 -> 463 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/tiff.pngbin0 -> 654 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/unknown.pngbin0 -> 556 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/vcal.pngbin0 -> 556 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/video.pngbin0 -> 739 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/xml.pngbin0 -> 585 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/zip.pngbin0 -> 617 bytes
-rw-r--r--flakes/mypackages/pkgs/webapps/apache-theme/theme/style.css160
-rw-r--r--flakes/mypackages/pkgs/webapps/awl/default.nix16
-rw-r--r--flakes/mypackages/pkgs/webapps/davical/default.nix23
-rw-r--r--flakes/mypackages/pkgs/webapps/default.nix24
-rw-r--r--flakes/mypackages/pkgs/webapps/dokuwiki/default.nix54
-rw-r--r--flakes/mypackages/pkgs/webapps/dokuwiki/plugins/farmer.nix25
-rw-r--r--flakes/mypackages/pkgs/webapps/dokuwiki/plugins/todo.nix18
-rw-r--r--flakes/mypackages/pkgs/webapps/infcloud/default.nix19
-rw-r--r--flakes/mypackages/pkgs/webapps/infcloud/infcloud_config.js1446
-rw-r--r--flakes/mypackages/pkgs/webapps/mantisbt_2/bug_report.php.diff20
-rw-r--r--flakes/mypackages/pkgs/webapps/mantisbt_2/bug_report_page.php.diff53
-rw-r--r--flakes/mypackages/pkgs/webapps/mantisbt_2/bugnote_add.php.diff20
-rw-r--r--flakes/mypackages/pkgs/webapps/mantisbt_2/bugnote_add_inc.php.diff52
-rw-r--r--flakes/mypackages/pkgs/webapps/mantisbt_2/default.nix44
-rw-r--r--flakes/mypackages/pkgs/webapps/mantisbt_2/plugins/slack/default.nix18
-rw-r--r--flakes/mypackages/pkgs/webapps/mantisbt_2/plugins/source-integration/Source.API.php.diff12
-rw-r--r--flakes/mypackages/pkgs/webapps/mantisbt_2/plugins/source-integration/default.nix22
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/audioplayer.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/bookmarks.nix21
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/calendar.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/carnet.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/contacts.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/cookbook.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/deck.nix27
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/drawio.nix24
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/external.nix27
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/extract.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/files_markdown.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/files_mindmap.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/files_readmemd.nix14
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/flowupload.nix14
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/gpxedit.nix22
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/gpxpod.nix31
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/groupfolders.nix27
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/impersonate.nix27
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/integration_dropbox.nix13
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/keeweb.nix24
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/maps.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/metadata.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/music.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/notes.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/ocsms.nix21
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/onlyoffice.nix21
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/passman.nix21
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/polls.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/side_menu.nix16
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/social.nix14
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/spreed.nix27
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/talk_matterbridge.nix14
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/apps/tasks.nix15
-rw-r--r--flakes/mypackages/pkgs/webapps/nextcloud/default.nix84
-rw-r--r--flakes/mypackages/pkgs/webapps/phpbb/default.nix61
-rw-r--r--flakes/mypackages/pkgs/webapps/phpbb/extensions/adduser.nix22
-rw-r--r--flakes/mypackages/pkgs/webapps/phpbb/extensions/autosubscribe.nix19
-rw-r--r--flakes/mypackages/pkgs/webapps/phpbb/extensions/mailinglist.nix18
-rw-r--r--flakes/mypackages/pkgs/webapps/phpbb/extensions/markdown.nix20
-rw-r--r--flakes/mypackages/pkgs/webapps/phpbb/extensions/mchat.nix21
-rw-r--r--flakes/mypackages/pkgs/webapps/phpbb/extensions/monitoranswers.nix19
-rw-r--r--flakes/mypackages/pkgs/webapps/phpbb/langs/fr.nix12
-rw-r--r--flakes/mypackages/pkgs/webapps/phpldapadmin/default.nix27
-rw-r--r--flakes/mypackages/pkgs/webapps/phpldapadmin/ldap-align-button.patch11
-rw-r--r--flakes/mypackages/pkgs/webapps/phpldapadmin/ldap-fix-password.patch13
-rw-r--r--flakes/mypackages/pkgs/webapps/phpldapadmin/ldap-sort-in-templates.patch12
-rw-r--r--flakes/mypackages/pkgs/webapps/rompr/default.nix17
-rw-r--r--flakes/mypackages/pkgs/webapps/roundcubemail/add_all.patch209
-rw-r--r--flakes/mypackages/pkgs/webapps/roundcubemail/default.nix85
-rw-r--r--flakes/mypackages/pkgs/webapps/roundcubemail/plugins/automatic_addressbook/default.nix7
-rw-r--r--flakes/mypackages/pkgs/webapps/roundcubemail/plugins/carddav/default.nix7
-rw-r--r--flakes/mypackages/pkgs/webapps/roundcubemail/plugins/contextmenu/default.nix7
-rw-r--r--flakes/mypackages/pkgs/webapps/roundcubemail/plugins/contextmenu_folder/default.nix7
-rw-r--r--flakes/mypackages/pkgs/webapps/roundcubemail/plugins/html5_notifier/default.nix7
-rw-r--r--flakes/mypackages/pkgs/webapps/roundcubemail/plugins/ident_switch/default.nix7
-rw-r--r--flakes/mypackages/pkgs/webapps/roundcubemail/plugins/message_highlight/default.nix7
-rw-r--r--flakes/mypackages/pkgs/webapps/roundcubemail/plugins/thunderbird_labels/default.nix7
-rw-r--r--flakes/mypackages/pkgs/webapps/spip/default.nix32
-rw-r--r--flakes/mypackages/pkgs/webapps/spip/spip_ldap_patch.patch60
-rw-r--r--flakes/mypackages/pkgs/webapps/spip/spip_mes_options.php18
-rw-r--r--flakes/mypackages/pkgs/webapps/ttrss/default.nix37
-rw-r--r--flakes/mypackages/pkgs/webapps/ttrss/plugins/af_feedmod/default.nix18
-rw-r--r--flakes/mypackages/pkgs/webapps/ttrss/plugins/af_feedmod/type_replace.patch12
-rw-r--r--flakes/mypackages/pkgs/webapps/ttrss/plugins/auth_ldap/default.nix17
-rw-r--r--flakes/mypackages/pkgs/webapps/ttrss/plugins/feediron/default.nix18
-rw-r--r--flakes/mypackages/pkgs/webapps/ttrss/plugins/feediron/json_reformat.patch18
-rw-r--r--flakes/mypackages/pkgs/webapps/ttrss/plugins/ff_instagram/default.nix17
-rw-r--r--flakes/mypackages/pkgs/webapps/ttrss/plugins/tumblr_gdpr_ua/default.nix17
-rw-r--r--flakes/mypackages/pkgs/webapps/wallabag/default.nix54
-rw-r--r--flakes/mypackages/pkgs/webapps/wallabag/ldap.patch664
-rw-r--r--flakes/mypackages/pkgs/webapps/yourls/default.nix37
-rw-r--r--flakes/mypackages/pkgs/webapps/yourls/plugins/ldap/default.nix17
161 files changed, 4528 insertions, 0 deletions
diff --git a/flakes/mypackages/pkgs/webapps/adminer/default.nix b/flakes/mypackages/pkgs/webapps/adminer/default.nix
new file mode 100644
index 0000000..cd01080
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/adminer/default.nix
@@ -0,0 +1,14 @@
1{ stdenv, fetchurl }:
2stdenv.mkDerivation rec {
3 version = "4.8.2";
4 pname = "adminer";
5 src = fetchurl {
6 url = "https://github.com/adminerevo/adminerevo/releases/download/v${version}/${pname}-${version}.php";
7 sha256 = "sha256-jXcnGLyNQZqJKS0Rs+UY1SxzknBEZwBhcbD0BmJVFKs=";
8 };
9 phases = "installPhase";
10 installPhase = ''
11 mkdir -p $out
12 cp $src $out/index.php
13 '';
14}
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/default.nix b/flakes/mypackages/pkgs/webapps/apache-theme/default.nix
new file mode 100644
index 0000000..4b5755a
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/default.nix
@@ -0,0 +1,88 @@
1{ theme_root ? null }:
2rec {
3 theme = ./theme;
4 apacheConfig = let
5 theme_root' = if isNull theme_root then theme else theme_root;
6 in ''
7 <Macro Apaxy %{folder} %{ignored}>
8 Alias /theme ${theme_root'}
9 <Directory ${theme_root'}>
10 Options -Indexes
11 AllowOverride None
12 Require all granted
13 </Directory>
14
15 # mod_autoindex
16 <Directory %{folder}>
17 Options Indexes
18 AllowOverride None
19 Require all granted
20
21 # Inspired from Apaxy by @adamwhitcroft
22
23 IndexOptions +Charset=UTF-8 +FancyIndexing +IgnoreCase +FoldersFirst +XHTML +HTMLTable +SuppressRules +SuppressDescription +NameWidth=* +IconsAreLinks +ShowForbidden
24
25 IndexHeadInsert "<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\" />"
26
27 IndexIgnoreReset ON
28 IndexIgnore /theme .htaccess %{ignored}
29
30 AddIcon /theme/icons/blank.png ^^BLANKICON^^
31 AddIcon /theme/icons/folder.png ^^DIRECTORY^^
32 AddIcon /theme/icons/folder-home.png ..
33
34 AddIconByType (TXT,/theme/icons/text.png) text/*
35 AddIconByType (IMG,/theme/icons/image.png) image/*
36 AddIconByType (SND,/theme/icons/audio.png) audio/*
37 AddIconByType (VID,/theme/icons/video.png) video/*
38
39 AddIcon /theme/icons/archive.png .7z .bz2 .cab .gz .tar
40 AddIcon /theme/icons/audio.png .aac .aif .aifc .aiff .ape .au .flac .iff .m4a .mid .mp3 .mpa .ra .wav .wma .f4a .f4b .oga .ogg .xm .it .s3m .mod
41 AddIcon /theme/icons/bin.png .bin .hex
42 AddIcon /theme/icons/bmp.png .bmp
43 AddIcon /theme/icons/c.png .c
44 AddIcon /theme/icons/calc.png .xlsx .xlsm .xltx .xltm .xlam .xlr .xls .csv
45 AddIcon /theme/icons/cd.png .iso
46 AddIcon /theme/icons/cpp.png .cpp
47 AddIcon /theme/icons/css.png .css .sass .scss
48 AddIcon /theme/icons/deb.png .deb
49 AddIcon /theme/icons/doc.png .doc .docx .docm .dot .dotx .dotm .log .msg .odt .pages .rtf .tex .wpd .wps
50 AddIcon /theme/icons/draw.png .svg .svgz
51 AddIcon /theme/icons/eps.png .ai .eps
52 AddIcon /theme/icons/exe.png .exe
53 AddIcon /theme/icons/gif.png .gif
54 AddIcon /theme/icons/h.png .h
55 AddIcon /theme/icons/html.png .html .xhtml .shtml .htm .URL .url
56 AddIcon /theme/icons/ico.png .ico
57 AddIcon /theme/icons/java.png .jar
58 AddIcon /theme/icons/jpg.png .jpg .jpeg .jpe
59 AddIcon /theme/icons/js.png .js .json
60 AddIcon /theme/icons/markdown.png .md
61 AddIcon /theme/icons/package.png .pkg .dmg
62 AddIcon /theme/icons/pdf.png .pdf
63 AddIcon /theme/icons/php.png .php .phtml
64 AddIcon /theme/icons/playlist.png .m3u .m3u8 .pls .pls8
65 AddIcon /theme/icons/png.png .png
66 AddIcon /theme/icons/ps.png .ps
67 AddIcon /theme/icons/psd.png .psd
68 AddIcon /theme/icons/py.png .py
69 AddIcon /theme/icons/rar.png .rar
70 AddIcon /theme/icons/rb.png .rb
71 AddIcon /theme/icons/rpm.png .rpm
72 AddIcon /theme/icons/rss.png .rss
73 AddIcon /theme/icons/script.png .bat .cmd .sh
74 AddIcon /theme/icons/sql.png .sql
75 AddIcon /theme/icons/tiff.png .tiff .tif
76 AddIcon /theme/icons/text.png .txt .nfo
77 AddIcon /theme/icons/video.png .asf .asx .avi .flv .mkv .mov .mp4 .mpg .rm .srt .swf .vob .wmv .m4v .f4v .f4p .ogv
78 AddIcon /theme/icons/xml.png .xml
79 AddIcon /theme/icons/zip.png .zip
80 DefaultIcon /theme/icons/default.png
81
82 HeaderName /theme/header.html
83 ReadmeName /theme/footer.html
84 IndexStyleSheet /theme/style.css
85 </Directory>
86 </Macro>
87 '';
88}
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/.htaccess b/flakes/mypackages/pkgs/webapps/apache-theme/theme/.htaccess
new file mode 100644
index 0000000..f9e5472
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/.htaccess
@@ -0,0 +1,9 @@
1#
2# Apaxy by @adamwhitcroft
3#
4# For a full breakdown of the mod_autoindex module
5# http://apache.org/docs/2.2/mod/mod_autoindex.html
6#
7
8# Don't index this folder
9Options -Indexes
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/footer.html b/flakes/mypackages/pkgs/webapps/apache-theme/theme/footer.html
new file mode 100644
index 0000000..57a2012
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/footer.html
@@ -0,0 +1,31 @@
1</div><!--/.wrapper-->
2
3<script type="text/javascript">
4// grab the 2nd child and add the parent class. tr:nth-child(2)
5document.getElementsByTagName('tr')[1].className = 'parent';
6// fix links when not adding a / at the end of the URI
7var uri = window.location.pathname.substr(1);
8if (uri.length > 0 && uri.substring(uri.length-1) != '/'){
9 var indexes = document.getElementsByClassName('indexcolname'),
10 i = indexes.length;
11 while (i--){
12 var a = indexes[i].getElementsByTagName('a')[0];
13 a.href = '/' + uri + '/' + a.getAttribute('href',2);
14 }
15}
16
17function getAjax(url, success) {
18 var xhr = window.XMLHttpRequest ? new XMLHttpRequest() : new ActiveXObject('Microsoft.XMLHTTP');
19 xhr.open('GET', url);
20 xhr.onreadystatechange = function() {
21 if (xhr.readyState>3 && xhr.status==200)
22 success(xhr.responseText);
23 };
24 xhr.setRequestHeader('X-Requested-With', 'XMLHttpRequest');
25 xhr.send();
26 return xhr;
27}
28getAjax("title", function(data) {
29 document.getElementById('pagetitle').innerHTML = data;
30});
31</script>
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/header.html b/flakes/mypackages/pkgs/webapps/apache-theme/theme/header.html
new file mode 100644
index 0000000..cbded6a
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/header.html
@@ -0,0 +1,3 @@
1<div class="wrapper">
2 <h1 id="pagetitle"></h1>
3<!-- we open the `wrapper` element here, but close it in the `footer.html` file -->
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/archive.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/archive.png
new file mode 100644
index 0000000..99ae6fc
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/archive.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/audio.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/audio.png
new file mode 100644
index 0000000..a67618d
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/audio.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/authors.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/authors.png
new file mode 100644
index 0000000..78bf784
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/authors.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/bin.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/bin.png
new file mode 100644
index 0000000..ec2220b
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/bin.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/blank.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/blank.png
new file mode 100644
index 0000000..bef1f60
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/blank.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/bmp.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/bmp.png
new file mode 100644
index 0000000..c6f3044
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/bmp.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/c.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/c.png
new file mode 100644
index 0000000..12adaa3
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/c.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/calc.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/calc.png
new file mode 100644
index 0000000..a034367
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/calc.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/cd.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/cd.png
new file mode 100644
index 0000000..3a3ffbb
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/cd.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/copying.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/copying.png
new file mode 100644
index 0000000..83fa06e
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/copying.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/cpp.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/cpp.png
new file mode 100644
index 0000000..47e8b1e
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/cpp.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/css.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/css.png
new file mode 100644
index 0000000..15f7695
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/css.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/deb.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/deb.png
new file mode 100644
index 0000000..1b12d29
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/deb.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/default.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/default.png
new file mode 100644
index 0000000..6997229
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/default.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/diff.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/diff.png
new file mode 100644
index 0000000..5bef920
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/diff.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/doc.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/doc.png
new file mode 100644
index 0000000..5732f9b
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/doc.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/draw.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/draw.png
new file mode 100644
index 0000000..8f1da5c
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/draw.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/eps.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/eps.png
new file mode 100644
index 0000000..93736bb
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/eps.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/exe.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/exe.png
new file mode 100644
index 0000000..31299b7
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/exe.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-home.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-home.png
new file mode 100644
index 0000000..14fe20a
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-home.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-open.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-open.png
new file mode 100644
index 0000000..2aa5cc7
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-open.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-page.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-page.png
new file mode 100644
index 0000000..604f9ad
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-page.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-parent-old.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-parent-old.png
new file mode 100644
index 0000000..b82d7a9
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-parent-old.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-parent.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-parent.png
new file mode 100644
index 0000000..3c964f1
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder-parent.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder.png
new file mode 100644
index 0000000..7c613e0
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/folder.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/gif.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/gif.png
new file mode 100644
index 0000000..01a2f2a
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/gif.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/gzip.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/gzip.png
new file mode 100644
index 0000000..99ae6fc
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/gzip.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/h.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/h.png
new file mode 100644
index 0000000..d3c7a9c
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/h.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/hpp.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/hpp.png
new file mode 100644
index 0000000..e5e52e2
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/hpp.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/html.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/html.png
new file mode 100644
index 0000000..2f94a78
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/html.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/ico.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/ico.png
new file mode 100644
index 0000000..82227e8
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/ico.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/image.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/image.png
new file mode 100644
index 0000000..add1c59
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/image.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/install.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/install.png
new file mode 100644
index 0000000..0a9c036
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/install.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/java.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/java.png
new file mode 100644
index 0000000..63b8683
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/java.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/jpg.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/jpg.png
new file mode 100644
index 0000000..a50c99b
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/jpg.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/js.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/js.png
new file mode 100644
index 0000000..af1a475
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/js.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/json.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/json.png
new file mode 100644
index 0000000..af1a475
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/json.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/log.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/log.png
new file mode 100644
index 0000000..02f1b9a
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/log.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/makefile.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/makefile.png
new file mode 100644
index 0000000..f99ea4c
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/makefile.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/markdown.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/markdown.png
new file mode 100644
index 0000000..25c8373
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/markdown.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/package.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/package.png
new file mode 100644
index 0000000..fb1343e
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/package.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/pdf.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/pdf.png
new file mode 100644
index 0000000..7408d8d
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/pdf.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/php.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/php.png
new file mode 100644
index 0000000..22c4df6
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/php.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/playlist.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/playlist.png
new file mode 100644
index 0000000..8d6f281
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/playlist.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/png.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/png.png
new file mode 100644
index 0000000..1fe1ec4
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/png.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/pres.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/pres.png
new file mode 100644
index 0000000..db195e9
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/pres.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/ps.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/ps.png
new file mode 100644
index 0000000..05f3ed9
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/ps.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/psd.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/psd.png
new file mode 100644
index 0000000..62718ee
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/psd.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/py.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/py.png
new file mode 100644
index 0000000..0aaffd1
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/py.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rar.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rar.png
new file mode 100644
index 0000000..8a0ff54
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rar.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rb.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rb.png
new file mode 100644
index 0000000..c7db42f
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rb.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/readme.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/readme.png
new file mode 100644
index 0000000..3ae48cd
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/readme.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rpm.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rpm.png
new file mode 100644
index 0000000..64699ac
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rpm.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rss.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rss.png
new file mode 100644
index 0000000..a1130a1
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rss.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rtf.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rtf.png
new file mode 100644
index 0000000..25c8373
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/rtf.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/script.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/script.png
new file mode 100644
index 0000000..1099b5f
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/script.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/source.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/source.png
new file mode 100644
index 0000000..5bef920
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/source.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/sql.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/sql.png
new file mode 100644
index 0000000..b3b1467
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/sql.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/tar.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/tar.png
new file mode 100644
index 0000000..bab3b6a
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/tar.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/tex.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/tex.png
new file mode 100644
index 0000000..1487b25
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/tex.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/text.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/text.png
new file mode 100644
index 0000000..1d48677
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/text.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/tiff.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/tiff.png
new file mode 100644
index 0000000..819e64c
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/tiff.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/unknown.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/unknown.png
new file mode 100644
index 0000000..b1dcc3f
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/unknown.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/vcal.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/vcal.png
new file mode 100644
index 0000000..3d81455
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/vcal.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/video.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/video.png
new file mode 100644
index 0000000..f92f7e1
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/video.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/xml.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/xml.png
new file mode 100644
index 0000000..83a83df
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/xml.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/zip.png b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/zip.png
new file mode 100644
index 0000000..cc196c1
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/icons/zip.png
Binary files differ
diff --git a/flakes/mypackages/pkgs/webapps/apache-theme/theme/style.css b/flakes/mypackages/pkgs/webapps/apache-theme/theme/style.css
new file mode 100644
index 0000000..e46139f
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/apache-theme/theme/style.css
@@ -0,0 +1,160 @@
1/*------------------------------------*\
2 Apaxy
3 by @adamwhitcroft
4
5 Theme name: Apaxy
6 Theme author: @adamwhitcroft
7\*------------------------------------*/
8@import url('//assets.immae.eu/fonts/OpenSans/font.css');
9/* Have to use @import for the font, as you can only specify a single stylesheet */
10* {
11 margin:0;
12 padding:0;
13 -webkit-box-sizing:border-box;
14 -moz-box-sizing:border-box;
15 box-sizing: border-box;
16}
17
18html {
19 min-height:100%;
20 border-top:10px solid #ECEEF1;
21 border-bottom:10px solid #ECEEF1;
22 color:#61666c;
23 font-weight:400;
24 font-size:1em;
25 font-family:'Open Sans', sans-serif;
26 line-height:2em;
27}
28body {
29 padding:20px;
30 -webkit-backface-visibility:hidden;
31}
32code {
33 font-family:consolas,monospace;
34}
35a {
36 color:#61666c;
37 text-decoration:none;
38}
39a, img {
40 border:none;
41 outline:none
42}
43a:hover {
44 color:#2a2a2a;
45}
46/*------------------------------------*\
47 Wrapper
48\*------------------------------------*/
49.wrapper {
50 margin:0 auto;
51 padding-top:20px;
52 max-width:80%;
53}
54/*------------------------------------*\
55 Demo block
56\*------------------------------------*/
57.block {
58 font-size:.875em;
59 margin:20px 0;
60 padding:20px;
61 color:#9099A3;
62}
63/*------------------------------------*\
64 Table (directory listing)
65\*------------------------------------*/
66table {
67 width:100%;
68 border-collapse:collapse;
69 font-size:.875em;
70}
71tr {
72 outline:0;
73 border:0;
74}
75tr:hover td {
76 background:#f6f6f6;
77}
78th {
79 text-align:left;
80 font-size:.75em;
81 padding-right:20px;
82}
83/* 2nd Column: Filename */
84th + th {
85 width:65%;
86}
87/* 3rd Column: Last Modified */
88th + th + th {
89}
90/* 4th Column: Size */
91th + th + th + th {
92 width:5%;
93}
94tr td:first-of-type {
95 padding-left:10px;
96 padding-right:10px;
97}
98td {
99 padding:5px 0;
100 outline:0;
101 border:0;
102 border-bottom:1px solid #edf1f5;
103 vertical-align:middle;
104 text-align:left;
105 -webkit-transition:background 300ms ease;
106 -moz-transition:background 300ms ease;
107 -ms-transition:background 300ms ease;
108 -o-transition:background 300ms ease;
109 transition:background 300ms ease;
110}
111td a{
112 display: block;
113}
114tr.parent a[href^="/"] {
115 color:#9099A3;
116}
117 .parent a[href^="/"]:hover {
118 color:#2281d0;
119 }
120/*------------------------------------*\
121 Footer
122\*------------------------------------*/
123.footer {
124 text-align:center;
125 font-size:.75em;
126}
127
128h1#pagetitle {
129 text-align: center;
130}
131tr.parent a[href="/"]{
132 display: none;
133}
134
135tr.indexhead {
136 visibility: hidden;
137}
138
139th.indexcollastmod, td.indexcollastmod, th.indexcolsize, td.indexcolsize {
140 visibility: hidden;
141}
142
143.instructions a {
144 text-decoration: underline;
145}
146
147.instructions h2 {
148 margin-top: 10px;
149}
150.instructions em.important:before {
151 content: "⚠ Important ⚠ ";
152 color: red;
153}
154.instructions pre {
155 width: 50em;
156 padding: 10px 15px;
157 display: table;
158 border: 1px inset black;
159 line-height: 1em;
160}
diff --git a/flakes/mypackages/pkgs/webapps/awl/default.nix b/flakes/mypackages/pkgs/webapps/awl/default.nix
new file mode 100644
index 0000000..dc78339
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/awl/default.nix
@@ -0,0 +1,16 @@
1{ stdenv, fetchurl }:
2stdenv.mkDerivation rec {
3 version = "0.62";
4 name = "awl-${version}";
5 src = fetchurl {
6 url = "https://www.davical.org/downloads/awl_${version}.orig.tar.xz";
7 sha256 = "0x9pr8sq3bicnvzsxfwdsqxnvfygn6gy5pawmm6i6fyb1p5h5izz";
8 };
9 unpackCmd = ''
10 tar --one-top-level -xf $curSrc
11 '';
12 installPhase = ''
13 mkdir -p $out
14 cp -ra dba docs inc scripts tests $out
15 '';
16}
diff --git a/flakes/mypackages/pkgs/webapps/davical/default.nix b/flakes/mypackages/pkgs/webapps/davical/default.nix
new file mode 100644
index 0000000..045a93b
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/davical/default.nix
@@ -0,0 +1,23 @@
1{ davical_config ? "/etc/davical/config.php", stdenv, fetchurl, gettext }:
2stdenv.mkDerivation rec {
3 version = "1.1.10";
4 name = "davical-${version}";
5 src = fetchurl {
6 url = "https://www.davical.org/downloads/davical_${version}.orig.tar.xz";
7 sha256 = "1d8zw558qrz2rybdv853ai04ar7v5a2dsypnffapx9ihgnrv4hq3";
8 };
9 unpackCmd = ''
10 tar --one-top-level -xf $curSrc
11 '';
12 makeFlags = "all";
13 patchPhase = ''
14 # https://gitlab.com/davical-project/davical/-/issues/229
15 sed -i -e 's/"newpass1"/"newpass1", "password"/g' htdocs/always.php
16 '';
17 installPhase = ''
18 mkdir -p $out
19 cp -ra config dba docs htdocs inc locale po scripts testing zonedb $out
20 ln -s ${davical_config} $out/config/config.php
21 '';
22 buildInputs = [ gettext ];
23}
diff --git a/flakes/mypackages/pkgs/webapps/default.nix b/flakes/mypackages/pkgs/webapps/default.nix
new file mode 100644
index 0000000..18a724d
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/default.nix
@@ -0,0 +1,24 @@
1{ callPackage, mylibs, composerEnv, sources }:
2rec {
3 adminer = callPackage ./adminer {};
4 apache-theme = import ./apache-theme;
5 awl = callPackage ./awl {};
6 davical = callPackage ./davical {};
7 dokuwiki = callPackage ./dokuwiki {};
8 infcloud = callPackage ./infcloud {};
9 mantisbt_2 = callPackage ./mantisbt_2 {};
10 nextcloud_25 = callPackage ./nextcloud { nextcloudVersion = 25; };
11 nextcloud_26 = callPackage ./nextcloud { nextcloudVersion = 26; };
12 nextcloud_27 = callPackage ./nextcloud { nextcloudVersion = 27; };
13 nextcloud_25-all = nextcloud_25.withApps (a: builtins.attrValues nextcloud_25.allSupportedApps);
14 nextcloud_26-all = nextcloud_26.withApps (a: builtins.attrValues nextcloud_26.allSupportedApps);
15 nextcloud_27-all = nextcloud_27.withApps (a: builtins.attrValues nextcloud_27.allSupportedApps);
16 phpbb = callPackage ./phpbb {};
17 phpldapadmin = callPackage ./phpldapadmin {};
18 rompr = callPackage ./rompr {};
19 roundcubemail = callPackage ./roundcubemail {};
20 spip = callPackage ./spip {};
21 ttrss = callPackage ./ttrss { inherit sources; };
22 wallabag = callPackage ./wallabag { inherit composerEnv; };
23 yourls = callPackage ./yourls {};
24}
diff --git a/flakes/mypackages/pkgs/webapps/dokuwiki/default.nix b/flakes/mypackages/pkgs/webapps/dokuwiki/default.nix
new file mode 100644
index 0000000..db8be30
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/dokuwiki/default.nix
@@ -0,0 +1,54 @@
1{ varDir ? "/var/lib/dokuwiki", preload ? "", lib, callPackage, stdenv, fetchFromGitHub, writeText }:
2let
3 preloadFile = plugins: let preloads = [preload]
4 ++ builtins.concatMap (p: lib.optional (lib.hasAttr "preload" p) (p.preload p)) plugins;
5 in writeText "preload.php" (''
6 <?php
7 '' + builtins.concatStringsSep "\n" preloads
8 );
9 pluginNames = [ "farmer" "todo" ];
10 allPlugins = lib.attrsets.genAttrs pluginNames
11 (name: callPackage (./plugins + "/${name}.nix") {});
12 toPassthru = pkg: plugins: {
13 inherit plugins varDir allPlugins;
14 withPlugins = withPlugins pkg;
15 };
16 withPlugins = pkg: toPlugins:
17 let
18 plugins = toPlugins allPlugins;
19 toInstallPlugin = n:
20 "ln -sf ${n} $out/lib/plugins/${n.pluginName}";
21 newDokuwiki = pkg.overrideAttrs(old: {
22 installPhase = old.installPhase + "\n" + builtins.concatStringsSep "\n" (map toInstallPlugin plugins);
23 installPreloadPhase = ''
24 cp ${preloadFile (pkg.plugins ++ plugins)} $out/inc/preload.php
25 '';
26 passthru = toPassthru newDokuwiki (pkg.plugins ++ plugins);
27 });
28 in newDokuwiki;
29 package = stdenv.mkDerivation (rec {
30 pname = "dokuwiki";
31 version = "release_stable_2018-04-22b";
32 src = fetchFromGitHub {
33 owner = "splitbrain";
34 repo = "dokuwiki";
35 rev = "871dae1320b40211626c7ec665f5e6d5290aca95";
36 sha256 = "1syvd5dvv3v75swf8ig7dxqs0g5xikb0f6vlcy7g4c4ghldkw7nz";
37 fetchSubmodules = true;
38 };
39 phases = "unpackPhase buildPhase installPhase installPreloadPhase fixupPhase";
40 buildPhase = ''
41 mv conf conf.dist
42 mv data data.dist
43 '';
44 installPhase = ''
45 cp -a . $out
46 ln -sf ${varDir}/{conf,data} $out/
47 ln -sf ${varDir}/conf/.htaccess $out/
48 '';
49 installPreloadPhase = ''
50 cp ${preloadFile []} $out/inc/preload.php
51 '';
52 passthru = toPassthru package [];
53 });
54in package
diff --git a/flakes/mypackages/pkgs/webapps/dokuwiki/plugins/farmer.nix b/flakes/mypackages/pkgs/webapps/dokuwiki/plugins/farmer.nix
new file mode 100644
index 0000000..b737b2d
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/dokuwiki/plugins/farmer.nix
@@ -0,0 +1,25 @@
1{ stdenv, fetchFromGitHub }:
2stdenv.mkDerivation rec {
3 version = "72b8577-master";
4 name = "dokuwiki-plugin-farmer-${version}";
5 src = fetchFromGitHub {
6 owner = "cosmocode";
7 repo = "dokuwiki-plugin-farmer";
8 rev = "72b857734fd164bf79cc6e17abe56491d55c1072";
9 sha256 = "1c9vc1z7yvzjz4p054kshb9yd00a4bb52s43k9zav0lvwvjij9l0";
10 };
11 installPhase = ''
12 mkdir $out
13 cp -a * $out
14 '';
15 passthru = {
16 pluginName = "farmer";
17 preload = out: ''
18 # farm setup by farmer plugin
19 if (file_exists('${out}/DokuWikiFarmCore.php'))
20 {
21 include('${out}/DokuWikiFarmCore.php');
22 }
23 '';
24 };
25}
diff --git a/flakes/mypackages/pkgs/webapps/dokuwiki/plugins/todo.nix b/flakes/mypackages/pkgs/webapps/dokuwiki/plugins/todo.nix
new file mode 100644
index 0000000..a3e03fb
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/dokuwiki/plugins/todo.nix
@@ -0,0 +1,18 @@
1{ stdenv, fetchFromGitHub }:
2stdenv.mkDerivation rec {
3 version = "49068ec-master";
4 name = "dokuwiki-plugin-todo-${version}";
5 src = fetchFromGitHub {
6 owner = "leibler";
7 repo = "dokuwiki-plugin-todo";
8 rev = "49068ecea455ea997d1e4a7adab171ccaf8228e8";
9 sha256 = "1jaq623kp14fyhamsas5mk9ryqlk4q6x6znijrb5xhcdg3r83gmq";
10 };
11 installPhase = ''
12 mkdir $out
13 cp -a * $out
14 '';
15 passthru = {
16 pluginName = "todo";
17 };
18}
diff --git a/flakes/mypackages/pkgs/webapps/infcloud/default.nix b/flakes/mypackages/pkgs/webapps/infcloud/default.nix
new file mode 100644
index 0000000..45354fa
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/infcloud/default.nix
@@ -0,0 +1,19 @@
1{ infcloud_config ? ./infcloud_config.js, stdenv, fetchzip, ed }:
2stdenv.mkDerivation rec {
3 version = "0.13.2rc1";
4 name = "InfCloud-${version}";
5 src = fetchzip {
6 url = "https://www.inf-it.com/InfCloud_${version}.zip";
7 sha256 = "1qgw6l7ccfkyzcw9dxcjwhxw9q27c0x9w584amc579mmrn9ppz3n";
8 };
9 buildPhase = ''
10 patchShebangs .
11 ./cache_update.sh
12 rm config.js
13 '';
14 installPhase = ''
15 cp -a . $out
16 ln -s ${infcloud_config} $out/config.js
17 '';
18 buildInputs = [ ed ];
19}
diff --git a/flakes/mypackages/pkgs/webapps/infcloud/infcloud_config.js b/flakes/mypackages/pkgs/webapps/infcloud/infcloud_config.js
new file mode 100644
index 0000000..ba73860
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/infcloud/infcloud_config.js
@@ -0,0 +1,1446 @@
1/*
2InfCloud - the open source CalDAV/CardDAV Web Client
3Copyright (C) 2011-2015
4 Jan Mate <jan.mate@inf-it.com>
5 Andrej Lezo <andrej.lezo@inf-it.com>
6 Matej Mihalik <matej.mihalik@inf-it.com>
7
8This program is free software: you can redistribute it and/or modify
9it under the terms of the GNU Affero General Public License as
10published by the Free Software Foundation, either version 3 of the
11License, or (at your option) any later version.
12
13This program is distributed in the hope that it will be useful,
14but WITHOUT ANY WARRANTY; without even the implied warranty of
15MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16GNU Affero General Public License for more details.
17
18You should have received a copy of the GNU Affero General Public License
19along with this program. If not, see <http://www.gnu.org/licenses/>.
20*/
21
22
23// NOTE: see readme.txt before you start to configure this client!
24
25
26// NOTE: do not forget to execute the cache_update.sh script every time you
27// update this configuration file or any other files (otherwise your browser
28// will use the previous version of files stored in HTML5 cache). Alternatively
29// you can update the cache.manifest manually - edit the second line beginning
30// with "#V 20" to anything else (this file simple needs "some" change)
31
32
33// Supported setup types (use ONE of them):
34// a.) globalAccountSettings => username and password is hardcoded
35// in config.js, automatic login without the login screen
36// - advantages: fast login process = no username/password is required
37// - disadvantages: username/password is visible in your config.js, so
38// this type of setup is recommended ONLY for intranet/home users
39// b.) globalNetworkCheckSettings => standard setup with login screen
40// - advantages: username/password is required (no visible
41// username/password in config.js)
42// - disadvantages: if a user enters wrong username/password then
43// the browser will show authentication popup window (it is NOT
44// possible to disable it in JavaScript; see the next option)
45// c.) globalNetworkAccountSettings => advanced setup with login screen
46// - advantages: no authentication popup if you enter wrong username/
47// password, dynamic XML configuration generator (you can generate
48// different configurations for your users /by modifying the "auth"
49// module configuration or the PHP code itself/)
50// - disadvantages: requires PHP >= 5.3 and additional configuration,
51// only basic http authentication is supported => always use https!
52//
53//
54// What is a "principal URL"? => Check you server documentation!
55// - "principal URL" is NOT "collection URL"
56// - this client automatically detects collections for "principal URL"
57// - PROPER "principal URL" looks like:
58// https://server.com:8443/principals/users/USER/
59// https://server.com:8443/caldav.php/USER/
60// - INVALID principal URL looks like:
61// https://server.com:8443/principals/users/USER/collection/
62// => this is a collection URL
63// https://server.com:8443/caldav.php/USER/collection/
64// => this is a collection URL
65// https://server.com:8443/principals/users/USER
66// => missing trailing '/'
67// https://server.com:8443/caldav.php/USER
68// => missing trailing '/'
69// /caldav.php/USER/
70// => relative URL instead of full URL
71//
72//
73// List of properties used in globalAccountSettings, globalNetworkCheckSettings
74// and globalNetworkAccountSettings variables (+ in the "auth" module):
75// - href
76// Depending on the setup type set the value to:
77// a.) globalAccountSettings: full "principal URL"
78// b.) globalNetworkCheckSettings: "principal URL" WITHOUT the "USER/" part
79// c.) globalNetworkAccountSettings: "full URL" to the "auth" directory
80// This property is supported in:
81// globalAccountSettings
82// globalNetworkCheckSettings
83// globalNetworkAccountSettings
84// - userAuth
85// - userName
86// Set the username you want to login.
87// - userPassword
88// Set the password for the given username.
89// This property is supported in:
90// globalAccountSettings
91// - timeOut
92// This option sets the timeout for jQuery .ajax call (in miliseconds).
93// Example:
94// timeOut: 90000
95// This property is supported in:
96// globalAccountSettings
97// globalNetworkCheckSettings
98// globalNetworkAccountSettings
99// - lockTimeOut
100// NOTE: used only if server supports LOCK requests
101// This option sets the LOCK timeout value if resource locking
102// is used (in miliseconds).
103// Example:
104// lockTimeOut: 10000
105// This property is supported in:
106// globalAccountSettings
107// globalNetworkCheckSettings
108// globalNetworkAccountSettings (available in auth module only)
109// - checkContentType
110// This option enables a content-type checking for server response.
111// If enabled then only objects with proper content-type are inserted
112// into the interface.
113// If you cannot see data in the interface you may try to disable it (useful
114// if your server returns wrong value in "propstat/prop/getcontenttype").
115// If undefined then content-type checking is enabled.
116// Examples:
117// checkContentType: true
118// checkContentType: false
119// This property is supported in:
120// globalAccountSettings
121// globalNetworkCheckSettings
122// globalNetworkAccountSettings (available in auth module only)
123// - settingsAccount
124// NOTE: server support for custom DAV properties is REQUIRED!
125// This option sets the account where the client properties such as:
126// loaded collections, enabled collections, ... are saved during
127// the logout and resource/collection synchronisation
128// NOTE: set it to true ONLY for ONE account!
129// Examples:
130// settingsAccount: true
131// settingsAccount: false
132// This property is supported in:
133// globalAccountSettings
134// globalNetworkCheckSettings
135// globalNetworkAccountSettings (available in auth module only)
136// - delegation
137// NOTE: server support for this functionality is REQUIRED!
138// This option allows you to load delegated (shared) collections.
139// If set to true (default) then delegation functionality is enabled,
140// and the interface allows you to load delegated collections.
141// If false then delegation functionality is completely disabled.
142// Examples:
143// delegation: true
144// delegation: false
145// This property is supported in:
146// globalAccountSettings
147// globalNetworkCheckSettings
148// globalNetworkAccountSettings (available in auth module only)
149// - additionalResources
150// This options sets the list of additional resources (e.g. shared resources
151// accessible by all users). If the server supports delegation (see
152// the delegation option above) there is no reason to use this option!
153// Supported values:
154// - array of URL encoded resource names (not collections), such as:
155// 'company'
156// 'shared_resource'
157// If empty (default) or undefined then shared resources are not loaded
158// using this option, but may be loaded using the delegation option.
159// Examples:
160// additionalResources=[]
161// additionalResources=['public', 'shared_resource']
162// This property is supported in:
163// globalNetworkCheckSettings
164// - hrefLabel
165// This option sets the server name in the resource header (useful if
166// you want to see custom resource header above the collections).
167// You can use the following variables in the value:
168// %H = full hostname (including the port number)
169// %h = full hostname (without the port number)
170// %D = full domain name
171// %d = only the first and second level domain
172// %P = principal name
173// %p = principal name without the @domain.com part (if present)
174// %U = logged user name
175// %u = logged user name without the @domain.com part (if present)
176// If undefined, empty or or null then '%d/%p [%u]' is used.
177// Examples:
178// hrefLabel: '%d/%p [%u]'
179// hrefLabel: '%D/%u'
180// This property is supported in:
181// globalAccountSettings
182// globalNetworkCheckSettings
183// globalNetworkAccountSettings (available in auth module only)
184// - forceReadOnly
185// This option sets the list of collections as "read-only".
186// Supported values:
187// - true
188// all collections will be "read-only"
189// - array of URL encoded
190// - collections, such as:
191// '/caldav.php/user/calendar/'
192// '/caldav.php/user%40domain.com/calendar/'
193// - regexes, such as:
194// new RegExp('^/caldav.php/user/calendar[0-9]/$', 'i')
195// specifies the list of collections marked as "read-only"
196// If null (default) or undefined then server detected privileges are used.
197// Examples:
198// forceReadOnly: null
199// forceReadOnly: true
200// forceReadOnly: ['/caldav.php/user/calendar/',
201// '/caldav.php/user/calendar2/']
202// forceReadOnly: [new RegExp('^/.*/user/calendar[0-9]/$', 'i')]
203// This property is supported in:
204// globalAccountSettings
205// globalNetworkCheckSettings
206// globalNetworkAccountSettings (available in auth module only, with
207// different syntax for regexes)
208// - ignoreAlarms
209// This option sets list of calendar collections with disabled
210// alarm functionality.
211// Supported values:
212// - true
213// alarm functionality is disabled for all collections
214// - array of URL encoded
215// - collections, such as:
216// '/caldav.php/user/calendar/'
217// '/caldav.php/user%40domain.com/calendar/'
218// - regexes, such as:
219// new RegExp('^/caldav.php/user/calendar[0-9]/$', 'i')
220// specifies the list of collections with disabled alarm functionality.
221// If false (default) or undefined then alarm functionality is enabled
222// for all collections.
223// Examples:
224// ignoreAlarms: true
225// ignoreAlarms: ['/caldav.php/user/calendar/',
226// '/caldav.php/user/calendar2/']
227// ignoreAlarms: [new RegExp('^/.*/user/calendar[0-9]/$', 'i')]
228// This property is supported in:
229// globalAccountSettings
230// globalNetworkCheckSettings
231// globalNetworkAccountSettings (available in auth module only, with
232// different syntax for regexes)
233// - backgroundCalendars
234// This options defines a list of background calendars. If there is
235// at least one event defined for the given day in a background calendar,
236// the background color for that day will be pink/light-red.
237// Supported values:
238// - array of URL encoded
239// - collections, such as:
240// '/caldav.php/user/calendar/'
241// '/caldav.php/user%40domain.com/calendar/'
242// - regexes, such as:
243// new RegExp('^/caldav.php/user/calendar[0-9]/$', 'i')
244// specifies the list of background calendar collections.
245// Examples:
246// backgroundCalendars: ['/caldav.php/user/calendar/',
247// '/caldav.php/user/calendar2/']
248// backgroundCalendars: [new RegExp('^/.*/user/calendar[0-9]/$', 'i')]
249// This property is supported in:
250// globalAccountSettings
251// globalNetworkCheckSettings
252// globalNetworkAccountSettings (available in auth module only, with
253// different syntax for regexes)
254// Special options not present in configuration examples:
255// NOTE: use ONLY if you know what are you doing!
256// - crossDomain
257// This option sets the crossDomain for jQuery .ajax call. If null (default)
258// then the value is autodetected /and the result is shown in the console/
259// - withCredentials
260// This option sets the withCredentials for jQuery .ajax call. The default
261// value is false and there is NO REASON to change it to true!
262// NOTE: if true, Access-Control-Allow-Origin "*" (CORS header) not works!
263
264
265// globalAccountSettings
266// Use this option if you want to use automatic login (without a login
267// screen) with hardcoded username/password in config.js. Otherwise use
268// globalNetworkCheckSettings or globalNetworkAccountSettings (see below).
269// NOTE: if this option is used the value must be an array of object(s).
270// List of properties used in globalAccountSettings variable:
271// - href
272// Set this option to the full "principal URL".
273// NOTE: the last character in the value must be '/'
274// - userAuth
275// - userName
276// Set the username you want to login.
277// - userPassword
278// Set the password for the given username.
279// NOTE: for description of other properties see comments at the beginning
280// of this file.
281// NOTE: for minimal/fast setup you need to set only the href and userAuth
282// options. It is safe/recommended to keep the remaining options unchanged!
283// Example:
284//var globalAccountSettings=[
285// {
286// href: 'https://server1.com:8443/caldav.php/USERNAME1/',
287// userAuth:
288// {
289// userName: 'USERNAME1',
290// userPassword: 'PASSWORD1'
291// },
292// timeOut: 90000,
293// lockTimeOut: 10000,
294// checkContentType: true,
295// settingsAccount: true,
296// delegation: true,
297// hrefLabel: null,
298// forceReadOnly: null,
299// ignoreAlarms: false,
300// backgroundCalendars: []
301// },
302// {
303// href: 'https://server2.com:8443/caldav.php/USERNAME2/',
304// ...
305// ...
306// }
307//];
308
309
310// globalNetworkCheckSettings
311// Use this option if you want to use standard login screen without
312// hardcoded username/password in config.js (used by globalAccountSettings).
313// NOTE: if this option is used the value must be an object.
314// List of properties used in globalAccountSettings variable:
315// - href
316// Set this option to the "principal URL" WITHOUT the "USERNAME/"
317// part (this options uses the username from the login screen).
318// NOTE: the last character in the value must be '/'
319// NOTE: for description of other properties see comments at the beginning
320// of this file.
321// NOTE: for minimal/fast setup you need to set only the href option. It is
322// safe/recommended to keep the remaining options unchanged!
323// Example href values:
324// OS X server http example (see misc/readme_osx.txt for server setup):
325// href: 'http://osx.server.com:8008/principals/users/'
326// OS X server https example (see misc/readme_osx.txt for server setup):
327// href: 'https://osx.server.com:8443/principals/users/'
328// Cyrus server https example:
329// href: 'https://cyrus.server.com/dav/principals/user/'
330// Example:
331// Davical example which automatically detects the protocol, server name,
332// port, ... (client installed into Davical "htdocs" subdirectory;
333// works "out of the box", no additional setup required):
334var globalNetworkCheckSettings={
335 href: location.protocol+'//'+location.hostname+
336 (location.port ? ':'+location.port: '')+
337 location.pathname.replace(RegExp('/+[^/]+/*(index\.html)?$'),'')+
338 '/caldav.php/',
339 timeOut: 90000,
340 lockTimeOut: 10000,
341 checkContentType: true,
342 settingsAccount: true,
343 delegation: true,
344 additionalResources: [],
345 hrefLabel: null,
346 forceReadOnly: null,
347 ignoreAlarms: false,
348 backgroundCalendars: []
349}
350
351
352// globalNetworkAccountSettings
353// Try this option ONLY if you have working setup using
354// globalNetworkCheckSettings and want to fix the authentication popup
355// window problem (if invalid username/password is entered)!
356// If you use this option then your browser sends username/password to the PHP
357// "auth" module ("auth" directory) instead of the DAV server itself.
358// The "auth" module then validates your username/password against your server,
359// and if the authentication is successful, then it sends back a configuration
360// XML (requires additional configuration). The resulting XML is handled
361// IDENTICALLY as the globalAccountSettings configuration option.
362// NOTE: for the "auth" module configuration see readme.txt!
363// NOTE: this option invokes a login screen and disallows access until
364// the client gets correct XML configuration file from the server!
365// List of properties used in globalNetworkAccountSettings variable:
366// - href
367// Set this option to the "full URL" of the "auth" directory
368// NOTE: the last character in the value must be '/'
369// NOTE: for description of other properties see comments at the beginning
370// of this file.
371// Example href values:
372// href: 'https://server.com/client/auth/'
373// Example:
374// Use this configuration if the "auth" module is located in the client
375// installation subdirectory (default):
376//var globalNetworkAccountSettings={
377// href: location.protocol+'//'+location.hostname+
378// (location.port ? ':'+location.port : '')+
379// location.pathname.replace(RegExp('index\.html$'),'')+
380// 'auth/',
381// timeOut: 30000
382//};
383
384
385// globalUseJqueryAuth
386// Use jQuery .ajax() auth or custom header for HTTP basic auth (default).
387// Set this option to true if your server uses digest auth (note: you may
388// experience auth popups on some browsers).
389// If undefined (or empty), custom header for HTTP basic auth is used.
390// Example:
391//var globalUseJqueryAuth=false;
392
393
394// globalBackgroundSync
395// Enable background synchronization even if the browser window/tab has no
396// focus.
397// If false, synchronization is performed only if the browser window/tab
398// is focused. If undefined or not false, then background sync is enabled.
399// Example:
400var globalBackgroundSync=true;
401
402
403// globalSyncResourcesInterval
404// This option defines how often (in miliseconds) are resources/collections
405// asynchronously synchronized.
406// Example:
407var globalSyncResourcesInterval=120000;
408
409
410// globalEnableRefresh
411// This option enables or disables the manual synchronization button in
412// the interface. If this option is enabled then users can perform server
413// synchronization manually. Enabling this option may cause high server
414// load (even DDOS) if users will try to manually synchronize data too
415// often (instead of waiting for the automatic synchronization).
416// If undefined or false, the synchronization button is disabled.
417// NOTE: enable this option only if you really know what are you doing!
418// Example:
419var globalEnableRefresh=false;
420
421
422// globalEnableKbNavigation
423// Enable basic keyboard navigation using arrow keys?
424// If undefined or not false, keyboard navigation is enabled.
425// Example:
426var globalEnableKbNavigation=true;
427
428
429// globalSettingsType
430// Where to store user settings such as: active view, enabled/selected
431// collections, ... (the client store them into DAV property on the server).
432// NOTE: not all servers support storing DAV properties (some servers support
433// only subset /or none/ of these URLs).
434// Supported values:
435// - 'principal-URL', '', null or undefined (default) => settings are stored
436// to principal-URL (recommended for most servers)
437// - 'addressbook-home-set' => settings are are stored to addressbook-home-set
438// - 'calendar-home-set' => settings are stored to calendar-home-set
439// Example:
440//var globalSettingsType='';
441
442
443// globalCrossServerSettingsURL
444// Settings such as enabled/selected collections are stored on the server
445// (see the previous option) in form of full URL
446// (e.g.: https://user@server:port/principal/collection/), but even if this
447// approach is "correct" (you can use the same principal URL with multiple
448// different logins, ...) it causes a problem if your server is accessible
449// from multiple URLs (e.g. http://server/ and https://server/). If you want
450// to store only the "principal/collection/" part of the URL (instead of the
451// full URL) then enable this option.
452// Example:
453//var globalCrossServerSettingsURL=false;
454
455
456// globalInterfaceLanguage
457// Default interface language (note: this option is case sensitive):
458// cs_CZ (Čeština [Czech])
459// da_DK (Dansk [Danish]; thanks Niels Bo Andersen)
460// de_DE (Deutsch [German]; thanks Marten Gajda and Thomas Scheel)
461// en_US (English [English/US])
462// es_ES (Español [Spanish]; thanks Damián Vila)
463// fr_FR (Français [French]; thanks John Fischer)
464// it_IT (Italiano [Italian]; thanks Luca Ferrario)
465// ja_JP (日本語 [Japan]; thanks Muimu Nakayama)
466// hu_HU (Magyar [Hungarian])
467// nl_NL (Nederlands [Dutch]; thanks Johan Vromans)
468// sk_SK (Slovenčina [Slovak])
469// tr_TR (Türkçe [Turkish]; thanks Selcuk Pultar)
470// ru_RU (Русский [Russian]; thanks Александр Симонов)
471// uk_UA (Українська [Ukrainian]; thanks Serge Yakimchuck)
472// zh_CN (中国 [Chinese]; thanks Fandy)
473// Example:
474var globalInterfaceLanguage='fr_FR';
475
476
477// globalInterfaceCustomLanguages
478// If defined and not empty then only languages listed here are shown
479// at the login screen, otherwise (default) all languages are shown
480// NOTE: values in the array must refer to an existing localization
481// (see the option above)
482// Example:
483// globalInterfaceCustomLanguages=['en_US', 'sk_SK'];
484var globalInterfaceCustomLanguages=[];
485
486
487// globalSortAlphabet
488// Use JavaScript localeCompare() or custom alphabet for data sorting.
489// Custom alphabet is used by default because JavaScript localeCompare()
490// not supports collation and often returns "wrong" result. If set to null
491// then localeCompare() is used.
492// Example:
493// var globalSortAlphabet=null;
494var globalSortAlphabet=' 0123456789'+
495 'AÀÁÂÄÆÃÅĀBCÇĆČDĎEÈÉÊËĒĖĘĚFGĞHIÌÍÎİÏĪĮJKLŁĹĽMNŃÑŇOÒÓÔÖŐŒØÕŌ'+
496 'PQRŔŘSŚŠȘșŞşẞTŤȚțŢţUÙÚÛÜŰŮŪVWXYÝŸZŹŻŽ'+
497 'aàáâäæãåābcçćčdďeèéêëēėęěfgğhiìíîïīįıjklłĺľmnńñňoòóôöőœøõō'+
498 'pqrŕřsśšßtťuùúûüűůūvwxyýÿzźżžАБВГҐДЕЄЖЗИІЇЙКЛМНОПРСТУФХЦЧШЩЮЯ'+
499 'Ьабвгґдеєжзиіїйклмнопрстуфхцчшщюяь';
500
501
502// globalSearchTransformAlphabet
503// To support search without diacritics (e.g. search for 'd' will find: 'Ď', 'ď')
504// it is required to define something like "character equivalence".
505// key = regex text, value = search character
506// Example:
507var globalSearchTransformAlphabet={
508 '[ÀàÁáÂâÄäÆæÃãÅåĀā]': 'a', '[ÇçĆćČč]': 'c', '[Ďď]': 'd',
509 '[ÈèÉéÊêËëĒēĖėĘęĚě]': 'e', '[Ğğ]': 'g', '[ÌìÍíÎîİıÏïĪīĮį]': 'i',
510 '[ŁłĹ弾]': 'l', '[ŃńÑñŇň]': 'n', '[ÒòÓóÔôÖöŐőŒœØøÕõŌō]': 'o',
511 '[ŔŕŘř]': 'r', '[ŚśŠšȘșŞşẞß]': 's', '[ŤťȚțŢţ]': 't',
512 '[ÙùÚúÛûÜüŰűŮůŪū]': 'u', '[ÝýŸÿ]': 'y', '[ŹźŻżŽž]': 'z'
513};
514
515// globalResourceAlphabetSorting
516// If more than one resource (server account) is configured, sort the
517// resources alphabetically?
518// Example:
519var globalResourceAlphabetSorting=true;
520
521
522// globalNewVersionNotifyUsers
523// Update notification will be shown only to users with login names defined
524// in this array.
525// If undefined (or empty), update notifications will be shown to all users.
526// Example:
527// globalNewVersionNotifyUsers=['admin', 'peter'];
528var globalNewVersionNotifyUsers=[];
529
530
531// globalDatepickerFormat
532// Set the datepicker format (see
533// http://docs.jquery.com/UI/Datepicker/formatDate for valid values).
534// NOTE: date format is predefined for each localization - use this option
535// ONLY if you want to use custom date format (instead of the localization
536// predefined one).
537// Example:
538//var globalDatepickerFormat='dd.mm.yy';
539var globalDatepickerFormat='yy-mm-dd';
540
541
542// globalDatepickerFirstDayOfWeek
543// Set the datepicker first day of the week: Sunday is 0, Monday is 1, etc.
544// Example:
545var globalDatepickerFirstDayOfWeek=1;
546
547
548// globalHideInfoMessageAfter
549// How long are information messages (such as: success, error) displayed
550// (in miliseconds).
551// Example:
552var globalHideInfoMessageAfter=1800;
553
554
555// globalEditorFadeAnimation
556// Set the editor fade in/out animation duration when editing or saving data
557// (in miliseconds).
558// Example:
559var globalEditorFadeAnimation=666;
560
561
562
563
564// ******* CalDAV (CalDavZAP) related settings ******* //
565
566// globalEventStartPastLimit, globalEventStartFutureLimit, globalTodoPastLimit
567// Number of months pre-loaded from past/future in advance for calendars
568// and todo lists (if null then date range synchronization is disabled).
569// NOTE: interval synchronization is used only if your server supports
570// sync-collection REPORT (e.g. DAViCal).
571// NOTE: if you experience problems with data loading and your server has
572// no time-range filtering support set these variables to null.
573// Example:
574var globalEventStartPastLimit=3;
575var globalEventStartFutureLimit=3;
576var globalTodoPastLimit=1;
577
578
579// globalLoadedCalendarCollections
580// This option sets the list of calendar collections (down)loaded after login.
581// If empty then all calendar collections for the currently logged user are
582// loaded.
583// NOTE: settings stored on the server (see settingsAccount) overwrite this
584// option.
585// Example:
586var globalLoadedCalendarCollections=[];
587
588
589// globalLoadedTodoCollections
590// This option sets the list of todo collections (down)loaded after login.
591// If empty then all todo collections for the currently logged user are loaded.
592// NOTE: settings stored on the server (see settingsAccount) overwrite this
593// option.
594// Example:
595var globalLoadedTodoCollections=[];
596
597
598// globalActiveCalendarCollections
599// This options sets the list of calendar collections checked (enabled
600// checkbox => data visible in the interface) by default after login.
601// If empty then all loaded calendar collections for the currently logged
602// user are checked.
603// NOTE: only already (down)loaded collections can be checked (see
604// the globalLoadedCalendarCollections option).
605// NOTE: settings stored on the server (see settingsAccount) overwrite this
606// option.
607// Example:
608var globalActiveCalendarCollections=[];
609
610
611// globalActiveTodoCollections
612// This options sets the list of todo collections checked (enabled
613// checkbox => data visible in the interface) by default after login.
614// If empty then all loaded todo collections for the currently logged
615// user are checked.
616// NOTE: only already (down)loaded collections can be checked (see
617// the globalLoadedTodoCollections option).
618// NOTE: settings stored on the server (see settingsAccount) overwrite this
619// option.
620// Example:
621var globalActiveTodoCollections=[];
622
623
624// globalCalendarSelected
625// This option sets which calendar collection will be pre-selected
626// (if you create a new event) by default after login.
627// The value must be URL encoded path to a calendar collection,
628// for example: 'USER/calendar/'
629// If empty or undefined then the first available calendar collection
630// is selected automatically.
631// NOTE: only already (down)loaded collections can be pre-selected (see
632// the globalLoadedCalendarCollections option).
633// NOTE: settings stored on the server (see settingsAccount) overwrite this
634// option.
635// Example:
636//var globalCalendarSelected='';
637
638
639// globalTodoCalendarSelected
640// This option sets which todo collection will be pre-selected
641// (if you create a new todo) by default after login.
642// The value must be URL encoded path to a todo collection,
643// for example: 'USER/todo_calendar/'
644// If empty or undefined then the first available todo collection
645// is selected automatically.
646// NOTE: only already (down)loaded collections can be pre-selected (see
647// the globalLoadedTodoCollections option).
648// NOTE: settings stored on the server (see settingsAccount) overwrite this
649// option.
650// Example:
651//var globalTodoCalendarSelected='';
652
653
654// globalActiveView
655// This options sets the default fullcalendar view option (the default calendar
656// view after the first login).
657// Supported values:
658// - 'month'
659// - 'multiWeek'
660// - 'agendaWeek'
661// - 'agendaDay'
662// NOTE: we use custom and enhanced version of fullcalendar!
663// Example:
664var globalActiveView='multiWeek';
665
666
667// globalOpenFormMode
668// Open new event form on 'single' or 'double' click.
669// If undefined or not 'double', then 'single' is used.
670// Example:
671var globalOpenFormMode='double';
672
673
674// globalTodoListFilterSelected
675// This options sets the list of filters in todo list that are selected
676// after login.
677// Supported options:
678// - 'filterAction'
679// - 'filterProgress' (available only if globalAppleRemindersMode is disabled)
680// - 'filterCompleted'
681// - 'filterCanceled' (available only if globalAppleRemindersMode is disabled)
682// NOTE: settings stored on the server (see settingsAccount) overwrite this
683// option.
684// Example:
685var globalTodoListFilterSelected=['filterAction', 'filterProgress'];
686
687
688// globalCalendarStartOfBusiness, globalCalendarEndOfBusiness
689// These options set the start and end of business hours with 0.5 hour
690// precision. Non-business hours are faded out in the calendar interface.
691// If both variables are set to the same value then no fade out occurs.
692// Example:
693var globalCalendarStartOfBusiness=8;
694var globalCalendarEndOfBusiness=17;
695
696
697// globalDefaultEventDuration
698// This option sets the default duration (in minutes) for newly created events.
699// If undefined or null, globalCalendarEndOfBusiness value will be taken as
700// a default end time instead.
701// Example:
702var globalDefaultEventDuration=120;
703
704
705// globalAMPMFormat
706// This option enables to use 12 hours format (AM/PM) for displaying time.
707// NOTE: time format is predefined for each localization - use this option
708// ONLY if you want to use custom time format (instead of the localization
709// predefined one).
710// Example:
711//var globalAMPMFormat=false;
712
713
714// globalTimeFormatBasic
715// This option defines the time format information for events in month and
716// multiweek views. If undefined or null then default value is used.
717// If defined as empty string no time information is shown in these views.
718// See http://arshaw.com/fullcalendar/docs/utilities/formatDate/ for exact
719// formating rules.
720// Example:
721//var globalTimeFormatBasic='';
722
723
724// globalTimeFormatAgenda
725// This option defines the time format information for events in day and
726// week views. If undefined or null then default value is used.
727// If defined as empty string no time information is shown in these views.
728// See http://arshaw.com/fullcalendar/docs/utilities/formatDate/ for exact
729// formating rules.
730// Example:
731//var globalTimeFormatAgenda='';
732
733
734// globalDisplayHiddenEvents
735// This option defined whether events from unechecked calendars are displayed
736// with certain transparency (true) or completely hidden (false).
737// Example:
738var globalDisplayHiddenEvents=false;
739
740
741// globalTimeZoneSupport
742// This option enables timezone support in the client.
743// NOTE: timezone cannot be specified for all-day events because these don't
744// have start and end time.
745// If this option is disabled then local time is used.
746// Example:
747var globalTimeZoneSupport=true;
748
749
750// globalTimeZone
751// If timezone support is enabled, this option sets the default timezone.
752// See timezones.js or use the following command to get the list of supported
753// timezones (defined in timezones.js):
754// grep "'[^']\+': {" timezones.js | sed -Ee "s#(\s*'|':\s*\{)##g"
755// Example:
756var globalTimeZone='Europe/Paris';
757
758
759// globalTimeZonesEnabled
760// This option sets the list of available timezones in the interface (for the
761// list of supported timezones see the comment for the previous configuration
762// option).
763// NOTE: if there is at least one event/todo with a certain timezone defined,
764// that timezone is enabled (even if it is not present in this list).
765// Example:
766// var globalTimeZonesEnabled=['America/New_York', 'Europe/Berlin'];
767var globalTimeZonesEnabled=[];
768
769
770// globalRewriteTimezoneComponent
771// This options sets whether the client will enhance/replace (if you edit an
772// event or todo) the timezone information using the official IANA timezone
773// database information (recommended).
774// Example:
775var globalRewriteTimezoneComponent=true;
776
777
778// globalRemoveUnknownTimezone
779// This options sets whether the client will remove all non-standard timezone
780// names from events and todos (if you edit an event or todo)
781// (e.g.: /freeassociation.sourceforge.net/Tzfile/Europe/Vienna)
782// Example:
783var globalRemoveUnknownTimezone=false;
784
785
786// globalShowHiddenAlarms
787// This option sets whether the client will show alarm notifications for
788// unchecked calendars. If this option is enabled and you uncheck a calendar
789// in the calendar list, alarm notifications will be temporary disabled for
790// unchecked calendar(s).
791// Example:
792var globalShowHiddenAlarms=false;
793
794
795// globalIgnoreCompletedOrCancelledAlarms
796// This options sets whether the client will show alarm notifications for
797// already completed or cancelled todos. If enabled then alarm notification
798// for completed and cancelled todos are disabled.
799// Example:
800var globalIgnoreCompletedOrCancelledAlarms=true;
801
802
803// globalMozillaSupport
804// Mozilla automatically treats custom repeating event calculations as if
805// the start day of the week is Monday, despite what day is chosen in settings.
806// Set this variable to true to use the same approach, ensuring compatible
807// event rendering in special cases.
808// Example:
809var globalMozillaSupport=false;
810
811
812// globalCalendarColorPropertyXmlns
813// This options sets the namespace used for storing the "calendar-color"
814// property by the client.
815// If true, undefined (or empty) "http://apple.com/ns/ical/" is used (Apple
816// compatible). If false, then the calendar color modification functionality
817// is completely disabled.
818// Example:
819//var globalCalendarColorPropertyXmlns=true;
820
821
822// globalWeekendDays
823// This option sets the list of days considered as weekend days (these
824// are faded out in the calendar interface). Non-weekend days are automatically
825// considered as business days.
826// Sunday is 0, Monday is 1, etc.
827// Example:
828var globalWeekendDays=[0, 6];
829
830
831// globalAppleRemindersMode
832// If this option is enabled then then client will use the same approach
833// for handling repeating reminders (todos) as Apple. It is STRONGLY
834// recommended to enabled this option if you use any Apple clients for
835// reminders (todos).
836// Supported options:
837// - 'iOS6'
838// - 'iOS7'
839// - true (support of the latest iOS version - 'iOS8')
840// - false
841// If this option is enabled:
842// - RFC todo support is SEVERELY limited and the client mimics the behaviour
843// of Apple Reminders.app (to ensure maximum compatibility)
844// - when a single instance of repeating todo is edited, it becomes an
845// autonomous non-repeating todo with NO relation to the original repeating
846// todo
847// - capabilities of repeating todos are limited - only the first instance
848// is ever visible in the interface
849// - support for todo DTSTART attribute is disabled
850// - support for todo STATUS attribute other than COMPLETED and NEEDS-ACTION
851// is disabled
852// - [iOS6 only] support for LOCATION and URL attributes is disabled
853// Example:
854var globalAppleRemindersMode=true;
855
856
857// globalSubscribedCalendars
858// This option specifies a list of remote URLs to ics files (e.g.: used
859// for distributing holidays information). Subscribed calendars are
860// ALWAYS read-only. Remote servers where ics files are hosted MUST
861// return proper CORS headers (see readme.txt) otherwise this functionality
862// will not work!
863// NOTE: subsribed calendars are NOT "shared" calendars. For "shared"
864// calendars see the delegation option in globalAccountSettings,
865// globalNetworkCheckSettings and globalNetworkAccountSettings.
866// List of properties used in globalSubscribedCalendars variable:
867// - hrefLabel
868// This options defines the header string above the subcsribed calendars.
869// - calendars
870// This option specifies an array of remote calendar objects with the
871// following properties:
872// - href
873// Set this option to the "full URL" of the remote calendar
874// - userAuth
875// NOTE: keep empty if remote authentication is not required!
876// - userName
877// Set the username you want to login.
878// - userPassword
879// Set the password for the given username.
880// - typeList
881// Set the list of objects you want to process from remote calendars;
882// two options are available:
883// - 'vevent' (show remote events in the interface)
884// - 'vtodo' (show remote todos in the interface)
885// - ignoreAlarm
886// Set this option to true if you want to disable alarm notifications
887// from the remote calendar.
888// - displayName
889// Set this option to the name of the calendar you want to see
890// in the interface.
891// - color
892// Set the calendar color you want to see in the interface.
893// Example:
894//var globalSubscribedCalendars={
895// hrefLabel: 'Subscribed',
896// calendars: [
897// {
898// href: 'http://something.com/calendar.ics',
899// userAuth: {
900// userName: '',
901// userPassword: ''
902// },
903// typeList: ['vevent', 'vtodo'],
904// ignoreAlarm: true,
905// displayName: 'Remote Calendar 1',
906// color: '#ff0000'
907// },
908// {
909// href: 'http://calendar.com/calendar2.ics',
910// ...
911// ...
912// }
913// ]
914//};
915
916
917
918// ******* CardDAV (CardDavMATE) related settings ******* //
919
920
921// globalLoadedAddressbookCollections
922// This option sets the list of addressbook collections (down)loaded after
923// login. If empty then all addressbook collections for the currently logged
924// user are loaded.
925// NOTE: settings stored on the server (see settingsAccount) overwrite this
926// option.
927// Example:
928var globalLoadedAddressbookCollections=[];
929
930
931// globalActiveAddressbookCollections
932// This options sets the list of addressbook collections checked (enabled
933// checkbox => data visible in the interface) by default after login.
934// If empty then all loaded addressbook collections for the currently logged
935// user are checked.
936// NOTE: only already (down)loaded collections can be checked (see
937// the globalLoadedAddressbookCollections option).
938// NOTE: settings stored on the server (see settingsAccount) overwrite this
939// option.
940// Example:
941var globalActiveAddressbookCollections=[];
942
943
944// globalAddressbookSelected
945// This option sets which addressbook collection will be pre-selected
946// (if you create a new contact) by default after login.
947// The value must be URL encoded path to an addressbook collection,
948// for example: 'USER/addressbook/'
949// If empty or undefined then the first available addressbook collection
950// is selected automatically.
951// NOTE: only already (down)loaded collections can be pre-selected (see
952// the globalLoadedAddressbookCollections option).
953// NOTE: settings stored on the server (see settingsAccount) overwrite this
954// option.
955// Example:
956//var globalAddressbookSelected='';
957
958
959// globalCompatibility
960// This options is reserved for various compatibility settings.
961// NOTE: if this option is used the value must be an object.
962// Currently there is only one supported option:
963// - anniversaryOutputFormat
964// Different clients use different (and incompatible) approach
965// to store anniversary date in vCards. Apple stores this attribute as:
966// itemX.X-ABDATE;TYPE=pref:2000-01-01\r\n
967// itemX.X-ABLabel:_$!<Anniversary>!$_\r\n'
968// other clients store this attribute as:
969// X-ANNIVERSARY:2000-01-01\r\n
970// Choose 'apple' or 'other' (lower case) for your 3rd party client
971// compatibility. You can chose both: ['apple', 'other'], but it may
972// cause many problems in the future, for example: duplicate anniversary
973// dates, invalid/old anniversary date in your clients, ...)
974// Examples:
975// anniversaryOutputFormat: ['other']
976// anniversaryOutputFormat: ['apple', 'other']
977// Example:
978var globalCompatibility={anniversaryOutputFormat: ['apple']};
979
980
981// globalUriHandler{Tel,Email,Url,Profile}
982// These options set the URI handlers for TEL, EMAIL, URL and X-SOCIALPROFILE
983// vCard attributes. Set them to null (or comment out) to disable.
984// NOTE: for globalUriHandlerTel is recommended to use 'tel:', 'callto:'
985// or 'skype:'. The globalUriHandlerUrl value is used only if no URI handler
986// is defined in the URL.
987// NOTE: it is safe to keep these values unchanged!
988// Example:
989var globalUriHandlerTel='tel:';
990var globalUriHandlerEmail='mailto:';
991var globalUriHandlerUrl='http://';
992var globalUriHandlerProfile={
993 'twitter': 'http://twitter.com/%u',
994 'facebook': 'http://www.facebook.com/%u',
995 'flickr': 'http://www.flickr.com/photos/%u',
996 'linkedin': 'http://www.linkedin.com/in/%u',
997 'myspace': 'http://www.myspace.com/%u',
998 'sinaweibo': 'http://weibo.com/n/%u'
999};
1000
1001
1002// globalDefaultAddressCountry
1003// This option sets the default country for new address fields.
1004// See common.js or use the following command to get the list of
1005// all supported country codes (defined in common.js):
1006// grep -E "'[a-z]{2}':\s+\[" common.js | sed -Ee 's#^\s+|\s+\[\s+# #g'
1007// Example:
1008var globalDefaultAddressCountry='fr';
1009
1010
1011// globalAddressCountryEquivalence
1012// This option sets the processing of the country field specified
1013// in the vCard ADR attribute.
1014// By default the address field in vCard looks like:
1015// ADR;TYPE=WORK:;;1 Waters Edge;Baytown;LA;30314;USA\r\n
1016// what cause a problem, because the country field is a plain
1017// text and can contain any value, e.g.:
1018// USA
1019// United States of America
1020// US
1021// and because the address format can be completely different for
1022// each country, e.g.:
1023// China address example:
1024// [China]
1025// [Province] [City]
1026// [Street]
1027// [Postal]
1028// Japan address example:
1029// [Postal]
1030// [Prefecture] [County/City]
1031// [Further Divisions]
1032// [Japan]
1033// the client needs to correctly detect the country from the ADR
1034// attribute. Apple solved this problem by using:
1035// item1.ADR;TYPE=WORK:;;1 Waters Edge;Baytown;LA;30314;USA\r\n
1036// item1.X-ABADR:us\r\n
1037// where the second "related" attribute defines the country code
1038// for the ADR attribute. This client uses the same approach, but
1039// if the vCard is created by 3rd party clients and the X-ABADR
1040// is missing, it is possible to define additional "rules" for
1041// country matching. These rules are specied by the country code
1042// (for full list of country codes see the comment for pre previous
1043// option) and a case insensitive regular expression (which matches
1044// the plain text value in the country field).
1045// NOTE: if X-ABADR is not present and the country not matches any
1046// country defined in this option, then globalDefaultAddressCountry
1047// is used by default.
1048// Example:
1049var globalAddressCountryEquivalence=[
1050 {country: 'de', regex: '^\\W*Deutschland\\W*$'},
1051 {country: 'sk', regex: '^\\W*Slovensko\\W*$'}
1052];
1053
1054
1055// globalAddressCountryFavorites
1056// This option defines the list of countries which are shown at the top
1057// of the country list in the interface (for full list of country codes
1058// see the comment for pre globalDefaultAddressCountry option).
1059// Example:
1060// var globalAddressCountryFavorites=['de','sk'];
1061var globalAddressCountryFavorites=[];
1062
1063
1064// globalAddrColorPropertyXmlns
1065// This options sets the namespace used for storing the "addressbook-color"
1066// property by the client.
1067// If true, undefined (or empty) "http://inf-it.com/ns/ab/" is used.
1068// If false, then the addressbook color modification functionality
1069// is completely disabled, and addressbook colors in the interface are
1070// generated automatically.
1071// Example:
1072//var globalAddrColorPropertyXmlns=true;
1073
1074
1075// globalContactStoreFN
1076// This option specifies how the FN (formatted name) is stored into vCard.
1077// The value for this options must be an array of strings, that can contain
1078// the following variables:
1079// prefix
1080// last
1081// middle
1082// first
1083// suffix
1084// The string element of the array can contain any other characters (usually
1085// space or colon). Elements are added into FN only if the there is
1086// a variable match, for example if:
1087// last='Lastname'
1088// first='Firstname'
1089// middle='' (empty)
1090// and this option is set to:
1091// ['last', ' middle', ' first'] (space in the second and third element)
1092// the resulting value for FN will be: 'Lastname Firstname' and not
1093// 'Lastname Firstname' (two spaces), because the middle name is empty (so
1094// the second element is completely ignored /not added into FN/).
1095// NOTE: this attribute is NOT used by this client, and it is also NOT
1096// possible to directly edit it in the interface.
1097// Examples:
1098// var globalContactStoreFN=[' last', ' middle', ' first'];
1099// var globalContactStoreFN=['last', ', middle', ' ,first'];
1100var globalContactStoreFN=['prefix',' last',' middle',' first',' suffix'];
1101
1102
1103// globalGroupContactsByCompanies
1104// This options specifies how contacts are grouped in the interface.
1105// By default the interface looks like (very simple example):
1106// A
1107// Adams Adam
1108// Anderson Peter
1109// B
1110// Brown John
1111// Baker Josh
1112// if grouped by company/deparment the result is:
1113// Company A [Department X]
1114// Adams Adam
1115// Brown John
1116// Company B [Department Y]
1117// Anderson Peter
1118// Baker Josh
1119// If this option is set to true contacts are grouped by company/department,
1120// otherwise (default) contacts are grouped by letters of the alphabet.
1121// If undefined or not true, grouping by alphabet letters is used.
1122// NOTE: see also the globalCollectionDisplay option below.
1123var globalGroupContactsByCompanies=false;
1124
1125
1126// globalCollectionDisplay
1127// This options specifies how data columns in the contact list are displayed.
1128//
1129// NOTE: columns are displayed ONLY if there is enought horizontal place in
1130// the browser window (e.g. if you define 5 columns here, but your browser
1131// window is not wide enough, you will see only first 3 columns instead of 5).
1132//
1133// NOTE: see the globalContactDataMinVisiblePercentage option which defines the
1134// width for columns.
1135//
1136// The value must be an array of columns, where each column is represented by
1137// an object with the following properties:
1138// label => the value of this option is a string used as column header
1139// You can use the following localized variables in the label string:
1140// - {Name}
1141// - {FirstName}
1142// - {LastName}
1143// - {MiddleName}
1144// - {NickName}
1145// - {Prefix}
1146// - {Suffix}
1147// - {BirthDay}
1148// - {PhoneticLastName}
1149// - {PhoneticFirstName}
1150// - {JobTitle}
1151// - {Company}
1152// - {Department}
1153// - {Categories}
1154// - {NoteText}
1155// - {Address}, {AddressWork}, {AddressHome}, {AddressOther}
1156// - {Phone}, {PhoneWork}, {PhoneHome}, {PhoneCell}, {PhoneMain},
1157// {PhonePager}, {PhoneFax}, {PhoneIphone}, {PhoneOther}
1158// - {Email}, {EmailWork}, {EmailHome}, {EmailMobileme}, {EmailOther}
1159// - {URL}, {URLWork}, {URLHome}, {URLHomepage}, {URLOther}
1160// - {Dates}, {DatesAnniversary}, {DatesOther}
1161// - {Related}, {RelatedManager}, {RelatedAssistant}, {RelatedFather},
1162// {RelatedMother}, {RelatedParent}, {RelatedBrother}, {RelatedSister},
1163// {RelatedChild}, {RelatedFriend}, {RelatedSpouse}, {RelatedPartner},
1164// {RelatedOther}
1165// - {Profile}, {ProfileTwitter}, {ProfileFacebook}, {ProfileFlickr},
1166// {ProfileLinkedin}, {ProfileMyspace}, {ProfileSinaweibo}
1167// - {IM}, {IMWork}, {IMHome}, {IMMobileme}, {IMOther}, {IMAim}, {IMIcq},
1168// {IMIrc}, {IMJabber}, {IMMsn}, {IMYahoo}, {IMFacebook}, {IMGadugadu},
1169// {IMGoogletalk}, {IMQq}, {IMSkype}
1170// value => the value of this option is an array of format strings, or
1171// an object with the following properties:
1172// - company (used for company contacts)
1173// - personal (used for user contacts)
1174// where the value of these properties is an array of format strings used
1175// for company or user contacts (you can have different values in the same
1176// column for personal and company contacts).
1177// You can use the following simple variables in the format string:
1178// - {FirstName}
1179// - {LastName}
1180// - {MiddleName}
1181// - {NickName}
1182// - {Prefix}
1183// - {Suffix}
1184// - {BirthDay}
1185// - {PhoneticLastName}
1186// - {PhoneticFirstName}
1187// - {JobTitle}
1188// - {Company}
1189// - {Department}
1190// - {Categories}
1191// - {NoteText}
1192// You can also use parametrized variables, where the parameter is enclosed
1193// in square bracket. Paramatrized variables are useful to extract data
1194// such as home phone {Phone[type=home]}, extract the second phone number
1195// {Phone[:1]} (zero based indexing) or extract the third home phone number
1196// {Phone[type=home][:2]} from the vCard.
1197// NOTE: if the parametrized variable matches multiple items, e.g.:
1198// {Phone[type=work]} (if the contact has multiple work phones) then the
1199// first one is used!
1200//
1201// The following parametrized variables are supported (note: you can use
1202// all of them also without parameters /the first one will be used/):
1203// - {Address[type=XXX]} or {Address[:NUM]} or {Address[type=XXX][:NUM]}
1204// where supported values for XXX are:
1205// - work
1206// - home
1207// - other
1208// - any other custom value
1209// - {Phone[type=XXX]} or {Phone[:NUM]} or {Phone[type=XXX][:NUM]}
1210// where supported values for XXX are:
1211// - work
1212// - home
1213// - cell
1214// - main
1215// - pager
1216// - fax
1217// - iphone
1218// - other
1219// - any other custom value
1220// - {Email[type=XXX]} or {Email[:NUM]} or {Email[type=XXX][:NUM]}
1221// where supported values for XXX are:
1222// - work
1223// - home
1224// - mobileme
1225// - other
1226// - any other custom value
1227// - {URL[type=XXX]} or {URL[:NUM]} or {URL[type=XXX][:NUM]}
1228// where supported values for XXX are:
1229// - work
1230// - home
1231// - homepage
1232// - other
1233// - any other custom value
1234// - {Dates[type=XXX]} or {Dates[:NUM]} or {Dates[type=XXX][:NUM]}
1235// where supported values for XXX are:
1236// - anniversary
1237// - other
1238// - any other custom value
1239// - {Related[type=XXX]} or {Related[:NUM]} or {Related[type=XXX][:NUM]}
1240// where supported values for XXX are:
1241// - manager
1242// - assistant
1243// - father
1244// - mother
1245// - parent
1246// - brother
1247// - sister
1248// - child
1249// - friend
1250// - spouse
1251// - partner
1252// - other
1253// - any other custom value
1254// - {Profile[type=XXX]} or {Profile[:NUM]} or {Profile[type=XXX][:NUM]}
1255// where supported values for XXX are:
1256// - twitter
1257// - facebook
1258// - flickr
1259// - linkedin
1260// - myspace
1261// - sinaweibo
1262// - any other custom value
1263// - {IM[type=XXX]} or {IM[service-type=YYY]} or {IM[:NUM]}
1264// where supported values for XXX are:
1265// - work
1266// - home
1267// - mobileme
1268// - other
1269// - any other custom value
1270// and supported values for YYY are:
1271// - aim
1272// - icq
1273// - irc
1274// - jabber
1275// - msn
1276// - yahoo
1277// - facebook
1278// - gadugadu
1279// - googletalk
1280// - qq
1281// - skype
1282// - any other custom value
1283//
1284// NOTE: if you want to use the "any other custom value" option (for XXX
1285// or YYY above) you MUST double escape the following characters:
1286// =[]{}\
1287// for example:
1288// - for profile type "=XXX=" use: '{Profile[type=\\=XXX\\=]}'
1289// - for profile type "\XXX\" use: '{Profile[type=\\\\XXX\\\\]}'
1290//
1291// NOTE: if you want to use curly brackets in the format string you must
1292// double escape it, e.g.: ['{Company}', '\\{{Department}\\}']
1293//
1294// The format string (for the value option) is an array to allow full
1295// customization of the interface. For example if:
1296// value: ['{LastName} {MiddleName} {FirstName}']
1297// and the person has no middle name, then the result in the column
1298// will be (without quotes):
1299// "Parker Peter" (note: two space characters)
1300// but if you use:
1301// value: ['{LastName}', ' {MiddleName}', ' {FirstName}']
1302// then the result will be (without quotes):
1303// "Parker Peter" (note: only one space character)
1304// The reason is that only those elements of the array are appended
1305// into the result where non-empty substitution was performed (so the
1306// ' {MiddleName}' element in this case is ignored, because the person
1307// in the example above has no /more precisely has empty/ middle name).
1308//
1309// Examples:
1310// To specify two columns (named "Company" and "Department / LastName"),
1311// where the first will display the company name, and the second will display
1312// department for company contacts (with "Dep -" prefix), and lastname for
1313// personal contacts (with "Name -" prefix) use:
1314// var globalCollectionDisplay=[
1315// {
1316// label: 'Company',
1317// value: ['{Company}']
1318// },
1319// {
1320// label: 'Department / LastName',
1321// value: {
1322// company: ['Dep - {Department}'],
1323// personal: ['Name - {LastName}']
1324// }
1325// }
1326// ];
1327// To specify 3 columns (named "Categories", "URL" and "IM"), where the first
1328// will display categories, second will display the third work URL, and third
1329// will display ICQ IM use:
1330// var globalCollectionDisplay=[
1331// {
1332// label: 'Categories',
1333// value: ['{Categories}']
1334// },
1335// {
1336// label: 'URL',
1337// value: ['{URL[type=WORK][:2]}']
1338// },
1339// {
1340// label: 'IM',
1341// value: ['{IM[service-type=ICQ]}']
1342// }
1343// ];
1344//
1345// Recommended settings if globalGroupContactsByCompanies
1346// is set to false:
1347// var globalCollectionDisplay=[
1348// {
1349// label: '{Name}',
1350// value: ['{LastName}', ' {MiddleName}', ' {FirstName}']
1351// },
1352// {
1353// label: '{Company} [{Department}]',
1354// value: ['{Company}', ' [{Department}]']
1355// },
1356// {
1357// label: '{JobTitle}',
1358// value: ['{JobTitle}']
1359// },
1360// {
1361// label: '{Email}',
1362// value: ['{Email[:0]}']
1363// },
1364// {
1365// label: '{Phone} 1',
1366// value: ['{Phone[:0]}']
1367// },
1368// {
1369// label: '{Phone} 2',
1370// value: ['{Phone[:1]}']
1371// },
1372// {
1373// label: '{NoteText}',
1374// value: ['{NoteText}']
1375// }
1376// ];
1377//
1378// Recommended settings if globalGroupContactsByCompanies
1379// is set to true:
1380// var globalCollectionDisplay=[
1381// {
1382// label: '{Name}',
1383// value: {
1384// personal: ['{LastName}', ' {MiddleName}', ' {FirstName}'],
1385// company: ['{Company}', ' [{Department}]']
1386// }
1387// },
1388// {
1389// label: '{JobTitle}',
1390// value: ['{JobTitle}']
1391// },
1392// {
1393// label: '{Email}',
1394// value: ['{Email[:0]}']
1395// },
1396// {
1397// label: '{Phone} 1',
1398// value: ['{Phone[:0]}']
1399// },
1400// {
1401// label: '{Phone} 2',
1402// value: ['{Phone[:1]}']
1403// },
1404// {
1405// label: '{NoteText}',
1406// value: ['{NoteText}']
1407// }
1408// ];
1409//
1410// NOTE: if left undefined, the recommended settings will be used.
1411
1412
1413// globalCollectionSort
1414// This options sets the ordering of contacts in the interface. In general
1415// contacts are ordered alphabetically by an internal "sort string" which
1416// is created for each contact. Here you can specify how this internal string
1417// is created. The value is a simple array holding only the values from the
1418// value property defined in the globalCollectionDisplay option.
1419// If undefined, the definition from globalCollectionDisplay is used.
1420// Example:
1421// var globalCollectionSort = [
1422// ['{LastName}'],
1423// ['{FirstName}'],
1424// ['{MiddleName}'],
1425// {
1426// company: ['{Categories}'],
1427// personal: ['{Company}']
1428// }
1429// ];
1430var globalCollectionSort=[
1431 ['{LastName}'],
1432 ['{FirstName}'],
1433 ['{MiddleName}']
1434];
1435
1436
1437// globalContactDataMinVisiblePercentage
1438// This option defines how the width for columns are computed. If you set
1439// it to 1 then 100% of all data in the column will be visible (the column
1440// width is determined by the longest string in the column). If you set it
1441// to 0.95 then 95% of data will fit into the column width, and the remaining
1442// 5% will be truncated (" ...").
1443// Example:
1444var globalContactDataMinVisiblePercentage=0.95;
1445
1446
diff --git a/flakes/mypackages/pkgs/webapps/mantisbt_2/bug_report.php.diff b/flakes/mypackages/pkgs/webapps/mantisbt_2/bug_report.php.diff
new file mode 100644
index 0000000..2924252
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/mantisbt_2/bug_report.php.diff
@@ -0,0 +1,20 @@
1--- a/bug_report.php 2019-05-06 12:06:44.265508011 +0200
2+++ b/bug_report.php 2019-05-06 12:09:40.106952738 +0200
3@@ -67,6 +67,17 @@
4 'copy_files' => $f_copy_attachments_from_parent
5 );
6
7+# begin captcha check for anon user
8+if ( current_user_is_anonymous() && get_gd_version() > 0 ) {
9+ $f_captcha = gpc_get_string( 'captcha', '' );
10+ $f_captcha = utf8_strtolower( trim( $f_captcha ) );
11+
12+ $t_securimage = new Securimage();
13+ if( $t_securimage->check( $f_captcha ) == false ) {
14+ trigger_error( ERROR_SIGNUP_NOT_MATCHING_CAPTCHA, ERROR );
15+ }
16+}
17+
18 if( $f_master_bug_id > 0 ) {
19 bug_ensure_exists( $f_master_bug_id );
20
diff --git a/flakes/mypackages/pkgs/webapps/mantisbt_2/bug_report_page.php.diff b/flakes/mypackages/pkgs/webapps/mantisbt_2/bug_report_page.php.diff
new file mode 100644
index 0000000..80dea91
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/mantisbt_2/bug_report_page.php.diff
@@ -0,0 +1,53 @@
1--- a/bug_report_page.php 2018-02-10 21:29:27.000000000 +0100
2+++ b/bug_report_page.php 2018-03-03 15:04:19.622499678 +0100
3@@ -708,7 +708,50 @@
4 <span class="lbl padding-6"><?php echo lang_get( 'check_report_more_bugs' ) ?></span>
5 </label>
6 </td>
7 </tr>
8+<?php
9+ # captcha image requires GD library and related option to ON
10+ if( current_user_is_anonymous() && get_gd_version() > 0 ) {
11+ $t_securimage_path = 'vendor/dapphp/securimage';
12+ $t_securimage_show = $t_securimage_path . '/securimage_show.php';
13+ $t_securimage_play = $t_securimage_path . '/securimage_play.swf?'
14+ . http_build_query( array(
15+ 'audio_file' => $t_securimage_path . '/securimage_play.php',
16+ 'bgColor1=' => '#fff',
17+ 'bgColor2=' => '#fff',
18+ 'iconColor=' => '#777',
19+ 'borderWidth=' => 1,
20+ 'borderColor=' => '#000',
21+ ) );
22+?>
23+ <tr>
24+ <th class="category">CAPTCHA</th>
25+ <td>
26+
27+ <label for="captcha-field" class="block clearfix">
28+ <strong><?php echo lang_get( 'signup_captcha_request_label' ); ?></strong>
29+ </label>
30+ <span id="captcha-input" class="input">
31+ <?php print_captcha_input( 'captcha' ); ?>
32+
33+ <span id="captcha-image" class="captcha-image" style="padding-right:3px;">
34+ <img src="<?php echo $t_securimage_show; ?>" alt="visual captcha" />
35+ <ul id="captcha-refresh"><li><a href="#"><?php
36+ echo lang_get( 'signup_captcha_refresh' );
37+ ?></a></li></ul>
38+ </span>
39+
40+ <object type="application/x-shockwave-flash" width="19" height="19"
41+ data="<?php echo $t_securimage_play; ?>">
42+ <param name="movie" value="<?php echo $t_securimage_play; ?>" />
43+ </object>
44+ </span>
45+ </td>
46+ </tr>
47+<?php
48+ }
49+?>
50+
51 </table>
52 </div>
53 </div>
diff --git a/flakes/mypackages/pkgs/webapps/mantisbt_2/bugnote_add.php.diff b/flakes/mypackages/pkgs/webapps/mantisbt_2/bugnote_add.php.diff
new file mode 100644
index 0000000..4509f0a
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/mantisbt_2/bugnote_add.php.diff
@@ -0,0 +1,20 @@
1--- a/bugnote_add.php 2018-02-10 21:29:27.000000000 +0100
2+++ b/bugnote_add.php 2018-03-03 15:13:12.439919511 +0100
3@@ -44,6 +44,17 @@
4
5 $t_query = array( 'issue_id' => $f_bug_id );
6
7+# begin captcha check for anon user
8+if ( current_user_is_anonymous() && get_gd_version() > 0 ) {
9+ $f_captcha = gpc_get_string( 'captcha', '' );
10+ $f_captcha = utf8_strtolower( trim( $f_captcha ) );
11+
12+ $t_securimage = new Securimage();
13+ if( $t_securimage->check( $f_captcha ) == false ) {
14+ trigger_error( ERROR_SIGNUP_NOT_MATCHING_CAPTCHA, ERROR );
15+ }
16+}
17+
18 if( count( $f_files ) > 0 && is_blank( $f_text ) && helper_duration_to_minutes( $f_duration ) == 0 ) {
19 $t_payload = array(
20 'files' => helper_array_transpose( $f_files )
diff --git a/flakes/mypackages/pkgs/webapps/mantisbt_2/bugnote_add_inc.php.diff b/flakes/mypackages/pkgs/webapps/mantisbt_2/bugnote_add_inc.php.diff
new file mode 100644
index 0000000..a8589c7
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/mantisbt_2/bugnote_add_inc.php.diff
@@ -0,0 +1,52 @@
1--- a/bugnote_add_inc.php 2018-02-10 21:29:27.000000000 +0100
2+++ b/bugnote_add_inc.php 2018-03-03 15:14:27.332428557 +0100
3@@ -119,6 +119,49 @@
4 <textarea name="bugnote_text" id="bugnote_text" class="<?php echo $t_bugnote_class ?>" rows="7"></textarea>
5 </td>
6 </tr>
7+<?php
8+ # captcha image requires GD library and related option to ON
9+ if( current_user_is_anonymous() && get_gd_version() > 0 ) {
10+ $t_securimage_path = 'vendor/dapphp/securimage';
11+ $t_securimage_show = $t_securimage_path . '/securimage_show.php';
12+ $t_securimage_play = $t_securimage_path . '/securimage_play.swf?'
13+ . http_build_query( array(
14+ 'audio_file' => $t_securimage_path . '/securimage_play.php',
15+ 'bgColor1=' => '#fff',
16+ 'bgColor2=' => '#fff',
17+ 'iconColor=' => '#777',
18+ 'borderWidth=' => 1,
19+ 'borderColor=' => '#000',
20+ ) );
21+?>
22+ <tr>
23+ <th class="category">CAPTCHA</th>
24+ <td>
25+
26+ <label for="captcha-field" class="block clearfix">
27+ <strong><?php echo lang_get( 'signup_captcha_request_label' ); ?></strong>
28+ </label>
29+ <span id="captcha-input" class="input">
30+ <?php print_captcha_input( 'captcha' ); ?>
31+
32+ <span id="captcha-image" class="captcha-image" style="padding-right:3px;">
33+ <img src="<?php echo $t_securimage_show; ?>" alt="visual captcha" />
34+ <ul id="captcha-refresh"><li><a href="#"><?php
35+ echo lang_get( 'signup_captcha_refresh' );
36+ ?></a></li></ul>
37+ </span>
38+
39+ <object type="application/x-shockwave-flash" width="19" height="19"
40+ data="<?php echo $t_securimage_play; ?>">
41+ <param name="movie" value="<?php echo $t_securimage_play; ?>" />
42+ </object>
43+ </span>
44+ </td>
45+ </tr>
46+<?php
47+ }
48+?>
49+
50
51 <?php
52 if( config_get( 'time_tracking_enabled' ) ) {
diff --git a/flakes/mypackages/pkgs/webapps/mantisbt_2/default.nix b/flakes/mypackages/pkgs/webapps/mantisbt_2/default.nix
new file mode 100644
index 0000000..466595d
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/mantisbt_2/default.nix
@@ -0,0 +1,44 @@
1{ mantis_config ? "/etc/mantisbt/config_inc.php", stdenv, fetchurl, lib, callPackage}:
2let
3 pluginNames = [ "slack" "source-integration" ];
4 allPlugins = lib.attrsets.genAttrs pluginNames
5 (name: callPackage (./plugins + "/${name}") {});
6 toPassthru = pkg: plugins: {
7 inherit plugins allPlugins;
8 pluginNames = map (n: n.pluginName) plugins;
9 withPlugins = withPlugins pkg;
10 };
11 withPlugins = pkg: toPlugins:
12 let
13 plugins = toPlugins allPlugins;
14 toInstallPlugin = n:
15 if builtins.hasAttr "selector" n then
16 "ln -sf ${n}/${n.selector} $out/plugins/"
17 else
18 "ln -sf ${n} $out/plugins/${n.pluginName}";
19 newMantisbt = pkg.overrideAttrs(old: {
20 installPhase = old.installPhase + "\n" + builtins.concatStringsSep "\n" (map toInstallPlugin plugins);
21 passthru = toPassthru newMantisbt (pkg.plugins ++ plugins);
22 });
23 in newMantisbt;
24 package = stdenv.mkDerivation rec {
25 name = "mantisbt-${version}";
26 version = "2.21.0";
27 src = fetchurl {
28 url = "https://downloads.sourceforge.net/project/mantisbt/mantis-stable/${version}/${name}.tar.gz";
29 sha256 = "13lx569dp1gibq5daqp7dj6gsqic85rrix1s7xkp60gwpzk8wiw5";
30 };
31 patches = [
32 ./bug_report.php.diff
33 ./bug_report_page.php.diff
34 ./bugnote_add.php.diff
35 ./bugnote_add_inc.php.diff
36 ];
37 installPhase = ''
38 cp -a . $out
39 ln -s ${mantis_config} $out/config/config_inc.php
40 '';
41
42 passthru = toPassthru package [];
43 };
44in package
diff --git a/flakes/mypackages/pkgs/webapps/mantisbt_2/plugins/slack/default.nix b/flakes/mypackages/pkgs/webapps/mantisbt_2/plugins/slack/default.nix
new file mode 100644
index 0000000..61ed15f
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/mantisbt_2/plugins/slack/default.nix
@@ -0,0 +1,18 @@
1{ stdenv, fetchFromGitHub }:
2stdenv.mkDerivation rec {
3 passthru = {
4 pluginName = "Slack";
5 };
6 version = "9286d2e-master";
7 name = "mantisbt-plugin-slack-${version}";
8 src = fetchFromGitHub {
9 owner = "mantisbt-plugins";
10 repo = "Slack";
11 rev = "9286d2eeeb8a986ed949e378711fef5f0bf182dc";
12 sha256 = "0nn0v4jc967giilkzrppi5svd04m2hnals75xxp0iabcdjnih0mn";
13 };
14 installPhase = ''
15 sed -i -e "s/return '@' . \\\$username;/return \\\$username;/" Slack.php
16 cp -a . $out
17 '';
18}
diff --git a/flakes/mypackages/pkgs/webapps/mantisbt_2/plugins/source-integration/Source.API.php.diff b/flakes/mypackages/pkgs/webapps/mantisbt_2/plugins/source-integration/Source.API.php.diff
new file mode 100644
index 0000000..c355144
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/mantisbt_2/plugins/source-integration/Source.API.php.diff
@@ -0,0 +1,12 @@
1--- b/Source/Source.API.php 2017-09-18 00:50:32.000000000 +0200
2+++ a/Source/Source.API.php 2018-03-04 19:00:25.578889039 +0100
3@@ -452,6 +452,9 @@
4 # Allow other plugins to post-process commit data
5 event_signal( 'EVENT_SOURCE_COMMITS', array( $p_changesets ) );
6 event_signal( 'EVENT_SOURCE_FIXED', array( $t_fixed_bugs ) );
7+ foreach( $t_fixed_bugs as $t_bug_id => $t_changeset ) {
8+ event_signal( 'EVENT_BUG_ACTION', array('RESOLVE', $t_bug_id) );
9+ }
10 }
11
12 /**
diff --git a/flakes/mypackages/pkgs/webapps/mantisbt_2/plugins/source-integration/default.nix b/flakes/mypackages/pkgs/webapps/mantisbt_2/plugins/source-integration/default.nix
new file mode 100644
index 0000000..1ab00c5
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/mantisbt_2/plugins/source-integration/default.nix
@@ -0,0 +1,22 @@
1{ stdenv, fetchFromGitHub }:
2stdenv.mkDerivation rec {
3 version = "v2.2.0";
4 name = "mantisbt-plugin-source-integration-${version}";
5 src = fetchFromGitHub {
6 owner = "mantisbt-plugins";
7 repo = "source-integration";
8 rev = "44fc9e2e770aff4f40f56833f26a86ce0e2deb76";
9 sha256 = "0gcm6kqqijnv303sk59zn27adwx5vkr545mwzyaq2nrpxnkwdy5b";
10 };
11 patches = [
12 ./Source.API.php.diff
13 ];
14 installPhase = ''
15 mkdir $out
16 cp -a Source* $out/
17 '';
18 passthru = {
19 pluginName = "source-integration";
20 selector = "Source*";
21 };
22}
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/audioplayer.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/audioplayer.nix
new file mode 100644
index 0000000..6e7380c
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/audioplayer.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 audioplayer_3_4_0 = buildApp rec {
4 appName = "audioplayer";
5 version = "3.4.0";
6 url = "https://github.com/Rello/${appName}/releases/download/${version}/${appName}-${version}.tar.gz";
7 sha256 = "sha256-pog9cll02+AbYHG/jiUztO9odqu7PSEWBUieK32Eqf4=";
8 };
9 versions = {
10 "25" = audioplayer_3_4_0;
11 "26" = audioplayer_3_4_0;
12 "27" = audioplayer_3_4_0;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app audioplayer")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/bookmarks.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/bookmarks.nix
new file mode 100644
index 0000000..0503e5b
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/bookmarks.nix
@@ -0,0 +1,21 @@
1{ buildApp, nextcloudVersion }:
2let
3 bookmarks_12_1_0 = buildApp rec {
4 appName = "bookmarks";
5 version = "12.1.0";
6 url = "https://github.com/nextcloud/${appName}/releases/download/v${version}/${appName}-${version}.tar.gz";
7 sha256 = "sha256-NVyaVeg/UPgFaW/iCZiJkw1l5Vqc+S/4FMfFhHCBUTo=";
8 };
9 bookmarks_13_0_1 = buildApp rec {
10 appName = "bookmarks";
11 version = "13.0.1";
12 url = "https://github.com/nextcloud/${appName}/releases/download/v${version}/${appName}-${version}.tar.gz";
13 sha256 = "sha256-7Gx8e8C2dDkB/39eAGKOLrP3YkVbGkfPKpQBeCaV/cE=";
14 };
15 versions = {
16 "25" = bookmarks_12_1_0;
17 "26" = bookmarks_13_0_1;
18 "27" = bookmarks_13_0_1;
19 };
20in
21 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app bookmarks")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/calendar.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/calendar.nix
new file mode 100644
index 0000000..497d4ba
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/calendar.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 calendar_4_4_4 = buildApp rec {
4 appName = "calendar";
5 version = "4.4.4";
6 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
7 sha256 = "sha256-8UeHOpgbUf2oHHOvLN58v68QvyDYQXkSjsVKn6UGrGU=";
8 };
9 versions = {
10 "25" = calendar_4_4_4;
11 "26" = calendar_4_4_4;
12 "27" = calendar_4_4_4;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app calendar")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/carnet.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/carnet.nix
new file mode 100644
index 0000000..05f0928
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/carnet.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 carnet_0_25_2 = buildApp rec {
4 appName = "carnet";
5 version = "0.25.2";
6 url = "https://github.com/PhieF/CarnetNextcloud/releases/download/v${version}/${appName}-nc-v${version}.tar.gz";
7 sha256 = "sha256-HArD+M6UA9BhSsrlpp/gsKWkUTWAoNHl/gr0S3AlKzg=";
8 };
9 versions = {
10 "25" = carnet_0_25_2;
11 "26" = carnet_0_25_2;
12 "27" = carnet_0_25_2;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app carnet")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/contacts.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/contacts.nix
new file mode 100644
index 0000000..f8931b7
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/contacts.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 contacts_5_3_2 = buildApp rec {
4 appName = "contacts";
5 version = "5.3.2";
6 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
7 sha256 = "sha256-1jQ+pyLBPU7I4wSPkmezJq7ukrQh8WPErG4J6Ps3LR4=";
8 };
9 versions = {
10 "25" = contacts_5_3_2;
11 "26" = contacts_5_3_2;
12 "27" = contacts_5_3_2;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app contacts")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/cookbook.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/cookbook.nix
new file mode 100644
index 0000000..32fdcc0
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/cookbook.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 cookbook_0_10_2 = buildApp rec {
4 appName = "cookbook";
5 version = "0.10.2";
6 url = "https://github.com/nextcloud/${appName}/releases/download/v${version}/Cookbook-${version}.tar.gz";
7 sha256 = "sha256-H7KVeISBnu0/4Q31ihhiXvRtkXz4yLGOAsAj5ERgeCM=";
8 };
9 versions = {
10 "25" = cookbook_0_10_2;
11 "26" = cookbook_0_10_2;
12 "27" = cookbook_0_10_2;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app cookbook")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/deck.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/deck.nix
new file mode 100644
index 0000000..c5dd2d3
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/deck.nix
@@ -0,0 +1,27 @@
1{ buildApp, nextcloudVersion }:
2let
3 deck_1_8_5 = buildApp rec {
4 appName = "deck";
5 version = "1.8.5";
6 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
7 sha256 = "sha256-KsSSl9orqMEKJlBftHwCi/dh+aMCxZqjS7kPT0uDZlE=";
8 };
9 deck_1_9_2 = buildApp rec {
10 appName = "deck";
11 version = "1.9.2";
12 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
13 sha256 = "sha256-h1fmT4CCEFDZPBwFDIBLmFGJmO1Wt3a5nVXX5xCk0o0=";
14 };
15 deck_1_10_0 = buildApp rec {
16 appName = "deck";
17 version = "1.10.0";
18 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
19 sha256 = "sha256-W0XVvhTQoCjoK7S2tEd7bvU0MTWtqYt7QiB9H1p1UP8=";
20 };
21 versions = {
22 "25" = deck_1_8_5;
23 "26" = deck_1_9_2;
24 "27" = deck_1_10_0;
25 };
26in
27 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app deck")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/drawio.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/drawio.nix
new file mode 100644
index 0000000..c03c479
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/drawio.nix
@@ -0,0 +1,24 @@
1{ buildApp, nextcloudVersion }:
2let
3 otherConfig = {
4 mimetypealiases = {
5 "application/x-drawio" = "drawio";
6 };
7 mimetypemapping = {
8 "drawio" = ["application/x-drawio"];
9 };
10 };
11 drawio_2_1_2 = buildApp rec {
12 appName = "drawio";
13 version = "2.1.2";
14 url = "https://github.com/jgraph/drawio-nextcloud/releases/download/v${version}/${appName}-v${version}.tar.gz";
15 sha256 = "sha256-5BrEnS2cMk/vwkAr1lXKtfocqReZAj1+pbDqmi/uG0A=";
16 inherit otherConfig;
17 };
18 versions = {
19 "25" = drawio_2_1_2;
20 "26" = drawio_2_1_2;
21 "27" = drawio_2_1_2;
22 };
23in
24 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app drawio")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/external.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/external.nix
new file mode 100644
index 0000000..941304a
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/external.nix
@@ -0,0 +1,27 @@
1{ buildApp, nextcloudVersion }:
2let
3 external_5_0_2 = buildApp rec {
4 appName = "external";
5 version = "5.0.2";
6 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
7 sha256 = "sha256-Bkk9X1tVonKsiA3YlKux2y8K7HdJv4qM/eJ9TP+i17I=";
8 };
9 external_5_1_0 = buildApp rec {
10 appName = "external";
11 version = "5.1.0";
12 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
13 sha256 = "sha256-EMKWSXufw4FMyaN2f37yifrpUm6QBqqpPPFmvLvYYmY=";
14 };
15 external_5_2_0 = buildApp rec {
16 appName = "external";
17 version = "5.2.0";
18 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
19 sha256 = "sha256-XqeJCWS8mncS7CfrnXdhtzdgkFTib/RnursJ/AqyvD8=";
20 };
21 versions = {
22 "25" = external_5_0_2;
23 "26" = external_5_1_0;
24 "27" = external_5_2_0;
25 };
26in
27 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app external")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/extract.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/extract.nix
new file mode 100644
index 0000000..589115e
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/extract.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 extract_1_3_6 = buildApp rec {
4 appName = "extract";
5 version = "1.3.6";
6 url = "https://github.com/PaulLereverend/NextcloudExtract/releases/download/${version}/${appName}.tar.gz";
7 sha256 = "sha256-y1NacOWnCd/f5sOeEOLeZrWnqwi8q/XezOrhT7AzV/o=";
8 };
9 versions = {
10 "25" = extract_1_3_6;
11 "26" = extract_1_3_6;
12 "27" = extract_1_3_6;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app extract")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/files_markdown.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/files_markdown.nix
new file mode 100644
index 0000000..cf8e179
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/files_markdown.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 files_markdown_2_4_1 = buildApp rec {
4 appName = "files_markdown";
5 version = "2.4.1";
6 url = "https://github.com/icewind1991/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
7 sha256 = "sha256-6A9IMfRbKcF1+et7pzFF4zlZDmegx562cnyYsOFsVzU=";
8 };
9 versions = {
10 "25" = files_markdown_2_4_1;
11 "26" = files_markdown_2_4_1;
12 "27" = files_markdown_2_4_1;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app files_markdown")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/files_mindmap.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/files_mindmap.nix
new file mode 100644
index 0000000..fff85d7
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/files_mindmap.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 files_mindmap_0_0_28 = buildApp rec {
4 appName = "files_mindmap";
5 version = "0.0.28";
6 url = "https://github.com/ACTom/${appName}/releases/download/v${version}/${appName}-${version}.tar.gz";
7 sha256 = "sha256-VlzqstlsdinaqkbK32NvS1oFoQcFasJGHSlcKxdQwIM=";
8 };
9 versions = {
10 "25" = files_mindmap_0_0_28;
11 "26" = files_mindmap_0_0_28;
12 "27" = files_mindmap_0_0_28;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app files_mindmap")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/files_readmemd.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/files_readmemd.nix
new file mode 100644
index 0000000..97aeaf7
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/files_readmemd.nix
@@ -0,0 +1,14 @@
1{ buildApp, nextcloudVersion }:
2let
3 files_readmemd_2_0_0 = buildApp rec {
4 appName = "files_readmemd";
5 version = "2.0.0";
6 url = "https://github.com/mamatt/files_readmemd/releases/download/V${version}/${appName}.tar.gz";
7 sha256 = "sha256-vUoSK+b4gj51eJcocrXINO/eFKPRZQoj0q6l0gVBqgw=";
8 };
9 versions = {
10 "25" = files_readmemd_2_0_0;
11 "26" = files_readmemd_2_0_0;
12 };
13in
14 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app files_readmemd")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/flowupload.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/flowupload.nix
new file mode 100644
index 0000000..55f4ba7
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/flowupload.nix
@@ -0,0 +1,14 @@
1{ buildApp, nextcloudVersion }:
2let
3 flowupload_1_1_3 = buildApp rec {
4 appName = "flowupload";
5 version = "1.1.3";
6 url = "https://github.com/e-alfred/${appName}/releases/download/${version}/${appName}-${version}.tar.gz";
7 sha256 = "0d1xvimd4hzd0jpvv1h89zfqv3ajlrrm1xdbggvjhk9bllwqgxng";
8 };
9 versions = {
10 "22" = flowupload_1_1_3;
11 "23" = flowupload_1_1_3;
12 };
13in
14 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app flowupload")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/gpxedit.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/gpxedit.nix
new file mode 100644
index 0000000..be230fd
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/gpxedit.nix
@@ -0,0 +1,22 @@
1{ buildApp, nextcloudVersion }:
2let
3 gpxedit_0_0_14 = buildApp rec {
4 appName = "gpxedit";
5 version = "0.0.14";
6 url = "https://gitlab.com/eneiluj/gpxedit-oc/wikis/uploads/5b184c24f9e767ad19a84e177a9b473c/${appName}-${version}.tar.gz";
7 sha256 = "1kgpcxps73l83krrjxdzh4vzacja4m3vwidf9kidgqq505cgzq90";
8 otherConfig = {
9 mimetypealiases = {
10 "application/gpx+xml" = "gpx";
11 };
12 mimetypemapping = {
13 "gpx" = ["application/gpx+xml"];
14 };
15 };
16 };
17 versions = {
18 "22" = gpxedit_0_0_14;
19 "23" = gpxedit_0_0_14;
20 };
21in
22 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app gpxedit")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/gpxpod.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/gpxpod.nix
new file mode 100644
index 0000000..5a3b7e7
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/gpxpod.nix
@@ -0,0 +1,31 @@
1{ buildApp, nextcloudVersion }:
2let
3 otherConfig = {
4 mimetypealiases = {
5 "application/gpx+xml" = "gpx";
6 };
7 mimetypemapping = {
8 "gpx" = ["application/gpx+xml"];
9 };
10 };
11 gpxpod_5_0_10 = buildApp rec {
12 appName = "gpxpod";
13 version = "5.0.10";
14 url = "https://github.com/julien-nc/gpxpod/releases/download/v${version}/${appName}-${version}.tar.gz";
15 sha256 = "sha256-Ylhl9jdOxG+Qfk5zgNO8FwOtAzrjGHS66y59qmorXPU=";
16 inherit otherConfig;
17 };
18 gpxpod_5_0_12 = buildApp rec {
19 appName = "gpxpod";
20 version = "5.0.12";
21 url = "https://github.com/julien-nc/gpxpod/releases/download/v${version}/${appName}-${version}.tar.gz";
22 sha256 = "sha256-uhz6AC8opDQkFQDpG4u8H4vkFtzbFAZvb8r32QHj/8I=";
23 inherit otherConfig;
24 };
25 versions = {
26 "25" = gpxpod_5_0_10;
27 "26" = gpxpod_5_0_12;
28 "27" = gpxpod_5_0_12;
29 };
30in
31 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app gpxpod")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/groupfolders.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/groupfolders.nix
new file mode 100644
index 0000000..b966d3d
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/groupfolders.nix
@@ -0,0 +1,27 @@
1{ buildApp, nextcloudVersion }:
2let
3 groupfolders_13_1_5 = buildApp rec {
4 appName = "groupfolders";
5 version = "13.1.5";
6 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
7 sha256 = "sha256-1yf/uSN8TRsYvK3m2pxGaXo9xxHNrI/NjyWJ8rLPQfg=";
8 };
9 groupfolders_14_0_4 = buildApp rec {
10 appName = "groupfolders";
11 version = "14.0.4";
12 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
13 sha256 = "sha256-QzlD8dLI6T7Sex75ZsO2F40nTrg2Ig6tHTG8cslnNME=";
14 };
15 groupfolders_15_0_2 = buildApp rec {
16 appName = "groupfolders";
17 version = "15.0.2";
18 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
19 sha256 = "sha256-NsTZhmY1XBKHn/1IcIp2Al7BwJzE2xoBzgyBXnmuWls=";
20 };
21 versions = {
22 "25" = groupfolders_13_1_5;
23 "26" = groupfolders_14_0_4;
24 "27" = groupfolders_15_0_2;
25 };
26in
27 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app groupfolders")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/impersonate.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/impersonate.nix
new file mode 100644
index 0000000..afae917
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/impersonate.nix
@@ -0,0 +1,27 @@
1{ buildApp, nextcloudVersion }:
2let
3 impersonate_1_12_1 = buildApp rec {
4 appName = "impersonate";
5 version = "1.12.1";
6 url = "https://github.com/nextcloud-releases/impersonate/releases/download/v${version}/${appName}-v${version}.tar.gz";
7 sha256 = "sha256-xhlWGbLm1CtW4BSa/yQhv05Kn2r1DZJDUoDXQOLpEeQ=";
8 };
9 impersonate_1_13_1 = buildApp rec {
10 appName = "impersonate";
11 version = "1.13.1";
12 url = "https://github.com/nextcloud-releases/impersonate/releases/download/v${version}/${appName}-v${version}.tar.gz";
13 sha256 = "sha256-+tFWW5wQnbHxbgGdnp2GAFzfXnrW+e3eECY4O6ZckCU=";
14 };
15 impersonate_1_14_0 = buildApp rec {
16 appName = "impersonate";
17 version = "1.14.0";
18 url = "https://github.com/nextcloud-releases/impersonate/releases/download/v${version}/${appName}-v${version}.tar.gz";
19 sha256 = "sha256-A1rGJJLaWhiNf9l0YUh6WOB+fKRBRDckE890hq5OB4k=";
20 };
21 versions = {
22 "25" = impersonate_1_12_1;
23 "26" = impersonate_1_13_1;
24 "27" = impersonate_1_14_0;
25 };
26in
27 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app impersonate")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/integration_dropbox.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/integration_dropbox.nix
new file mode 100644
index 0000000..d3834ad
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/integration_dropbox.nix
@@ -0,0 +1,13 @@
1{ buildApp, nextcloudVersion }:
2let
3 integration_dropbox_2_0_1 = buildApp rec {
4 appName = "integration_dropbox";
5 version = "2.0.1";
6 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
7 sha256 = "sha256-RPCd8+/yKNlIGfEU+ITS8DBIxJDfc//8MGHaIjfYxdQ=";
8 };
9 versions = {
10 "27" = integration_dropbox_2_0_1;
11 };
12in
13 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app integration_dropbox")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/keeweb.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/keeweb.nix
new file mode 100644
index 0000000..7be8c6b
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/keeweb.nix
@@ -0,0 +1,24 @@
1{ buildApp, nextcloudVersion }:
2let
3 keeweb_0_6_13 = buildApp rec {
4 appName = "keeweb";
5 version = "0.6.13";
6 url = "https://github.com/jhass/nextcloud-keeweb/releases/download/v${version}/${appName}-${version}.tar.gz";
7 sha256 = "sha256-J9jFVXpmoeAjDI/crsXHVJvPvxCYaimWVuq473nLsNM=";
8 installPhase = ''
9 mkdir -p $out
10 cp -R . $out/
11 '';
12 otherConfig = {
13 mimetypemapping = {
14 "kdbx" = ["application/x-kdbx"];
15 };
16 };
17 };
18 versions = {
19 "25" = keeweb_0_6_13;
20 "26" = keeweb_0_6_13;
21 "27" = keeweb_0_6_13;
22 };
23in
24 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app keeweb")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/maps.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/maps.nix
new file mode 100644
index 0000000..1b29173
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/maps.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 maps_1_1_0 = buildApp rec {
4 appName = "maps";
5 version = "1.1.0";
6 url = "https://github.com/nextcloud/maps/releases/download/v${version}/${appName}-${version}.tar.gz";
7 sha256 = "sha256-Me/V+9wXZyq3UEVx9Nqim6pfPFJaALjKv9f7iUjill8=";
8 };
9 versions = {
10 "25" = maps_1_1_0;
11 "26" = maps_1_1_0;
12 "27" = maps_1_1_0;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app maps")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/metadata.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/metadata.nix
new file mode 100644
index 0000000..0fe7409
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/metadata.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 metadata_0_19_0 = buildApp rec {
4 appName = "metadata";
5 version = "0.19.0";
6 url = "https://github.com/gino0631/nextcloud-metadata/releases/download/v${version}/${appName}.tar.gz";
7 sha256 = "sha256-XfFxCwRFO0WnBPU4CIejNXySRQdguvzauu62bzUKD44=";
8 };
9 versions = {
10 "25" = metadata_0_19_0;
11 "26" = metadata_0_19_0;
12 "27" = metadata_0_19_0;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app metadata")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/music.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/music.nix
new file mode 100644
index 0000000..fc96224
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/music.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 music_1_8_4 = buildApp rec {
4 appName = "music";
5 version = "1.8.4";
6 url = "https://github.com/owncloud/music/releases/download/v${version}/${appName}_${version}_for_nextcloud.tar.gz";
7 sha256 = "sha256-WWXMpOyTRxykAVeUj/h6QP5ENqaMvTcPIqPQjhY68KA=";
8 };
9 versions = {
10 "25" = music_1_8_4;
11 "26" = music_1_8_4;
12 "27" = music_1_8_4;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app music")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/notes.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/notes.nix
new file mode 100644
index 0000000..7677c6c
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/notes.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 notes_4_8_1 = buildApp rec {
4 appName = "notes";
5 version = "4.8.1";
6 url = "https://github.com/nextcloud/${appName}/releases/download/v${version}/${appName}.tar.gz";
7 sha256 = "sha256-BfH1W+7TWKZRuAAhKQEQtlv8ePTtJQvZQVMMu3zULR4=";
8 };
9 versions = {
10 "25" = notes_4_8_1;
11 "26" = notes_4_8_1;
12 "27" = notes_4_8_1;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app notes")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/ocsms.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/ocsms.nix
new file mode 100644
index 0000000..dcdaad2
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/ocsms.nix
@@ -0,0 +1,21 @@
1{ buildApp, nextcloudVersion }:
2let
3 ocsms_2_2_0 = buildApp rec {
4 appName = "ocsms";
5 version = "2.2.0";
6 url = "https://github.com/nextcloud/${appName}/releases/download/${version}/${appName}-${version}.tar.gz";
7 sha256 = "1hjl11lxdflk4w0l8prcjr3jvmsm8njldbrmnqm7yhdy6qcfli28";
8 installPhase = ''
9 mkdir -p $out
10 cp -R . $out/
11 '';
12 };
13 versions = {
14 "18" = ocsms_2_2_0;
15 "19" = ocsms_2_2_0;
16 "20" = ocsms_2_2_0;
17 # Beware, 1.10.1 has a too wide range of versions and is not
18 # compatible with nextcloud > 20!
19 };
20in
21 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app ocsms")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/onlyoffice.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/onlyoffice.nix
new file mode 100644
index 0000000..e93df00
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/onlyoffice.nix
@@ -0,0 +1,21 @@
1{ buildApp, nextcloudVersion }:
2let
3 onlyoffice_7_9_0 = buildApp rec {
4 appName = "onlyoffice";
5 version = "7.9.0";
6 url = "https://github.com/ONLYOFFICE/onlyoffice-nextcloud/releases/download/v${version}/${appName}.tar.gz";
7 sha256 = "sha256-GN0edA/aVdOEDR0LF6PgG2vTcULaG9RMj2gIAoxSVAM=";
8 };
9 onlyoffice_8_2_0 = buildApp rec {
10 appName = "onlyoffice";
11 version = "8.2.0";
12 url = "https://github.com/ONLYOFFICE/onlyoffice-nextcloud/releases/download/v${version}/${appName}.tar.gz";
13 sha256 = "sha256-DfZKgpkpcogy9I3A3ru0V/WR5wYWBr+wrHe+mQJBPYk=";
14 };
15 versions = {
16 "25" = onlyoffice_7_9_0;
17 "26" = onlyoffice_7_9_0;
18 "27" = onlyoffice_8_2_0;
19 };
20in
21 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app onlyoffice")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/passman.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/passman.nix
new file mode 100644
index 0000000..5559b22
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/passman.nix
@@ -0,0 +1,21 @@
1{ buildApp, nextcloudVersion }:
2let
3 passman_2_4_5 = buildApp rec {
4 appName = "passman";
5 version = "2.4.5";
6 url = "https://releases.passman.cc/${appName}_${version}.tar.gz";
7 sha256 = "sha256-wcRx1lUEHbJBJBBSKOScGljOgHM7Vpf69OymJoI8S2Y=";
8 };
9 passman_2_4_7 = buildApp rec {
10 appName = "passman";
11 version = "2.4.7";
12 url = "https://releases.passman.cc/${appName}_${version}.tar.gz";
13 sha256 = "sha256-CeNaN0cioVjcW6ILB//BIvmjQWcbvfK3m8jVQ8LGtyM=";
14 };
15 versions = {
16 "25" = passman_2_4_5;
17 "26" = passman_2_4_7;
18 "27" = passman_2_4_7;
19 };
20in
21 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app passman")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/polls.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/polls.nix
new file mode 100644
index 0000000..a50ac43
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/polls.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 polls_5_2_0 = buildApp rec {
4 appName = "polls";
5 version = "5.2.0";
6 url = "https://github.com/nextcloud/polls/releases/download/v${version}/${appName}.tar.gz";
7 sha256 = "sha256-45YNcSeFG9v3mfk7eLbDiy6hFgmfePY0j86JiVS0k14=";
8 };
9 versions = {
10 "25" = polls_5_2_0;
11 "26" = polls_5_2_0;
12 "27" = polls_5_2_0;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app polls")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/side_menu.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/side_menu.nix
new file mode 100644
index 0000000..da48f91
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/side_menu.nix
@@ -0,0 +1,16 @@
1{ buildApp, nextcloudVersion }:
2let
3 side_menu_3_10_3 = buildApp rec {
4 appName = "side_menu";
5 version = "3.10.3";
6 url = "https://gitnet.fr/attachments/9c9be610-5d3b-414d-a523-396c237c15ef";
7 filename = "${appName}-${version}.tar.gz";
8 sha256 = "sha256-WKbc6Ln6v3LYyRzwy0xAOmXilbqrWGS8XGWIT+TajdM=";
9 };
10 versions = {
11 "25" = side_menu_3_10_3;
12 "26" = side_menu_3_10_3;
13 "27" = side_menu_3_10_3;
14 };
15in
16 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app side_menu")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/social.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/social.nix
new file mode 100644
index 0000000..912b5bf
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/social.nix
@@ -0,0 +1,14 @@
1{ buildApp, nextcloudVersion }:
2let
3 social_0_6_1 = buildApp rec {
4 appName = "social";
5 version = "0.6.1";
6 url = "https://github.com/nextcloud-releases/social/releases/download/v${version}/${appName}-v${version}.tar.gz";
7 sha256 = "sha256-5mww31ibwgnSiTuTaKo5MngbhPIw8lwLt1tkQySmerY=";
8 };
9 versions = {
10 "26" = social_0_6_1;
11 "27" = social_0_6_1;
12 };
13in
14 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app social")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/spreed.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/spreed.nix
new file mode 100644
index 0000000..d8a20b9
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/spreed.nix
@@ -0,0 +1,27 @@
1{ buildApp, nextcloudVersion }:
2let
3 spreed_15_0_7 = buildApp rec {
4 appName = "spreed";
5 version = "15.0.7";
6 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
7 sha256 = "sha256-J9udO7qlRL+TDwTPTbBpYeZLUi4oco42LoqYoHJbIyE=";
8 };
9 spreed_16_0_5 = buildApp rec {
10 appName = "spreed";
11 version = "16.0.5";
12 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
13 sha256 = "sha256-tTDnWqNkP6fMSdCP1c0vPh8f0K7sTFBvRwws5Gln9Mg=";
14 };
15 spreed_17_0_3 = buildApp rec {
16 appName = "spreed";
17 version = "17.0.3";
18 url = "https://github.com/nextcloud-releases/${appName}/releases/download/v${version}/${appName}-v${version}.tar.gz";
19 sha256 = "sha256-vb08DI+q+5f87zz2UguE1y6b0NV2EoICYpaKUGmyF5w=";
20 };
21 versions = {
22 "25" = spreed_15_0_7;
23 "26" = spreed_16_0_5;
24 "27" = spreed_17_0_3;
25 };
26in
27 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app spreed")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/talk_matterbridge.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/talk_matterbridge.nix
new file mode 100644
index 0000000..906719d
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/talk_matterbridge.nix
@@ -0,0 +1,14 @@
1{ buildApp, nextcloudVersion }:
2let
3 talk_matterbridge_1_26_0 = buildApp rec {
4 appName = "talk_matterbridge";
5 version = "1.26.0";
6 url = "https://github.com/nextcloud/${appName}/releases/download/v${version}/${appName}.tar.gz";
7 sha256 = "sha256-gD5lfLWBjWOiy2ULf31ngQVIQbMZj3iwu3zuVrEDSks=";
8 };
9 versions = {
10 "25" = talk_matterbridge_1_26_0;
11 "26" = talk_matterbridge_1_26_0;
12 };
13in
14 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app talk_matterbridge")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/apps/tasks.nix b/flakes/mypackages/pkgs/webapps/nextcloud/apps/tasks.nix
new file mode 100644
index 0000000..aee7650
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/apps/tasks.nix
@@ -0,0 +1,15 @@
1{ buildApp, nextcloudVersion }:
2let
3 tasks_0_15_0 = buildApp rec {
4 appName = "tasks";
5 version = "0.15.0";
6 url = "https://github.com/nextcloud/${appName}/releases/download/v${version}/${appName}.tar.gz";
7 sha256 = "sha256-nizJUFByK78FZ6KPJ4zfOU5Z9ClAxhwgQ7d+X5TGnM8=";
8 };
9 versions = {
10 "25" = tasks_0_15_0;
11 "26" = tasks_0_15_0;
12 "27" = tasks_0_15_0;
13 };
14in
15 versions."${builtins.toString nextcloudVersion}" or (throw "Unsupported version for nextcloud app tasks")
diff --git a/flakes/mypackages/pkgs/webapps/nextcloud/default.nix b/flakes/mypackages/pkgs/webapps/nextcloud/default.nix
new file mode 100644
index 0000000..6aeeaed
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/nextcloud/default.nix
@@ -0,0 +1,84 @@
1{ nextcloudVersion, otherConfig ? {}, lib, stdenv, callPackage, fetchzip, fetchurl, postInstall ? null }:
2let
3 shasumsAndVersion = {
4 "25" = { sum = "sha256-alvh0fWESSS5KbfiKI1gaoahisDWnfT/bUhsSEEXfQI="; fullVersion = "25.0.10"; }; # php 7.4 - 8.2
5 "26" = { sum = "sha256-nhq0aAY4T1hUZdKJY66ZSlirCSgPQet8YJpciwJw1b4="; fullVersion = "26.0.5"; }; # php 8.0 - 8.2
6 "27" = { sum = "sha256-ei3OpDqjuPswM0fv2kxvN3M8yhE8juFt2fDl+2jHIS8="; fullVersion = "27.0.2"; }; # php 8.0 - 8.2
7 };
8 appNames = [
9 "audioplayer" "bookmarks" "calendar" "carnet"
10 "contacts" "cookbook" "deck" "external" "extract" "files_markdown" "files_mindmap"
11 "files_readmemd" "flowupload" "gpxedit" "gpxpod" "groupfolders" "impersonate"
12 "keeweb" "maps" "metadata" "music" "notes" "ocsms" "onlyoffice" "passman" "polls"
13 "social" "spreed" "talk_matterbridge" "tasks" "drawio" "side_menu"
14 "integration_dropbox"
15 ];
16 toApp = name: callPackage (./apps + "/${name}.nix") { inherit buildApp nextcloudVersion; };
17 allSupportedApps = lib.mapAttrs (n: v: v.value) (lib.filterAttrs (n: v: v.success) (lib.genAttrs appNames (name: builtins.tryEval (toApp name))));
18 allApps = lib.genAttrs appNames toApp;
19 buildApp = { appName, version, filename ? null, url, sha256, installHook ? (n: ""), otherConfig ? {}, installPhase ? "mkdir -p $out && cp -R . $out/" }:
20 stdenv.mkDerivation rec {
21 name = "nextcloud-app-${appName}-${version}";
22 inherit version;
23 phases = "unpackPhase installPhase";
24 inherit installPhase;
25 src = fetchurl ({ inherit url sha256; } // lib.optionalAttrs (filename != null) { name = filename; });
26 passthru = {
27 inherit appName otherConfig installHook;
28 };
29 };
30 toPassthru = pkg: apps: otherConfig: {
31 inherit apps otherConfig allApps allSupportedApps buildApp;
32 withApps = withApps pkg;
33 };
34 withApps = pkg: toApps:
35 let
36 apps = toApps allApps;
37 toInstallApp = n: ''
38 if [ -e $out/apps/${n.appName} ]; then
39 echo "${n.appName} already exists"
40 false
41 fi
42 ln -sf ${n} $out/apps/${n.appName}
43 '' + (n.installHook n);
44 zipped = lib.attrsets.zipAttrs ([pkg.otherConfig or {}] ++ map (v: v.otherConfig) apps);
45 appConfigs = with lib.attrsets; with lib.lists; {
46 mimetypealiases = foldr (h: prev: prev // h) {} (zipped.mimetypealiases or []);
47 mimetypemapping = mapAttrs (_: v: unique (flatten v)) (zipAttrs (zipped.mimetypemapping or []));
48 };
49 newNextcloud = pkg.overrideAttrs(old: {
50 installPhase = old.installPhase + "\n" + builtins.concatStringsSep "\n" (map toInstallApp apps);
51 passthru = toPassthru newNextcloud (pkg.apps ++ apps) appConfigs;
52 });
53 in newNextcloud;
54 package = stdenv.mkDerivation rec {
55 name = "nextcloud-${version}";
56 version = shasumsAndVersion."${builtins.toString nextcloudVersion}".fullVersion;
57
58 src = fetchurl {
59 url = "https://download.nextcloud.com/server/releases/${name}.tar.bz2";
60 sha256 = shasumsAndVersion."${builtins.toString nextcloudVersion}".sum;
61 };
62
63 inherit postInstall;
64 installPhase = ''
65 mkdir -p $out/
66 cp -R . $out/
67 sed -i -e "/'appDirsWithDifferentOwner'/d" $out/apps/settings/lib/Controller/CheckSetupController.php
68 mv $out/config $out/config.example
69 runHook postInstall
70 '';
71
72 noAuditTmpdir = true;
73 dontPatchELF = true;
74 dontStrip = true;
75 passthru = toPassthru package [] otherConfig;
76 meta = {
77 description = "Sharing solution for files, calendars, contacts and more";
78 homepage = https://nextcloud.com;
79 maintainers = with lib.maintainers; [ schneefux bachp globin fpletz ];
80 license = lib.licenses.agpl3Plus;
81 platforms = with lib.platforms; unix;
82 };
83 };
84in package
diff --git a/flakes/mypackages/pkgs/webapps/phpbb/default.nix b/flakes/mypackages/pkgs/webapps/phpbb/default.nix
new file mode 100644
index 0000000..21ee154
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/phpbb/default.nix
@@ -0,0 +1,61 @@
1{ stdenv, fetchurl, callPackage
2, varDir ? "/var/lib/phpbb"
3}:
4let
5 allExts = {
6 alfredoramos.markdown = callPackage ./extensions/markdown.nix {};
7 davidiq.mailinglist = callPackage ./extensions/mailinglist.nix {};
8 dmzx.mchat = callPackage ./extensions/mchat.nix {};
9 empteintesduweb.monitoranswers = callPackage ./extensions/monitoranswers.nix {};
10 lr94.autosubscribe = callPackage ./extensions/autosubscribe.nix {};
11 phpbbmodders.adduser = callPackage ./extensions/adduser.nix {};
12 };
13 allLangs = {
14 fr = callPackage ./langs/fr.nix {};
15 };
16 toPassthru = pkg: {
17 inherit allLangs allExts;
18 withLangs = withLangs pkg;
19 withExts = withExts pkg;
20 };
21 withExts = pkg: toExts:
22 let
23 exts = toExts allExts;
24 toInstallExt = ext: "cp -r ${ext}/* $out/ext/";
25 newPhpBB = pkg.overrideAttrs(old: {
26 installPhase = old.installPhase + "\n" + builtins.concatStringsSep "\n" (map toInstallExt exts);
27 passthru = toPassthru newPhpBB;
28 });
29 in newPhpBB;
30 withLangs = pkg: toLangs:
31 let
32 langs = toLangs allLangs;
33 toInstallLang = lang: "cp -r ${lang}/*/ $out";
34 newPhpBB = pkg.overrideAttrs(old: {
35 installPhase = old.installPhase + "\n" + builtins.concatStringsSep "\n" (map toInstallLang langs);
36 passthru = toPassthru newPhpBB;
37 });
38 in newPhpBB;
39 phpBB = stdenv.mkDerivation rec {
40 pname = "phpBB";
41 version = "3.3.0";
42
43 src = fetchurl {
44 url = "https://download.phpbb.com/pub/release/3.3/${version}/${pname}-${version}.tar.bz2";
45 sha256 = "a6234ac9dcf9086c025ece29a0a235f997a92bb9a994eff0ddcf8917e841262f";
46 };
47
48 phases = [ "unpackPhase" "installPhase" ];
49
50 installPhase = ''
51 cp -a . $out
52 mkdir -p $out/vars
53 mv $out/{cache,files,store,config.php} $out/vars
54 ln -s ${varDir}/{cache,files,store,config.php} $out/
55 echo -e "core:\n allow_install_dir: true" >> $out/config/production/config.yml
56 '';
57
58 passthru = toPassthru phpBB;
59 };
60in
61 phpBB
diff --git a/flakes/mypackages/pkgs/webapps/phpbb/extensions/adduser.nix b/flakes/mypackages/pkgs/webapps/phpbb/extensions/adduser.nix
new file mode 100644
index 0000000..f9073e6
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/phpbb/extensions/adduser.nix
@@ -0,0 +1,22 @@
1{ stdenv, fetchurl, unzip }:
2stdenv.mkDerivation rec {
3 pname = "phpBB-extension-adduser";
4 version = "1.0.4";
5 src = fetchurl {
6 # https://www.phpbb.com/customise/db/extension/acp_add_user_2
7 url = "https://www.phpbb.com/customise/db/download/141601";
8 sha256 = "13m4anib74cinnv1ap3b1ncb8cxm3mzhhmlqhbrr9mlrqmwf4zg2";
9 };
10
11 buildInputs = [ unzip ];
12 phases = [ "unpackPhase" "installPhase" ];
13 unpackPhase = ''
14 mkdir src
15 cd src
16 unzip $src
17 '';
18 installPhase = ''
19 cp -a . $out
20 cp -a $out/phpbbmodders/adduser/language/en $out/phpbbmodders/adduser/language/fr
21 '';
22}
diff --git a/flakes/mypackages/pkgs/webapps/phpbb/extensions/autosubscribe.nix b/flakes/mypackages/pkgs/webapps/phpbb/extensions/autosubscribe.nix
new file mode 100644
index 0000000..78e23fc
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/phpbb/extensions/autosubscribe.nix
@@ -0,0 +1,19 @@
1{ stdenv, fetchurl, unzip }:
2stdenv.mkDerivation rec {
3 pname = "phpBB-extension-autosubscribe";
4 version = "1.1.0";
5 src = fetchurl {
6 # https://www.phpbb.com/customise/db/extension/autosubscribe
7 url = "https://www.phpbb.com/customise/db/download/146556";
8 sha256 = "0dsay463g4impw86w1nv307nslc195fkgkqmihfn5kc0hya0giv0";
9 };
10
11 buildInputs = [ unzip ];
12 phases = [ "unpackPhase" "installPhase" ];
13 unpackPhase = ''
14 mkdir src
15 cd src
16 unzip $src
17 '';
18 installPhase = "cp -a . $out";
19}
diff --git a/flakes/mypackages/pkgs/webapps/phpbb/extensions/mailinglist.nix b/flakes/mypackages/pkgs/webapps/phpbb/extensions/mailinglist.nix
new file mode 100644
index 0000000..d432aaf
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/phpbb/extensions/mailinglist.nix
@@ -0,0 +1,18 @@
1{ stdenv, fetchurl, unzip }:
2stdenv.mkDerivation rec {
3 pname = "phpBB-extension-MailingList";
4 version = "2.0.0";
5 src = fetchurl {
6 url = "https://github.com/DavidIQ/MailingList/archive/${version}.tar.gz";
7 sha256 = "1ddg8bci85jwmvyakcwdn4yzqwz1rgy7ljf4nmfk9p2kvx2nhj62";
8 };
9
10 phases = [ "unpackPhase" "installPhase" ];
11 installPhase = ''
12 mkdir -p $out/davidiq/mailinglist
13 cp -a . $out/davidiq/mailinglist
14 # delete last two lines which contain EMAIL_SIG
15 sed -i -n -e :a -e '1,2!{P;N;D;};N;ba' $out/davidiq/mailinglist/language/en/email/*
16 '';
17}
18
diff --git a/flakes/mypackages/pkgs/webapps/phpbb/extensions/markdown.nix b/flakes/mypackages/pkgs/webapps/phpbb/extensions/markdown.nix
new file mode 100644
index 0000000..3bd73c7
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/phpbb/extensions/markdown.nix
@@ -0,0 +1,20 @@
1{ stdenv, fetchurl, unzip }:
2stdenv.mkDerivation rec {
3 pname = "phpBB-extension-markdown";
4 version = "1.2.0";
5 src = fetchurl {
6 # https://www.phpbb.com/customise/db/extension/markdown
7 name = "alfredoramos_markdown_${version}.zip";
8 url = "https://www.phpbb.com/customise/db/download/173626";
9 sha256 = "0bmgi8qr6azaaz8xnz8dkyf147dyawqvqr93r01qbm9s8bfkpzqx";
10 };
11
12 buildInputs = [ unzip ];
13 phases = [ "unpackPhase" "installPhase" ];
14 unpackPhase = ''
15 mkdir src
16 cd src
17 unzip $src
18 '';
19 installPhase = "cp -a . $out";
20}
diff --git a/flakes/mypackages/pkgs/webapps/phpbb/extensions/mchat.nix b/flakes/mypackages/pkgs/webapps/phpbb/extensions/mchat.nix
new file mode 100644
index 0000000..93ea861
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/phpbb/extensions/mchat.nix
@@ -0,0 +1,21 @@
1{ stdenv, fetchurl, unzip }:
2stdenv.mkDerivation rec {
3 pname = "phpBB-extension-mchat";
4 version = "2.1.3";
5 src = fetchurl {
6 # https://www.phpbb.com/customise/db/extension/mchat_extension
7 name = "dmzx_mchat_${version}.zip";
8 url = "https://www.phpbb.com/customise/db/download/168331";
9 sha256 = "0mcka02wamn899vg64m1c5d5k6f4qml18cshhzfvccrdc7a0m5p1";
10 };
11
12 buildInputs = [ unzip ];
13 phases = [ "unpackPhase" "installPhase" ];
14 unpackPhase = ''
15 mkdir src
16 cd src
17 unzip $src
18 '';
19 installPhase = "cp -a . $out";
20}
21
diff --git a/flakes/mypackages/pkgs/webapps/phpbb/extensions/monitoranswers.nix b/flakes/mypackages/pkgs/webapps/phpbb/extensions/monitoranswers.nix
new file mode 100644
index 0000000..52c852e
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/phpbb/extensions/monitoranswers.nix
@@ -0,0 +1,19 @@
1{ stdenv, fetchurl, unzip }:
2stdenv.mkDerivation rec {
3 pname = "phpBB-extension-monitoranswers";
4 version = "1.0.0";
5 src = fetchurl {
6 # http://forums.phpbb-fr.com/extensions-developpement-en-cours/sujet208410.html
7 url = "https://www.empreintesduweb.com/dl/extension_empreintesduweb_monitoranswers_v100.zip";
8 sha256 = "0g5khzz7brkra9rnnjh8vsv11h8vf36pcw53b4wrkcjb66bfm20s";
9 };
10
11 buildInputs = [ unzip ];
12 phases = [ "unpackPhase" "installPhase" ];
13 unpackPhase = ''
14 mkdir src
15 cd src
16 unzip $src
17 '';
18 installPhase = "cp -a . $out";
19}
diff --git a/flakes/mypackages/pkgs/webapps/phpbb/langs/fr.nix b/flakes/mypackages/pkgs/webapps/phpbb/langs/fr.nix
new file mode 100644
index 0000000..12f2df0
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/phpbb/langs/fr.nix
@@ -0,0 +1,12 @@
1{ stdenv, fetchurl }:
2stdenv.mkDerivation rec {
3 pname = "phpBB-language-fr";
4 version = "v4.0.0";
5 src = fetchurl {
6 url = "https://github.com/milescellar/phpbb-language-fr/archive/${version}.tar.gz";
7 sha256 = "0pkw55pb8ka4ayn1861hwvjwzs8vkq04yaxrs7zm9c8lh2g7y8z0";
8 };
9
10 phases = [ "unpackPhase" "installPhase" ];
11 installPhase = "cp -a . $out";
12}
diff --git a/flakes/mypackages/pkgs/webapps/phpldapadmin/default.nix b/flakes/mypackages/pkgs/webapps/phpldapadmin/default.nix
new file mode 100644
index 0000000..da32f97
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/phpldapadmin/default.nix
@@ -0,0 +1,27 @@
1{ config ? "/etc/phpldapadmin/config.php", fetchurl, fetchFromGitHub, stdenv, optipng }:
2stdenv.mkDerivation rec {
3 version = "1.2.5";
4 name = "phpldapadmin-${version}";
5 src = fetchFromGitHub {
6 owner = "leenooks";
7 repo = "phpLDAPadmin";
8 rev = "8f4ced96f9c63a09510a5bccb2189a8b92fb29ba";
9 sha256 = "1x6xc3xbvw3aj46i5ds06a8h6mfljxdv3argxrzz02l541ra6ni7";
10 };
11 patches = [
12 #./ldap-php5_5.patch
13 #./ldap-disable-mcrypt.patch
14 #./ldap-php7_2.patch
15 ./ldap-sort-in-templates.patch
16 ./ldap-align-button.patch
17 ./ldap-fix-password.patch
18 ];
19 buildInputs = [ optipng ];
20 buildPhase = ''
21 find -name '*.png' -exec optipng -quiet -force -fix {} \;
22 '';
23 installPhase = ''
24 cp -a . $out
25 ln -sf ${config} $out/config/config.php
26 '';
27}
diff --git a/flakes/mypackages/pkgs/webapps/phpldapadmin/ldap-align-button.patch b/flakes/mypackages/pkgs/webapps/phpldapadmin/ldap-align-button.patch
new file mode 100644
index 0000000..d9a5504
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/phpldapadmin/ldap-align-button.patch
@@ -0,0 +1,11 @@
1--- a/htdocs/update_confirm.php 2012-10-01 08:54:14.000000000 +0200
2+++ b/htdocs/update_confirm.php 2018-06-06 15:47:44.122398888 +0200
3@@ -187,7 +187,7 @@
4
5 echo '</table>';
6
7- echo '<div style="text-align: center;">';
8+ echo '<div style="text-align: left;">';
9 echo '<br />';
10 // @todo cant use AJAX here, it affects file uploads.
11 printf('<input type="submit" value="%s" />',
diff --git a/flakes/mypackages/pkgs/webapps/phpldapadmin/ldap-fix-password.patch b/flakes/mypackages/pkgs/webapps/phpldapadmin/ldap-fix-password.patch
new file mode 100644
index 0000000..d2d80e4
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/phpldapadmin/ldap-fix-password.patch
@@ -0,0 +1,13 @@
1diff --git a/htdocs/login.php b/htdocs/login.php
2index 48f9e2e..298b07d 100644
3--- a/htdocs/login.php
4+++ b/htdocs/login.php
5@@ -13,7 +13,7 @@ require './common.php';
6
7 $user = array();
8 $user['login'] = get_request('login');
9-$user['password'] = get_request('login_pass');
10+$user['password'] = get_request('login_pass','POST',false,null,false);
11
12 if ($user['login'] && ! strlen($user['password']))
13 system_message(array(
diff --git a/flakes/mypackages/pkgs/webapps/phpldapadmin/ldap-sort-in-templates.patch b/flakes/mypackages/pkgs/webapps/phpldapadmin/ldap-sort-in-templates.patch
new file mode 100644
index 0000000..55a1974
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/phpldapadmin/ldap-sort-in-templates.patch
@@ -0,0 +1,12 @@
1diff -wbBur phpldapadmin-1.2.3.org/lib/TemplateRender.php phpldapadmin-1.2.3/lib/TemplateRender.php
2--- phpldapadmin-1.2.3.org/lib/TemplateRender.php 2012-10-01 10:54:14.000000000 +0400
3+++ phpldapadmin-1.2.3/lib/TemplateRender.php 2018-02-02 19:06:45.674760057 +0300
4@@ -321,6 +321,8 @@
5
6 $vals = array();
7
8+ asort($picklistvalues);
9+
10 foreach ($picklistvalues as $key => $values) {
11 $display = $args[3];
12
diff --git a/flakes/mypackages/pkgs/webapps/rompr/default.nix b/flakes/mypackages/pkgs/webapps/rompr/default.nix
new file mode 100644
index 0000000..5b3e7e0
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/rompr/default.nix
@@ -0,0 +1,17 @@
1{ varDir ? "/var/lib/rompr", stdenv, fetchFromGitHub }:
2stdenv.mkDerivation ({
3 pname = "rompr";
4 version = "1.24";
5 src = fetchFromGitHub {
6 owner = "fatg3erman";
7 repo = "RompR";
8 rev = "0d8f597027ac71b320963fe3f33f461a136312ad";
9 sha256 = "13p3c4whhmvz1vvh9fva5gdx4xji288k108hjdi8b1yn506lzix2";
10 fetchSubmodules = true;
11 };
12 installPhase = ''
13 cp -a . $out
14 ln -sf ${varDir}/prefs $out/prefs
15 ln -sf ${varDir}/albumart $out/albumart
16 '';
17})
diff --git a/flakes/mypackages/pkgs/webapps/roundcubemail/add_all.patch b/flakes/mypackages/pkgs/webapps/roundcubemail/add_all.patch
new file mode 100644
index 0000000..ba651e2
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/roundcubemail/add_all.patch
@@ -0,0 +1,209 @@
1diff --git a/program/include/rcmail_output_html.php b/program/include/rcmail_output_html.php
2index 0552b89c2..1b84e1b4e 100644
3--- a/program/include/rcmail_output_html.php
4+++ b/program/include/rcmail_output_html.php
5@@ -1013,13 +1013,13 @@ EOF;
6 // use minified file if exists (not in development mode)
7 if (!$this->devel_mode && !preg_match('/\.min\.' . $ext . '$/', $file)) {
8 $minified_file = substr($file, 0, strlen($ext) * -1) . 'min.' . $ext;
9- if ($fs = @filemtime($this->assets_dir . $minified_file)) {
10- return $minified_file . '?s=' . $fs;
11+ if ($fs = @md5_file($this->assets_dir . $minified_file)) {
12+ return $minified_file . '?s=' . substr($fs, 0, 6);
13 }
14 }
15
16- if ($fs = @filemtime($this->assets_dir . $file)) {
17- $file .= '?s=' . $fs;
18+ if ($fs = @md5_file($this->assets_dir . $file)) {
19+ $file .= '?s=' . substr($fs, 0, 6);
20 }
21
22 return $file;
23diff --git a/program/js/app.js b/program/js/app.js
24index 2094b7b7b..06fe96a80 100644
25--- a/program/js/app.js
26+++ b/program/js/app.js
27@@ -2277,6 +2277,9 @@ function rcube_webmail()
28 }
29
30 tree += '<span id="msgicn'+row.id+'" class="'+css_class+status_class+'" title="'+status_label+'"></span>';
31+ if (flags.mbox != this.env.mailbox) {
32+ tree += '<span style="color:#737677">' + flags.mbox + '&nbsp;<span>';
33+ }
34 row.className = row_class;
35
36 // build subject link
37diff --git a/program/localization/en_CA/labels.inc b/program/localization/en_CA/labels.inc
38index 03c1c8e11..8d67a49ac 100644
39--- a/program/localization/en_CA/labels.inc
40+++ b/program/localization/en_CA/labels.inc
41@@ -128,6 +128,7 @@ $labels['markunread'] = 'As unread';
42 $labels['markflagged'] = 'As flagged';
43 $labels['markunflagged'] = 'As unflagged';
44 $labels['moreactions'] = 'More actions...';
45+$labels['folders-allsubscribed'] = 'All subscribed folders';
46 $labels['folders-all'] = 'All folders';
47 $labels['more'] = 'More';
48 $labels['back'] = 'Back';
49@@ -184,6 +185,7 @@ $labels['namex'] = 'Name';
50 $labels['searchscope'] = 'Scope';
51 $labels['currentfolder'] = 'Current folder';
52 $labels['subfolders'] = 'This and subfolders';
53+$labels['allsubscribedfolders'] = 'All subscribed folders';
54 $labels['allfolders'] = 'All folders';
55 $labels['openinextwin'] = 'Open in new window';
56 $labels['emlsave'] = 'Download (.eml)';
57diff --git a/program/localization/en_GB/labels.inc b/program/localization/en_GB/labels.inc
58index a442965de..b5b4839e3 100644
59--- a/program/localization/en_GB/labels.inc
60+++ b/program/localization/en_GB/labels.inc
61@@ -135,6 +135,7 @@ $labels['moreactions'] = 'More actions...';
62 $labels['markallread'] = 'Mark all as read';
63 $labels['folders-cur'] = 'Selected folder only';
64 $labels['folders-sub'] = 'Selected folder and its subfolders';
65+$labels['folders-allsubscribed'] = 'All subscribed folders';
66 $labels['folders-all'] = 'All folders';
67 $labels['more'] = 'More';
68 $labels['back'] = 'Back';
69@@ -221,6 +222,7 @@ $labels['namex'] = 'Name';
70 $labels['searchscope'] = 'Scope';
71 $labels['currentfolder'] = 'Current folder';
72 $labels['subfolders'] = 'This and subfolders';
73+$labels['allsubscribedfolders'] = 'All subscribed folders';
74 $labels['allfolders'] = 'All folders';
75 $labels['searchinterval-1W'] = 'older than a week';
76 $labels['searchinterval-1M'] = 'older than a month';
77diff --git a/program/localization/en_US/labels.inc b/program/localization/en_US/labels.inc
78index 2e8ec8009..c7736557f 100644
79--- a/program/localization/en_US/labels.inc
80+++ b/program/localization/en_US/labels.inc
81@@ -158,6 +158,7 @@ $labels['moreactions'] = 'More actions...';
82 $labels['markallread'] = 'Mark all as read';
83 $labels['folders-cur'] = 'Selected folder only';
84 $labels['folders-sub'] = 'Selected folder and its subfolders';
85+$labels['folders-allsubscribed'] = 'All subscribed folders';
86 $labels['folders-all'] = 'All folders';
87 $labels['more'] = 'More';
88 $labels['back'] = 'Back';
89@@ -249,6 +250,7 @@ $labels['namex'] = 'Name';
90 $labels['searchscope'] = 'Scope';
91 $labels['currentfolder'] = 'Current folder';
92 $labels['subfolders'] = 'This and subfolders';
93+$labels['allsubscribedfolders'] = 'All subscribed folders';
94 $labels['allfolders'] = 'All folders';
95 $labels['searchinterval-1W'] = 'older than a week';
96 $labels['searchinterval-1M'] = 'older than a month';
97diff --git a/program/localization/fr_FR/labels.inc b/program/localization/fr_FR/labels.inc
98index 6db44f95c..ad83e15d8 100644
99--- a/program/localization/fr_FR/labels.inc
100+++ b/program/localization/fr_FR/labels.inc
101@@ -135,6 +135,7 @@ $labels['moreactions'] = 'Plus d’actions…';
102 $labels['markallread'] = 'Tout marquer comme lu';
103 $labels['folders-cur'] = 'Dossier sélectionné seulement';
104 $labels['folders-sub'] = 'Dossier sélectionné et ses sous-dossiers';
105+$labels['folders-allsubscribed'] = 'Tous les dossiers souscrits';
106 $labels['folders-all'] = 'Tous les dossiers';
107 $labels['more'] = 'Plus';
108 $labels['back'] = 'Retour';
109@@ -221,6 +222,7 @@ $labels['namex'] = 'Nom';
110 $labels['searchscope'] = 'Portée';
111 $labels['currentfolder'] = 'Répertoire actuel';
112 $labels['subfolders'] = 'Ceci et les sous-dossiers';
113+$labels['allsubscribedfolders'] = 'Tous les dossiers souscrits';
114 $labels['allfolders'] = 'Tous les dossiers';
115 $labels['searchinterval-1W'] = 'plus d’une semaine';
116 $labels['searchinterval-1M'] = 'plus d’un mois';
117diff --git a/program/steps/mail/func.inc b/program/steps/mail/func.inc
118index 8e0c642f6..ac79780e0 100644
119--- a/program/steps/mail/func.inc
120+++ b/program/steps/mail/func.inc
121@@ -110,8 +110,8 @@ if (empty($RCMAIL->action) || $RCMAIL->action == 'list') {
122 'copy', 'move', 'quota', 'replyall', 'replylist', 'stillsearching',
123 'flagged', 'unflagged', 'unread', 'deleted', 'replied', 'forwarded',
124 'priority', 'withattachment', 'fileuploaderror', 'mark', 'markallread',
125- 'folders-cur', 'folders-sub', 'folders-all', 'cancel', 'bounce', 'bouncemsg',
126- 'sendingmessage');
127+ 'folders-cur', 'folders-sub', 'folders-allsubscribed', 'folder-all',
128+ 'cancel', 'bounce', 'bouncemsg', 'sendingmessage');
129 }
130 }
131
132diff --git a/program/steps/mail/search.inc b/program/steps/mail/search.inc
133index f60528835..836a715b0 100644
134--- a/program/steps/mail/search.inc
135+++ b/program/steps/mail/search.inc
136@@ -86,7 +86,7 @@ else if (strlen(trim($str))) {
137 }
138
139 // save search modifiers for the current folder to user prefs
140- $mkey = $scope == 'all' ? '*' : $mbox;
141+ $mkey = ($scope == 'all' || $scope == 'allsubscribed') ? '*' : $mbox;
142 $search_mods = rcmail_search_mods();
143 $search_mods[$mkey] = array_fill_keys(array_keys($subject), 1);
144
145@@ -124,6 +124,10 @@ if (!empty($continue) && isset($_SESSION['search']) && $_SESSION['search_request
146 if ($search_str) {
147 // search all, current or subfolders folders
148 if ($scope == 'all') {
149+ $mboxes = $RCMAIL->storage->list_folders('', '*', 'mail', null, true);
150+ natcasesort($mboxes); // we want natural alphabetic sorting of folders in the result set
151+ }
152+ else if ($scope == 'allsubscribed') {
153 $mboxes = $RCMAIL->storage->list_folders_subscribed('', '*', 'mail', null, true);
154 natcasesort($mboxes); // we want natural alphabetic sorting of folders in the result set
155 }
156@@ -133,7 +137,7 @@ if ($search_str) {
157 array_unshift($mboxes, $mbox);
158 }
159
160- if ($scope != 'all') {
161+ if ($scope != 'all' && $scope != 'allsubscribed') {
162 // Remember current folder, it can change in meantime (plugins)
163 // but we need it to e.g. recognize Sent folder to handle From/To column later
164 $RCMAIL->output->set_env('mailbox', $mbox);
165@@ -194,7 +198,7 @@ else {
166 $count = 0;
167 $OUTPUT->show_message('searchnomatch', 'notice');
168 $OUTPUT->set_env('multifolder_listing', (bool)$result->multi);
169- if ($result->multi && $scope == 'all') {
170+ if ($result->multi && ($scope == 'all' || $scope == 'allsubscribed')) {
171 $OUTPUT->command('select_folder', '');
172 }
173 }
174diff --git a/skins/classic/templates/mail.html b/skins/classic/templates/mail.html
175index 666adf606..23d12a275 100644
176--- a/skins/classic/templates/mail.html
177+++ b/skins/classic/templates/mail.html
178@@ -106,6 +106,7 @@
179 <li><label class="comment"><roundcube:label name="searchscope" /></label></li>
180 <li><label><input type="radio" name="s_scope" value="base" id="s_scope_base" onclick="rcmail.set_searchscope(this.value)" /> <span><roundcube:label name="currentfolder" /></span></label></li>
181 <li><label><input type="radio" name="s_scope" value="sub" id="s_scope_sub" onclick="rcmail.set_searchscope(this.value)" /> <span><roundcube:label name="subfolders" /></span></label></li>
182+ <li><label><input type="radio" name="s_scope" value="allsubscribed" id="s_scope_allsubscribed" onclick="rcmail.set_searchscope(this.value)" /> <span><roundcube:label name="allsubscribedfolders" /></span></label></li>
183 <li><label><input type="radio" name="s_scope" value="all" id="s_scope_all" onclick="rcmail.set_searchscope(this.value)" /> <span><roundcube:label name="allfolders" /></span></label></li>
184 </ul>
185 </div>
186diff --git a/skins/elastic/templates/mail.html b/skins/elastic/templates/mail.html
187index 51dbfcd30..4c2281281 100644
188--- a/skins/elastic/templates/mail.html
189+++ b/skins/elastic/templates/mail.html
190@@ -77,6 +77,7 @@
191 <select name="s_scope" id="s_scope">
192 <option value="base"><roundcube:label name="currentfolder" /></option>
193 <option value="sub"><roundcube:label name="subfolders" /></option>
194+ <option value="allsubscribed"><roundcube:label name="allsubscribedfolders" /></option>
195 <option value="all"><roundcube:label name="allfolders" /></option>
196 </select>
197 </div>
198diff --git a/skins/larry/templates/mail.html b/skins/larry/templates/mail.html
199index 5ef0bc211..e0e8280ad 100644
200--- a/skins/larry/templates/mail.html
201+++ b/skins/larry/templates/mail.html
202@@ -56,6 +56,7 @@
203 <li role="separator" class="separator"><label><roundcube:label name="searchscope" /></label></li>
204 <li role="menuitem"><label><input type="radio" name="s_scope" value="base" id="s_scope_base" onclick="UI.set_searchscope(this)" /> <span><roundcube:label name="currentfolder" /></span></label></li>
205 <li role="menuitem"><label><input type="radio" name="s_scope" value="sub" id="s_scope_sub" onclick="UI.set_searchscope(this)" /> <span><roundcube:label name="subfolders" /></span></label></li>
206+ <li role="menuitem"><label><input type="radio" name="s_scope" value="allsubscribed" id="s_scope_allsubscribed" onclick="UI.set_searchscope(this)" /> <span><roundcube:label name="allsubscribedfolders" /></span></label></li>
207 <li role="menuitem"><label><input type="radio" name="s_scope" value="all" id="s_scope_all" onclick="UI.set_searchscope(this)" /> <span><roundcube:label name="allfolders" /></span></label></li>
208 </ul>
209 <div class="buttons"><a class="button" href="#" onclick="if (rcmail.command('search')) UI.show_popup('searchmenu',false)"><roundcube:label name="search" /></a></div>
diff --git a/flakes/mypackages/pkgs/webapps/roundcubemail/default.nix b/flakes/mypackages/pkgs/webapps/roundcubemail/default.nix
new file mode 100644
index 0000000..bdddf2f
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/roundcubemail/default.nix
@@ -0,0 +1,85 @@
1{ varDir ? "/var/lib/roundcubemail"
2, roundcube_config ? "/etc/roundcube/config.php"
3, stdenv, fetchurl, jre, unzip, lib, callPackage }:
4let
5 defaultInstall = ''
6 mkdir -p $out
7 cp -R . $out/
8 cd $out
9 if [ -d skins -a -d skins/larry -a ! -d skins/elastic ]; then
10 ln -s larry skins/elastic
11 fi
12 '';
13 buildPlugin = { appName, version, url, sha256, installPhase ? defaultInstall }:
14 stdenv.mkDerivation rec {
15 name = "roundcube-${appName}-${version}";
16 inherit version;
17 phases = "unpackPhase installPhase";
18 inherit installPhase;
19 src = fetchurl { inherit url sha256; };
20 passthru.pluginName = appName;
21 };
22 skinNames = [];
23 allSkins = lib.attrsets.genAttrs skinNames
24 (name: callPackage (./skins + "/${name}") {});
25 pluginNames = [
26 "automatic_addressbook" "carddav" "contextmenu"
27 "contextmenu_folder" "html5_notifier" "ident_switch"
28 "message_highlight" "thunderbird_labels"
29 ];
30 allPlugins = lib.attrsets.genAttrs pluginNames
31 (name: callPackage (./plugins + "/${name}") { inherit buildPlugin; });
32 toPassthru = pkg: plugins: skins: {
33 inherit plugins skins allSkins allPlugins;
34 withSkins = withSkins pkg;
35 withPlugins = withPlugins pkg;
36 };
37 withPlugins = pkg: toPlugins:
38 let
39 plugins = toPlugins allPlugins;
40 toInstallPlugin = n: "ln -s ${n} $out/plugins/${n.pluginName}";
41 newRoundcube = pkg.overrideAttrs(old: {
42 installPhase = old.installPhase + "\n" + builtins.concatStringsSep "\n" (map toInstallPlugin plugins);
43 passthru = toPassthru newRoundcube (pkg.plugins ++ plugins) pkg.skins;
44 });
45 in newRoundcube;
46 withSkins = pkg: toSkins:
47 let
48 skins = toSkins allSkins;
49 toInstallSkin = n: "ln -s ${n} $out/skins/${n.skinName}";
50 newRoundcube = pkg.overrideAttrs(old: {
51 installPhase = old.installPhase + "\n" + builtins.concatStringsSep "\n" (map toInstallSkin skins);
52 passthru = toPassthru newRoundcube pkg.plugins (pkg.skins ++ skins);
53 });
54 in newRoundcube;
55 shrinker = fetchurl {
56 url = "https://dl.google.com/closure-compiler/compiler-20200719.zip";
57 sha256 = "0j46y9ack2yq67naca6nfysbmyilwjlkl29dbswidf1lq09yhhj3";
58 };
59 package = stdenv.mkDerivation rec {
60 version = "1.4.4";
61 name = "roundcubemail-${version}";
62 src= fetchurl {
63 url = "https://github.com/roundcube/roundcubemail/releases/download/${version}/${name}-complete.tar.gz";
64 sha256 = "1my726p0wmsn21nbdsjx02h6hnbh8nidzipzdy0gk0qgda1j729b";
65 };
66 patches = [ ./add_all.patch ]; # This patch includes js modification which requires to re-run the jsshrink below
67 buildInputs = [ unzip jre ];
68 buildPhase = ''
69 mkdir -p /tmp
70 unzip -p "${shrinker}" "*.jar" > "/tmp/compiler.jar"
71 ./bin/jsshrink.sh
72 sed -i \
73 -e "s|RCUBE_INSTALL_PATH . 'temp.*|'${varDir}/cache';|" \
74 config/defaults.inc.php
75 sed -i \
76 -e "s|RCUBE_INSTALL_PATH . 'logs.*|'${varDir}/logs';|" \
77 config/defaults.inc.php
78 '';
79 installPhase = ''
80 cp -a . $out
81 ln -s ${roundcube_config} $out/config/config.inc.php
82 '';
83 passthru = toPassthru package [] [];
84 };
85in package
diff --git a/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/automatic_addressbook/default.nix b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/automatic_addressbook/default.nix
new file mode 100644
index 0000000..cd9efee
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/automatic_addressbook/default.nix
@@ -0,0 +1,7 @@
1{ buildPlugin }:
2buildPlugin rec {
3 appName = "automatic_addressbook";
4 version = "0.4.3";
5 url = "https://github.com/sblaisot/${appName}/archive/${version}.tar.gz";
6 sha256 = "0bx5qjzp3a3wc72fr295bvgsy5n15949c041hq76n6c7sqdn7inc";
7}
diff --git a/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/carddav/default.nix b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/carddav/default.nix
new file mode 100644
index 0000000..ad6856b
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/carddav/default.nix
@@ -0,0 +1,7 @@
1{ buildPlugin }:
2buildPlugin rec {
3 appName = "carddav";
4 version = "3.0.3";
5 url = "https://github.com/blind-coder/rcmcarddav/releases/download/v${version}/${appName}-${version}.tar.bz2";
6 sha256 = "0cf5rnqkhhag2vdy808zfpr4l5586fn43nvcia8ac1ha58azrxal";
7}
diff --git a/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/contextmenu/default.nix b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/contextmenu/default.nix
new file mode 100644
index 0000000..34a43a7
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/contextmenu/default.nix
@@ -0,0 +1,7 @@
1{ buildPlugin }:
2buildPlugin rec {
3 appName = "contextmenu";
4 version = "3.2";
5 url = "https://github.com/johndoh/roundcube-${appName}/archive/${version}.tar.gz";
6 sha256 = "1j7qns42bvgwav8d5n8g16iajyrhydd76hgil8625f3xyjbv4mx0";
7}
diff --git a/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/contextmenu_folder/default.nix b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/contextmenu_folder/default.nix
new file mode 100644
index 0000000..e5cb46d
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/contextmenu_folder/default.nix
@@ -0,0 +1,7 @@
1{ buildPlugin }:
2buildPlugin rec {
3 appName = "contextmenu_folder";
4 version = "1.3.3";
5 url = "https://github.com/random-cuber/${appName}/archive/${version}.tar.gz";
6 sha256 = "1ngfws1v8qrpa52rjh7kirc98alchk2vbqwra86h00agyjjlcc57";
7}
diff --git a/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/html5_notifier/default.nix b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/html5_notifier/default.nix
new file mode 100644
index 0000000..a5788b3
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/html5_notifier/default.nix
@@ -0,0 +1,7 @@
1{ buildPlugin }:
2buildPlugin rec {
3 appName = "html5_notifier";
4 version = "v0.6.4";
5 url = "https://github.com/stremlau/${appName}/archive/${version}.tar.gz";
6 sha256 = "1w6xkffgxwbahi7acixdh5sgjvsjlfwdq942gkvc64byk8r3bhsj";
7}
diff --git a/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/ident_switch/default.nix b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/ident_switch/default.nix
new file mode 100644
index 0000000..3e10fee
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/ident_switch/default.nix
@@ -0,0 +1,7 @@
1{ buildPlugin }:
2buildPlugin rec {
3 appName = "ident_switch";
4 version = "4.2";
5 url = "https://bitbucket.org/BoresExpress/${appName}/get/${version}.tar.gz";
6 sha256 = "0rf2krjsnly4i0mzgsbx09xckr3p9a9dzxf8qq4lkyng1a7dvjkq";
7}
diff --git a/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/message_highlight/default.nix b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/message_highlight/default.nix
new file mode 100644
index 0000000..dc7138a
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/message_highlight/default.nix
@@ -0,0 +1,7 @@
1{ buildPlugin }:
2buildPlugin rec {
3 appName = "message_highlight";
4 version = "4.4";
5 url = "https://github.com/corbosman/${appName}/archive/${version}.tar.gz";
6 sha256 = "12c4x47y70xdl5pgm8csh5i4yiyhpi232lvjbixmca6di4lkhh9j";
7}
diff --git a/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/thunderbird_labels/default.nix b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/thunderbird_labels/default.nix
new file mode 100644
index 0000000..b67f16a
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/roundcubemail/plugins/thunderbird_labels/default.nix
@@ -0,0 +1,7 @@
1{ buildPlugin }:
2buildPlugin rec {
3 appName = "thunderbird_labels";
4 version = "v1.4.2";
5 url = "https://github.com/mike-kfed/roundcube-${appName}/archive/${version}.tar.gz";
6 sha256 = "00dqqlq6m8a6dwynp6gwfimc10anbs8kh0qdy8xvq2l06hk6jxyc";
7}
diff --git a/flakes/mypackages/pkgs/webapps/spip/default.nix b/flakes/mypackages/pkgs/webapps/spip/default.nix
new file mode 100644
index 0000000..20d5c8c
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/spip/default.nix
@@ -0,0 +1,32 @@
1{ siteName ? "spip"
2, siteDir ? runCommand "empty" { preferLocalBuild = true; } "mkdir -p $out"
3, environment ? "prod"
4, ldap ? false
5, varDir ? "/var/lib/${siteName}_${environment}"
6, lib, fetchzip, runCommand, stdenv }:
7let
8 app = stdenv.mkDerivation rec {
9 name = "${siteName}-${environment}-spip-${version}";
10 version = "3.2.7";
11 src = fetchzip {
12 url = "https://files.spip.net/spip/archives/SPIP-v${version}.zip";
13 sha256 = "0n4kc95nhn524zbb11bpfjs965pm4v026s3m3q44pl8nyms91r33";
14 };
15 paches = lib.optionals ldap [ ./spip_ldap_patch.patch ];
16 buildPhase = ''
17 rm -rf IMG local tmp config/remove.txt
18 ln -sf ${./spip_mes_options.php} config/mes_options.php
19 echo "Require all denied" > "config/.htaccess"
20 ln -sf ${varDir}/{IMG,local} .
21 '';
22 installPhase = ''
23 cp -a . $out
24 cp -a ${siteDir}/* $out
25 '';
26 passthru = {
27 inherit siteName siteDir environment varDir;
28 webRoot = app;
29 spipConfig = ./spip_mes_options.php;
30 };
31 };
32in app
diff --git a/flakes/mypackages/pkgs/webapps/spip/spip_ldap_patch.patch b/flakes/mypackages/pkgs/webapps/spip/spip_ldap_patch.patch
new file mode 100644
index 0000000..653c909
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/spip/spip_ldap_patch.patch
@@ -0,0 +1,60 @@
1--- old/ecrire/auth/ldap.php 2017-06-08 21:58:17.000000000 +0200
2+++ new/ecrire/auth/ldap.php 2017-06-10 02:54:02.687954143 +0200
3@@ -171,24 +171,41 @@
4 $desc = isset($ldap['attributes']) && $ldap['attributes'] ? $ldap['attributes'] : $GLOBALS['ldap_attributes'] ;
5
6 $logins = is_array($desc['login']) ? $desc['login'] : array($desc['login']);
7+ if (isset($GLOBALS['ldap_search'])) {
8+ $search_query = str_replace("%user%", $login_search, $GLOBALS['ldap_search']);
9+ $result = @ldap_search($ldap_link, $ldap_base, $search_query, array("dn"));
10+ $info = @ldap_get_entries($ldap_link, $result);
11+ // Ne pas accepter les resultats si plus d'une entree
12+ // (on veut un attribut unique)
13
14- // Tenter une recherche pour essayer de retrouver le DN
15- foreach ($logins as $att) {
16- $result = @ldap_search($ldap_link, $ldap_base, "$att=$login_search", array("dn"));
17- $info = @ldap_get_entries($ldap_link, $result);
18- // Ne pas accepter les resultats si plus d'une entree
19- // (on veut un attribut unique)
20+ if (is_array($info) and $info['count'] == 1) {
21+ $dn = $info[0]['dn'];
22+ if (!$checkpass) {
23+ return $dn;
24+ }
25+ if (@ldap_bind($ldap_link, $dn, $pass)) {
26+ return $dn;
27+ }
28+ }
29+ } else {
30+ // Tenter une recherche pour essayer de retrouver le DN
31+ foreach ($logins as $att) {
32+ $result = @ldap_search($ldap_link, $ldap_base, "$att=$login_search", array("dn"));
33+ $info = @ldap_get_entries($ldap_link, $result);
34+ // Ne pas accepter les resultats si plus d'une entree
35+ // (on veut un attribut unique)
36
37- if (is_array($info) and $info['count'] == 1) {
38- $dn = $info[0]['dn'];
39- if (!$checkpass) {
40- return $dn;
41- }
42- if (@ldap_bind($ldap_link, $dn, $pass)) {
43- return $dn;
44- }
45- }
46- }
47+ if (is_array($info) and $info['count'] == 1) {
48+ $dn = $info[0]['dn'];
49+ if (!$checkpass) {
50+ return $dn;
51+ }
52+ if (@ldap_bind($ldap_link, $dn, $pass)) {
53+ return $dn;
54+ }
55+ }
56+ }
57+ }
58
59 if ($checkpass and !isset($dn)) {
60 // Si echec, essayer de deviner le DN
diff --git a/flakes/mypackages/pkgs/webapps/spip/spip_mes_options.php b/flakes/mypackages/pkgs/webapps/spip/spip_mes_options.php
new file mode 100644
index 0000000..8db8389
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/spip/spip_mes_options.php
@@ -0,0 +1,18 @@
1<?php // /!\ Important: There must be no blank space before &lt;?php or after ?&gt;
2// This file was inspired from the spip contrib website
3// http://www.spip.net/fr_article3811.html
4
5$config_dir = getenv('SPIP_CONFIG_DIR') . '/';
6$var_dir = getenv('SPIP_VAR_DIR') . '/';
7
8$cookie_prefix = str_replace('.', '_', getenv("SPIP_SITE"));
9$table_prefix = 'spip';
10
11spip_initialisation(
12 $config_dir,
13 _DIR_RACINE . _NOM_PERMANENTS_ACCESSIBLES,
14 $var_dir . _NOM_TEMPORAIRES_INACCESSIBLES,
15 _DIR_RACINE . _NOM_TEMPORAIRES_ACCESSIBLES
16);
17
18?>
diff --git a/flakes/mypackages/pkgs/webapps/ttrss/default.nix b/flakes/mypackages/pkgs/webapps/ttrss/default.nix
new file mode 100644
index 0000000..fa2453e
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/ttrss/default.nix
@@ -0,0 +1,37 @@
1{ ttrss_config ? "/etc/ttrss/config.php"
2, varDir ? "/var/lib/ttrss"
3, stdenv, lib, callPackage, sources }:
4let
5 pluginNames = [ "auth_ldap" "af_feedmod" "feediron" "ff_instagram" "tumblr_gdpr_ua" ];
6 allPlugins = lib.attrsets.genAttrs pluginNames
7 (name: callPackage (./plugins + "/${name}") {});
8 toPassthru = pkg: plugins: {
9 inherit plugins allPlugins;
10 withPlugins = withPlugins pkg;
11 };
12 withPlugins = pkg: toPlugins:
13 let
14 plugins = toPlugins allPlugins;
15 toInstallPlugin = n:
16 "ln -sf ${n} $out/plugins/${n.pluginName}";
17 newTtrss = pkg.overrideAttrs(old: {
18 installPhase = old.installPhase + "\n" + builtins.concatStringsSep "\n" (map toInstallPlugin plugins);
19 passthru = toPassthru newTtrss (pkg.plugins ++ plugins);
20 });
21 in newTtrss;
22 package = stdenv.mkDerivation rec {
23 pname = "tt-rss";
24 version = "${sources.tools.ttrss.shortRev}-master";
25 name = "${pname}-${version}";
26 src = sources.tools.ttrss;
27 buildPhase = ''
28 rm -rf lock feed-icons cache
29 ln -sf ${varDir}/{lock,feed-icons,cache} .
30 '';
31 installPhase = ''
32 cp -a . $out
33 ln -s ${ttrss_config} $out/config.php
34 '';
35 passthru = toPassthru package [];
36 };
37in package
diff --git a/flakes/mypackages/pkgs/webapps/ttrss/plugins/af_feedmod/default.nix b/flakes/mypackages/pkgs/webapps/ttrss/plugins/af_feedmod/default.nix
new file mode 100644
index 0000000..39f9e0e
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/ttrss/plugins/af_feedmod/default.nix
@@ -0,0 +1,18 @@
1{ patched ? false, stdenv, fetchFromGitHub, lib }:
2stdenv.mkDerivation ({
3 pname = "ttrss-af_feedmod";
4 version = "0ea2092-master";
5 src = fetchFromGitHub {
6 owner = "mbirth";
7 repo = "ttrss_plugin-af_feedmod";
8 rev = "0ea2092dd34067ecd898802cfca3570023d1ecfe";
9 sha256 = "02ibf47zcrsc2rr45wsix8gxyyf371davj8n8i0gj1zdq95klvnv";
10 fetchSubmodules = true;
11 };
12 patches = lib.optionals patched [ ./type_replace.patch ];
13 installPhase = ''
14 mkdir $out
15 cp init.php $out
16 '';
17 passthru.pluginName = "af_feedmod";
18})
diff --git a/flakes/mypackages/pkgs/webapps/ttrss/plugins/af_feedmod/type_replace.patch b/flakes/mypackages/pkgs/webapps/ttrss/plugins/af_feedmod/type_replace.patch
new file mode 100644
index 0000000..d622577
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/ttrss/plugins/af_feedmod/type_replace.patch
@@ -0,0 +1,12 @@
1--- a/init.php 2014-06-16 14:21:06.995480038 +0200
2+++ b/init.php 2014-06-16 14:22:00.151027654 +0200
3@@ -147,6 +147,9 @@
4 }
5 }
6 break;
7+ case 'replace':
8+ $article['content'] = preg_replace("/".$config['pattern']."/",$config['replacement'],$article['content']);
9+ break;
10
11 default:
12 // unknown type or invalid config
diff --git a/flakes/mypackages/pkgs/webapps/ttrss/plugins/auth_ldap/default.nix b/flakes/mypackages/pkgs/webapps/ttrss/plugins/auth_ldap/default.nix
new file mode 100644
index 0000000..d283160
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/ttrss/plugins/auth_ldap/default.nix
@@ -0,0 +1,17 @@
1{ stdenv, fetchFromGitHub }:
2stdenv.mkDerivation ({
3 pname = "ttrss-auth-ldap";
4 version = "4d751b0-master";
5 src = fetchFromGitHub {
6 owner = "hydrian";
7 repo = "TTRSS-Auth-LDAP";
8 rev = "4d751b095c29a8dbe2dc7bb07777742956136e94";
9 sha256 = "0b9fl86acrzpcv41r7pj3bl8b3n72hpkdywzx9zjyfqv5pskxyim";
10 fetchSubmodules = true;
11 };
12 installPhase = ''
13 mkdir $out
14 cp plugins/auth_ldap/init.php $out
15 '';
16 passthru.pluginName = "auth_ldap";
17})
diff --git a/flakes/mypackages/pkgs/webapps/ttrss/plugins/feediron/default.nix b/flakes/mypackages/pkgs/webapps/ttrss/plugins/feediron/default.nix
new file mode 100644
index 0000000..2f86416
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/ttrss/plugins/feediron/default.nix
@@ -0,0 +1,18 @@
1{ patched ? false, stdenv, fetchFromGitHub, lib }:
2stdenv.mkDerivation ({
3 pname = "ttrss-feediron";
4 version = "407168c-master";
5 src = fetchFromGitHub {
6 owner = "m42e";
7 repo = "ttrss_plugin-feediron";
8 rev = "407168c628880b5ced572cc549db6d50e866d3c8";
9 sha256 = "17b95ifpcph6m03hjd1mhi8gi1hw9yd3fnffmw66fqr5c9l3zd9r";
10 fetchSubmodules = true;
11 };
12 patches = lib.optionals patched [ ./json_reformat.patch ];
13 installPhase = ''
14 mkdir $out
15 cp -a . $out
16 '';
17 passthru.pluginName = "feediron";
18})
diff --git a/flakes/mypackages/pkgs/webapps/ttrss/plugins/feediron/json_reformat.patch b/flakes/mypackages/pkgs/webapps/ttrss/plugins/feediron/json_reformat.patch
new file mode 100644
index 0000000..e1c44d9
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/ttrss/plugins/feediron/json_reformat.patch
@@ -0,0 +1,18 @@
1diff --git a/init.php b/init.php
2index 3c0f2f9..1aad146 100644
3--- a/init.php
4+++ b/init.php
5@@ -600,10 +600,11 @@ class Feediron extends Plugin implements IHandler
6 return false;
7 }
8
9- $this->host->set($this, 'json_conf', Feediron_Json::format($json_conf));
10+ $new_conf = json_encode(json_decode($json_conf), JSON_PRETTY_PRINT);
11+ $this->host->set($this, 'json_conf', $new_conf);
12 $json_reply['success'] = true;
13 $json_reply['message'] = __('Configuration saved.');
14- $json_reply['json_conf'] = Feediron_Json::format($json_conf);
15+ $json_reply['json_conf'] = $new_conf;
16 echo json_encode($json_reply);
17 }
18
diff --git a/flakes/mypackages/pkgs/webapps/ttrss/plugins/ff_instagram/default.nix b/flakes/mypackages/pkgs/webapps/ttrss/plugins/ff_instagram/default.nix
new file mode 100644
index 0000000..f0df588
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/ttrss/plugins/ff_instagram/default.nix
@@ -0,0 +1,17 @@
1{ stdenv, fetchFromGitHub }:
2stdenv.mkDerivation ({
3 pname = "ttrss-ff_instagram";
4 version = "0366ffb-master";
5 src = fetchFromGitHub {
6 owner = "wltb";
7 repo = "ff_instagram";
8 rev = "0366ffb18c4d490c8fbfba2f5f3367a5af23cfe8";
9 sha256 = "0vvzl6wi6jmrqknsfddvckjgsgfizz1d923d1nyrpzjfn6bda1vk";
10 fetchSubmodules = true;
11 };
12 installPhase = ''
13 mkdir $out
14 cp -a . $out
15 '';
16 passthru.pluginName = "ff_instagram";
17})
diff --git a/flakes/mypackages/pkgs/webapps/ttrss/plugins/tumblr_gdpr_ua/default.nix b/flakes/mypackages/pkgs/webapps/ttrss/plugins/tumblr_gdpr_ua/default.nix
new file mode 100644
index 0000000..072b6c3
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/ttrss/plugins/tumblr_gdpr_ua/default.nix
@@ -0,0 +1,17 @@
1{ stdenv, fetchFromGitHub }:
2stdenv.mkDerivation ({
3 pname = "ttrss-tumblr_gdpr_ua";
4 version = "287c584-master";
5 src = fetchFromGitHub {
6 owner = "hkockerbeck";
7 repo = "ttrss-tumblr-gdpr-ua";
8 rev = "287c584e68845d524f920156bff0b2eaa6f65117";
9 sha256 = "1fviawgcclqky4k4xv1sqzvpb8i74w9f0pclm09m78s8l85wh9py";
10 fetchSubmodules = true;
11 };
12 installPhase = ''
13 mkdir $out
14 cp -a . $out
15 '';
16 passthru.pluginName = "tumblr_gdpr_ua";
17})
diff --git a/flakes/mypackages/pkgs/webapps/wallabag/default.nix b/flakes/mypackages/pkgs/webapps/wallabag/default.nix
new file mode 100644
index 0000000..bd420d4
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/wallabag/default.nix
@@ -0,0 +1,54 @@
1{ varDir ? "/var/lib/wallabag"
2, wallabag_config ? "/etc/wallabag/parameters.yml"
3, ldap ? false
4, composerEnv, fetchurl, lib }:
5composerEnv.buildPackage rec {
6 packages = {
7 "fr3d/ldap-bundle" = {
8 targetDir = "";
9 src = composerEnv.buildZipPackage {
10 name = "fr3d-ldap-bundle-5a8927c11af45fa06331b97221c6da1a4a237475";
11 src = fetchurl {
12 url = https://api.github.com/repos/Maks3w/FR3DLdapBundle/zipball/5a8927c11af45fa06331b97221c6da1a4a237475;
13 sha256 = "168zkd82j200wd6h0a3lq81g5s2pifg889rv27q2g429nppsbfxc";
14 };
15 };
16 };
17 "zendframework/zend-ldap" = {
18 targetDir = "";
19 src = composerEnv.buildZipPackage {
20 name = "zendframework-zend-ldap-b63c7884a08d3a6bda60ebcf7d6238cf8ad89f49";
21 src = fetchurl {
22 url = https://api.github.com/repos/zendframework/zend-ldap/zipball/b63c7884a08d3a6bda60ebcf7d6238cf8ad89f49;
23 sha256 = "0mn4yqnb5prqhrbbybmw1i2rx7xf4s4wagbdq9qi55fa0vk3jgw9";
24 };
25 };
26 };
27 };
28 noDev = true;
29 doRemoveVendor = false;
30 # Beware when upgrading, I probably messed up with the migrations table
31 # (due to a psql bug in wallabag)
32 version = "2.3.8";
33 name = "wallabag-${version}";
34 src = fetchurl {
35 url = "https://static.wallabag.org/releases/wallabag-release-${version}.tar.gz";
36 sha256 = "1sr62hfk2f2rl5by48dg8yd1gchngjnc850as17wr3w287p1kwsq";
37 };
38 unpackPhase = ''
39 unpackFile "$src"
40 sourceRoot=${version}
41 src=$PWD/${version}
42 '';
43 patches = lib.optionals ldap [ ./ldap.patch ];
44 preInstall = ''
45 export SYMFONY_ENV="prod"
46 '';
47 postInstall = ''
48 rm -rf web/assets var/{cache,logs,sessions} app/config/parameters.yml data
49 ln -sf ${wallabag_config} app/config/parameters.yml
50 ln -sf ${varDir}/var/{cache,logs,sessions} var
51 ln -sf ${varDir}/data data
52 ln -sf ${varDir}/assets web/assets
53 '';
54}
diff --git a/flakes/mypackages/pkgs/webapps/wallabag/ldap.patch b/flakes/mypackages/pkgs/webapps/wallabag/ldap.patch
new file mode 100644
index 0000000..e04dae1
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/wallabag/ldap.patch
@@ -0,0 +1,664 @@
1diff --git a/.travis.yml b/.travis.yml
2index 04cea258..56b1f576 100644
3--- a/.travis.yml
4+++ b/.travis.yml
5@@ -58,6 +58,7 @@ install:
6
7 before_script:
8 - PHP=$TRAVIS_PHP_VERSION
9+ - echo "extension=ldap.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
10 - if [[ ! $PHP = hhvm* ]]; then echo "memory_limit=-1" >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini; fi;
11 # xdebug isn't enable for PHP 7.1
12 - if [[ ! $PHP = hhvm* ]]; then phpenv config-rm xdebug.ini || echo "xdebug not available"; fi
13diff --git a/app/AppKernel.php b/app/AppKernel.php
14index 40726f05..c4f465dc 100644
15--- a/app/AppKernel.php
16+++ b/app/AppKernel.php
17@@ -42,6 +42,10 @@ class AppKernel extends Kernel
18 new OldSound\RabbitMqBundle\OldSoundRabbitMqBundle(),
19 ];
20
21+ if (class_exists('FR3D\\LdapBundle\\FR3DLdapBundle')) {
22+ $bundles[] = new FR3D\LdapBundle\FR3DLdapBundle();
23+ }
24+
25 if (in_array($this->getEnvironment(), ['dev', 'test'], true)) {
26 $bundles[] = new Symfony\Bundle\DebugBundle\DebugBundle();
27 $bundles[] = new Symfony\Bundle\WebProfilerBundle\WebProfilerBundle();
28diff --git a/app/DoctrineMigrations/Version20170710113900.php b/app/DoctrineMigrations/Version20170710113900.php
29new file mode 100644
30index 00000000..7be83110
31--- /dev/null
32+++ b/app/DoctrineMigrations/Version20170710113900.php
33@@ -0,0 +1,54 @@
34+<?php
35+
36+namespace Application\Migrations;
37+
38+use Doctrine\DBAL\Migrations\AbstractMigration;
39+use Doctrine\DBAL\Schema\Schema;
40+use Symfony\Component\DependencyInjection\ContainerAwareInterface;
41+use Symfony\Component\DependencyInjection\ContainerInterface;
42+
43+/**
44+ * Added dn field on wallabag_users
45+ */
46+class Version20170710113900 extends AbstractMigration implements ContainerAwareInterface
47+{
48+ /**
49+ * @var ContainerInterface
50+ */
51+ private $container;
52+
53+ public function setContainer(ContainerInterface $container = null)
54+ {
55+ $this->container = $container;
56+ }
57+
58+ private function getTable($tableName)
59+ {
60+ return $this->container->getParameter('database_table_prefix').$tableName;
61+ }
62+
63+ /**
64+ * @param Schema $schema
65+ */
66+ public function up(Schema $schema)
67+ {
68+ $usersTable = $schema->getTable($this->getTable('user'));
69+
70+ $this->skipIf($usersTable->hasColumn('dn'), 'It seems that you already played this migration.');
71+
72+ $usersTable->addColumn('dn', 'text', [
73+ 'default' => null,
74+ 'notnull' => false,
75+ ]);
76+ }
77+
78+ /**
79+ * @param Schema $schema
80+ */
81+ public function down(Schema $schema)
82+ {
83+ $usersTable = $schema->getTable($this->getTable('user'));
84+ $usersTable->dropColumn('dn');
85+ }
86+}
87+
88diff --git a/app/config/parameters.yml.dist b/app/config/parameters.yml.dist
89index 6b0cb8e8..cfd41b69 100644
90--- a/app/config/parameters.yml.dist
91+++ b/app/config/parameters.yml.dist
92@@ -62,3 +62,23 @@ parameters:
93 redis_port: 6379
94 redis_path: null
95 redis_password: null
96+
97+ # ldap configuration
98+ # To enable, you need to require fr3d/ldap-bundle
99+ ldap_enabled: false
100+ ldap_host: localhost
101+ ldap_port: 389
102+ ldap_tls: false
103+ ldap_ssl: false
104+ ldap_bind_requires_dn: true
105+ ldap_base: dc=example,dc=com
106+ ldap_manager_dn: ou=Manager,dc=example,dc=com
107+ ldap_manager_pw: password
108+ ldap_filter: (&(ObjectClass=Person))
109+ # optional (if null: no ldap user is admin)
110+ ldap_admin_filter: (&(memberOf=ou=admins,dc=example,dc=com)(uid=%s))
111+ ldap_username_attribute: uid
112+ ldap_email_attribute: mail
113+ ldap_name_attribute: cn
114+ # optional (default sets user as enabled unconditionally)
115+ ldap_enabled_attribute: ~
116diff --git a/app/config/security.yml b/app/config/security.yml
117index 02afc9ea..48fbb553 100644
118--- a/app/config/security.yml
119+++ b/app/config/security.yml
120@@ -6,6 +6,7 @@ security:
121 ROLE_ADMIN: ROLE_USER
122 ROLE_SUPER_ADMIN: [ ROLE_USER, ROLE_ADMIN, ROLE_ALLOWED_TO_SWITCH ]
123
124+ # /!\ This list is modified in WallabagUserBundle when LDAP is enabled
125 providers:
126 administrators:
127 entity:
128@@ -36,6 +37,7 @@ security:
129 pattern: ^/login$
130 anonymous: ~
131
132+ # /!\ This section is modified in WallabagUserBundle when LDAP is enabled
133 secured_area:
134 pattern: ^/
135 form_login:
136diff --git a/composer.json b/composer.json
137index 0483da1d..e3e47bdc 100644
138--- a/composer.json
139+++ b/composer.json
140@@ -87,7 +87,11 @@
141 "bdunogier/guzzle-site-authenticator": "^1.0.0",
142 "defuse/php-encryption": "^2.1",
143 "html2text/html2text": "^4.1",
144- "sulu/symfony-intl-fix": "^1.0"
145+ "sulu/symfony-intl-fix": "^1.0",
146+ "fr3d/ldap-bundle": "^3.0"
147+ },
148+ "suggest": {
149+ "fr3d/ldap-bundle": "If you want to authenticate via LDAP"
150 },
151 "require-dev": {
152 "doctrine/doctrine-fixtures-bundle": "~2.2",
153diff --git a/composer.lock b/composer.lock
154index b3b0a4c6..8c8a87ee 100644
155--- a/composer.lock
156+++ b/composer.lock
157@@ -1346,6 +1346,65 @@
158 ],
159 "time": "2019-05-09T11:53:40+00:00"
160 },
161+ {
162+ "name": "fr3d/ldap-bundle",
163+ "version": "v3.0.0",
164+ "source": {
165+ "type": "git",
166+ "url": "https://github.com/Maks3w/FR3DLdapBundle.git",
167+ "reference": "5a8927c11af45fa06331b97221c6da1a4a237475"
168+ },
169+ "dist": {
170+ "type": "zip",
171+ "url": "https://api.github.com/repos/Maks3w/FR3DLdapBundle/zipball/5a8927c11af45fa06331b97221c6da1a4a237475",
172+ "reference": "5a8927c11af45fa06331b97221c6da1a4a237475",
173+ "shasum": ""
174+ },
175+ "require": {
176+ "php": ">=5.5",
177+ "psr/log": "~1.0",
178+ "symfony/config": "2.3 - 3",
179+ "symfony/dependency-injection": "2.3 - 3",
180+ "symfony/polyfill-php56": "^1.1",
181+ "symfony/security": "2.3 - 3",
182+ "symfony/security-bundle": "2.3 - 3",
183+ "zendframework/zend-ldap": "2.5 - 3"
184+ },
185+ "require-dev": {
186+ "fabpot/php-cs-fixer": "1.11.*",
187+ "fr3d/psr3-message-assertions": "0.1.*",
188+ "friendsofsymfony/user-bundle": "~1.3",
189+ "maks3w/phpunit-methods-trait": "^4.6",
190+ "phpunit/phpunit": "^4.6",
191+ "symfony/validator": "2.3 - 3"
192+ },
193+ "suggest": {
194+ "friendsofsymfony/user-bundle": "Integrate authentication and management for DB users, useful for unmanned LDAP servers",
195+ "symfony/validator": "Allow pre-validate for existing users before register new ones"
196+ },
197+ "type": "symfony-bundle",
198+ "autoload": {
199+ "psr-4": {
200+ "FR3D\\LdapBundle\\": ""
201+ }
202+ },
203+ "notification-url": "https://packagist.org/downloads/",
204+ "license": [
205+ "MIT"
206+ ],
207+ "authors": [
208+ {
209+ "name": "Maks3w"
210+ }
211+ ],
212+ "description": "This package provide users and authentication services based on LDAP directories for Symfony2 framework",
213+ "homepage": "https://github.com/Maks3w/FR3DLdapBundle",
214+ "keywords": [
215+ "Authentication",
216+ "ldap"
217+ ],
218+ "time": "2016-02-12T17:45:14+00:00"
219+ },
220 {
221 "name": "friendsofsymfony/jsrouting-bundle",
222 "version": "1.6.3",
223@@ -7069,6 +7128,59 @@
224 "zf2"
225 ],
226 "time": "2018-04-25T15:33:34+00:00"
227+ },
228+ {
229+ "name": "zendframework/zend-ldap",
230+ "version": "2.10.0",
231+ "source": {
232+ "type": "git",
233+ "url": "https://github.com/zendframework/zend-ldap.git",
234+ "reference": "b63c7884a08d3a6bda60ebcf7d6238cf8ad89f49"
235+ },
236+ "dist": {
237+ "type": "zip",
238+ "url": "https://api.github.com/repos/zendframework/zend-ldap/zipball/b63c7884a08d3a6bda60ebcf7d6238cf8ad89f49",
239+ "reference": "b63c7884a08d3a6bda60ebcf7d6238cf8ad89f49",
240+ "shasum": ""
241+ },
242+ "require": {
243+ "ext-ldap": "*",
244+ "php": "^5.6 || ^7.0"
245+ },
246+ "require-dev": {
247+ "php-mock/php-mock-phpunit": "^1.1.2 || ^2.1.1",
248+ "phpunit/phpunit": "^5.7.27 || ^6.5.8 || ^7.1.2",
249+ "zendframework/zend-coding-standard": "~1.0.0",
250+ "zendframework/zend-config": "^2.5",
251+ "zendframework/zend-eventmanager": "^2.6.3 || ^3.0.1",
252+ "zendframework/zend-stdlib": "^2.7 || ^3.0"
253+ },
254+ "suggest": {
255+ "zendframework/zend-eventmanager": "Zend\\EventManager component"
256+ },
257+ "type": "library",
258+ "extra": {
259+ "branch-alias": {
260+ "dev-master": "2.10.x-dev",
261+ "dev-develop": "2.11.x-dev"
262+ }
263+ },
264+ "autoload": {
265+ "psr-4": {
266+ "Zend\\Ldap\\": "src/"
267+ }
268+ },
269+ "notification-url": "https://packagist.org/downloads/",
270+ "license": [
271+ "BSD-3-Clause"
272+ ],
273+ "description": "Provides support for LDAP operations including but not limited to binding, searching and modifying entries in an LDAP directory",
274+ "keywords": [
275+ "ZendFramework",
276+ "ldap",
277+ "zf"
278+ ],
279+ "time": "2018-07-05T05:05:12+00:00"
280 }
281 ],
282 "packages-dev": [
283diff --git a/scripts/install.sh b/scripts/install.sh
284index affa715f..45254212 100755
285--- a/scripts/install.sh
286+++ b/scripts/install.sh
287@@ -37,5 +37,8 @@ fi
288 TAG=$(git describe --tags $(git rev-list --tags --max-count=1))
289
290 git checkout $TAG
291+if [ -n "$LDAP_ENABLED" ]; then
292+ SYMFONY_ENV=$ENV $COMPOSER_COMMAND require --no-update fr3d/ldap-bundle
293+fi
294 SYMFONY_ENV=$ENV $COMPOSER_COMMAND install --no-dev -o --prefer-dist
295 php bin/console wallabag:install --env=$ENV
296diff --git a/scripts/update.sh b/scripts/update.sh
297index 3ef10439..eeee28d6 100755
298--- a/scripts/update.sh
299+++ b/scripts/update.sh
300@@ -42,6 +42,9 @@ git fetch origin
301 git fetch --tags
302 TAG=$(git describe --tags $(git rev-list --tags --max-count=1))
303 git checkout $TAG --force
304+if [ -n "$LDAP_ENABLED" ]; then
305+ SYMFONY_ENV=$ENV $COMPOSER_COMMAND require --no-update fr3d/ldap-bundle
306+fi
307 SYMFONY_ENV=$ENV $COMPOSER_COMMAND install --no-dev -o --prefer-dist
308 php bin/console doctrine:migrations:migrate --no-interaction --env=$ENV
309 php bin/console cache:clear --env=$ENV
310diff --git a/src/Wallabag/UserBundle/DependencyInjection/WallabagUserExtension.php b/src/Wallabag/UserBundle/DependencyInjection/WallabagUserExtension.php
311index 5ca3482e..904a6af1 100644
312--- a/src/Wallabag/UserBundle/DependencyInjection/WallabagUserExtension.php
313+++ b/src/Wallabag/UserBundle/DependencyInjection/WallabagUserExtension.php
314@@ -6,9 +6,34 @@ use Symfony\Component\Config\FileLocator;
315 use Symfony\Component\DependencyInjection\ContainerBuilder;
316 use Symfony\Component\DependencyInjection\Loader;
317 use Symfony\Component\HttpKernel\DependencyInjection\Extension;
318+use Symfony\Component\DependencyInjection\Extension\PrependExtensionInterface;
319
320-class WallabagUserExtension extends Extension
321+class WallabagUserExtension extends Extension implements PrependExtensionInterface
322 {
323+ public function prepend(ContainerBuilder $container)
324+ {
325+ $ldap = $container->getParameter('ldap_enabled');
326+
327+ if ($ldap) {
328+ $container->prependExtensionConfig('security', array(
329+ 'providers' => array(
330+ 'chain_provider' => array(),
331+ ),
332+ ));
333+ $loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config'));
334+ $loader->load('ldap.yml');
335+ } elseif ($container->hasExtension('fr3d_ldap')) {
336+ $container->prependExtensionConfig('fr3_d_ldap', array(
337+ 'driver' => array(
338+ 'host' => 'localhost',
339+ ),
340+ 'user' => array(
341+ 'baseDn' => 'dc=example,dc=com',
342+ ),
343+ ));
344+ }
345+ }
346+
347 public function load(array $configs, ContainerBuilder $container)
348 {
349 $configuration = new Configuration();
350@@ -16,6 +41,9 @@ class WallabagUserExtension extends Extension
351
352 $loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__ . '/../Resources/config'));
353 $loader->load('services.yml');
354+ if ($container->getParameter('ldap_enabled')) {
355+ $loader->load('ldap_services.yml');
356+ }
357 $container->setParameter('wallabag_user.registration_enabled', $config['registration_enabled']);
358 }
359
360diff --git a/src/Wallabag/UserBundle/Entity/User.php b/src/Wallabag/UserBundle/Entity/User.php
361index 48446e3c..f93c59c7 100644
362--- a/src/Wallabag/UserBundle/Entity/User.php
363+++ b/src/Wallabag/UserBundle/Entity/User.php
364@@ -1,5 +1,15 @@
365 <?php
366
367+// This permits to have the LdapUserInterface even when fr3d/ldap-bundle is not
368+// in the packages
369+namespace FR3D\LdapBundle\Model;
370+
371+interface LdapUserInterface
372+{
373+ public function setDn($dn);
374+ public function getDn();
375+}
376+
377 namespace Wallabag\UserBundle\Entity;
378
379 use Doctrine\Common\Collections\ArrayCollection;
380@@ -16,6 +26,7 @@ use Wallabag\ApiBundle\Entity\Client;
381 use Wallabag\CoreBundle\Entity\Config;
382 use Wallabag\CoreBundle\Entity\Entry;
383 use Wallabag\CoreBundle\Helper\EntityTimestampsTrait;
384+use FR3D\LdapBundle\Model\LdapUserInterface;
385
386 /**
387 * User.
388@@ -28,7 +39,7 @@ use Wallabag\CoreBundle\Helper\EntityTimestampsTrait;
389 * @UniqueEntity("email")
390 * @UniqueEntity("username")
391 */
392-class User extends BaseUser implements TwoFactorInterface, TrustedComputerInterface
393+class User extends BaseUser implements TwoFactorInterface, TrustedComputerInterface, LdapUserInterface
394 {
395 use EntityTimestampsTrait;
396
397@@ -67,6 +78,13 @@ class User extends BaseUser implements TwoFactorInterface, TrustedComputerInterf
398 */
399 protected $email;
400
401+ /**
402+ * @var string
403+ *
404+ * @ORM\Column(name="dn", type="text", nullable=true)
405+ */
406+ protected $dn;
407+
408 /**
409 * @var \DateTime
410 *
411@@ -309,4 +327,33 @@ class User extends BaseUser implements TwoFactorInterface, TrustedComputerInterf
412 return $this->clients->first();
413 }
414 }
415+
416+ /**
417+ * Set dn.
418+ *
419+ * @param string $dn
420+ *
421+ * @return User
422+ */
423+ public function setDn($dn)
424+ {
425+ $this->dn = $dn;
426+
427+ return $this;
428+ }
429+
430+ /**
431+ * Get dn.
432+ *
433+ * @return string
434+ */
435+ public function getDn()
436+ {
437+ return $this->dn;
438+ }
439+
440+ public function isLdapUser()
441+ {
442+ return $this->dn !== null;
443+ }
444 }
445diff --git a/src/Wallabag/UserBundle/LdapHydrator.php b/src/Wallabag/UserBundle/LdapHydrator.php
446new file mode 100644
447index 00000000..cea2450f
448--- /dev/null
449+++ b/src/Wallabag/UserBundle/LdapHydrator.php
450@@ -0,0 +1,103 @@
451+<?php
452+
453+namespace Wallabag\UserBundle;
454+
455+use FR3D\LdapBundle\Hydrator\HydratorInterface;
456+use FOS\UserBundle\FOSUserEvents;
457+use FOS\UserBundle\Event\UserEvent;
458+
459+class LdapHydrator implements HydratorInterface
460+{
461+ private $userManager;
462+ private $eventDispatcher;
463+ private $attributesMap;
464+ private $enabledAttribute;
465+ private $ldapBaseDn;
466+ private $ldapAdminFilter;
467+ private $ldapDriver;
468+
469+ public function __construct(
470+ $user_manager,
471+ $event_dispatcher,
472+ array $attributes_map,
473+ $ldap_base_dn,
474+ $ldap_admin_filter,
475+ $ldap_driver
476+ ) {
477+ $this->userManager = $user_manager;
478+ $this->eventDispatcher = $event_dispatcher;
479+
480+ $this->attributesMap = array(
481+ 'setUsername' => $attributes_map[0],
482+ 'setEmail' => $attributes_map[1],
483+ 'setName' => $attributes_map[2],
484+ );
485+ $this->enabledAttribute = $attributes_map[3];
486+
487+ $this->ldapBaseDn = $ldap_base_dn;
488+ $this->ldapAdminFilter = $ldap_admin_filter;
489+ $this->ldapDriver = $ldap_driver;
490+ }
491+
492+ public function hydrate(array $ldapEntry)
493+ {
494+ $user = $this->userManager->findUserBy(array('dn' => $ldapEntry['dn']));
495+
496+ if (!$user) {
497+ $user = $this->userManager->createUser();
498+ $user->setDn($ldapEntry['dn']);
499+ $user->setPassword('');
500+ $user->setSalt('');
501+ $this->updateUserFields($user, $ldapEntry);
502+
503+ $event = new UserEvent($user);
504+ $this->eventDispatcher->dispatch(FOSUserEvents::USER_CREATED, $event);
505+
506+ $this->userManager->reloadUser($user);
507+ } else {
508+ $this->updateUserFields($user, $ldapEntry);
509+ }
510+
511+ return $user;
512+ }
513+
514+ private function updateUserFields($user, $ldapEntry)
515+ {
516+ foreach ($this->attributesMap as $key => $value) {
517+ if (is_array($ldapEntry[$value])) {
518+ $ldap_value = $ldapEntry[$value][0];
519+ } else {
520+ $ldap_value = $ldapEntry[$value];
521+ }
522+
523+ call_user_func([$user, $key], $ldap_value);
524+ }
525+
526+ if ($this->enabledAttribute !== null) {
527+ $user->setEnabled($ldapEntry[$this->enabledAttribute]);
528+ } else {
529+ $user->setEnabled(true);
530+ }
531+
532+ if ($this->isAdmin($user)) {
533+ $user->addRole('ROLE_SUPER_ADMIN');
534+ } else {
535+ $user->removeRole('ROLE_SUPER_ADMIN');
536+ }
537+
538+ $this->userManager->updateUser($user, true);
539+ }
540+
541+ private function isAdmin($user)
542+ {
543+ if ($this->ldapAdminFilter === null) {
544+ return false;
545+ }
546+
547+ $escaped_username = ldap_escape($user->getUsername(), '', LDAP_ESCAPE_FILTER);
548+ $filter = sprintf($this->ldapAdminFilter, $escaped_username);
549+ $entries = $this->ldapDriver->search($this->ldapBaseDn, $filter);
550+
551+ return $entries['count'] == 1;
552+ }
553+}
554diff --git a/src/Wallabag/UserBundle/OAuthStorageLdapWrapper.php b/src/Wallabag/UserBundle/OAuthStorageLdapWrapper.php
555new file mode 100644
556index 00000000..8a851f12
557--- /dev/null
558+++ b/src/Wallabag/UserBundle/OAuthStorageLdapWrapper.php
559@@ -0,0 +1,43 @@
560+<?php
561+
562+namespace Wallabag\UserBundle;
563+
564+use FOS\OAuthServerBundle\Storage\OAuthStorage;
565+use OAuth2\Model\IOAuth2Client;
566+use Symfony\Component\Security\Core\Exception\AuthenticationException;
567+
568+class OAuthStorageLdapWrapper extends OAuthStorage
569+{
570+ private $ldapManager;
571+
572+ public function setLdapManager($ldap_manager)
573+ {
574+ $this->ldapManager = $ldap_manager;
575+ }
576+
577+ public function checkUserCredentials(IOAuth2Client $client, $username, $password)
578+ {
579+ try {
580+ $user = $this->userProvider->loadUserByUsername($username);
581+ } catch (AuthenticationException $e) {
582+ return false;
583+ }
584+
585+ if ($user->isLdapUser()) {
586+ return $this->checkLdapUserCredentials($user, $password);
587+ } else {
588+ return parent::checkUserCredentials($client, $username, $password);
589+ }
590+ }
591+
592+ private function checkLdapUserCredentials($user, $password)
593+ {
594+ if ($this->ldapManager->bind($user, $password)) {
595+ return array(
596+ 'data' => $user,
597+ );
598+ } else {
599+ return false;
600+ }
601+ }
602+}
603diff --git a/src/Wallabag/UserBundle/Resources/config/ldap.yml b/src/Wallabag/UserBundle/Resources/config/ldap.yml
604new file mode 100644
605index 00000000..5ec16088
606--- /dev/null
607+++ b/src/Wallabag/UserBundle/Resources/config/ldap.yml
608@@ -0,0 +1,28 @@
609+fr3d_ldap:
610+ service:
611+ user_hydrator: ldap_user_hydrator
612+ driver:
613+ host: "%ldap_host%"
614+ port: "%ldap_port%"
615+ useSsl: "%ldap_ssl%"
616+ useStartTls: "%ldap_tls%"
617+ bindRequiresDn: "%ldap_bind_requires_dn%"
618+ username: "%ldap_manager_dn%"
619+ password: "%ldap_manager_pw%"
620+ user:
621+ baseDn: "%ldap_base%"
622+ filter: "%ldap_filter%"
623+ usernameAttribute: "%ldap_username_attribute%"
624+security:
625+ providers:
626+ chain_provider:
627+ chain:
628+ providers: [ fr3d_ldapbundle, fos_userbundle ]
629+ fr3d_ldapbundle:
630+ id: fr3d_ldap.security.user.provider
631+ firewalls:
632+ secured_area:
633+ fr3d_ldap: ~
634+ form_login:
635+ provider: chain_provider
636+
637diff --git a/src/Wallabag/UserBundle/Resources/config/ldap_services.yml b/src/Wallabag/UserBundle/Resources/config/ldap_services.yml
638new file mode 100644
639index 00000000..b3e3fd8a
640--- /dev/null
641+++ b/src/Wallabag/UserBundle/Resources/config/ldap_services.yml
642@@ -0,0 +1,22 @@
643+services:
644+ fos_oauth_server.server:
645+ class: OAuth2\OAuth2
646+ arguments:
647+ - "@oauth_storage_ldap_wrapper"
648+ - "%fos_oauth_server.server.options%"
649+ oauth_storage_ldap_wrapper:
650+ class: Wallabag\UserBundle\OAuthStorageLdapWrapper
651+ parent: fos_oauth_server.storage
652+ calls:
653+ - [setLdapManager, ["@fr3d_ldap.ldap_manager"]]
654+
655+ ldap_user_hydrator:
656+ class: Wallabag\UserBundle\LdapHydrator
657+ arguments:
658+ - "@fos_user.user_manager"
659+ - "@event_dispatcher"
660+ - [ "%ldap_username_attribute%", "%ldap_email_attribute%", "%ldap_name_attribute%", "%ldap_enabled_attribute%" ]
661+ - "%ldap_base%"
662+ - "%ldap_admin_filter%"
663+ - "@fr3d_ldap.ldap_driver"
664+
diff --git a/flakes/mypackages/pkgs/webapps/yourls/default.nix b/flakes/mypackages/pkgs/webapps/yourls/default.nix
new file mode 100644
index 0000000..8001a60
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/yourls/default.nix
@@ -0,0 +1,37 @@
1{ yourls_config ? "/etc/yourls/config.php", fetchFromGitHub, callPackage, lib, stdenv }:
2let
3 pluginNames = [ "ldap" ];
4 allPlugins = lib.attrsets.genAttrs pluginNames
5 (name: callPackage (./plugins + "/${name}") {});
6 toPassthru = pkg: plugins: {
7 inherit plugins allPlugins;
8 withPlugins = withPlugins pkg;
9 };
10 withPlugins = pkg: toPlugins:
11 let
12 plugins = toPlugins allPlugins;
13 toInstallPlugin = n: "ln -s ${n} $out/user/plugins/${n.pluginName}";
14 newYourls = pkg.overrideAttrs(old: {
15 installPhase = old.installPhase + "\n" + builtins.concatStringsSep "\n" (map toInstallPlugin plugins);
16 passthru = toPassthru newYourls (pkg.plugins ++ plugins);
17 });
18 in newYourls;
19 package = stdenv.mkDerivation (rec {
20 pname = "yourls";
21 version = "1.7.3";
22 src = fetchFromGitHub {
23 owner = "YOURLS";
24 repo = "YOURLS";
25 rev = "077018822d3594229daa8343310d0b40804b9ddc";
26 sha256 = "1av6h619rwqn0yn0kjn2s2h3gmrhmxaaa9hd5ns4ralxgg731imd";
27 fetchSubmodules = true;
28 };
29 installPhase = ''
30 mkdir -p $out
31 cp -a */ *.php $out/
32 cp sample-robots.txt $out/robots.txt
33 ln -sf ${yourls_config} $out/includes/config.php
34 '';
35 passthru = toPassthru package [];
36 });
37in package
diff --git a/flakes/mypackages/pkgs/webapps/yourls/plugins/ldap/default.nix b/flakes/mypackages/pkgs/webapps/yourls/plugins/ldap/default.nix
new file mode 100644
index 0000000..5870faa
--- /dev/null
+++ b/flakes/mypackages/pkgs/webapps/yourls/plugins/ldap/default.nix
@@ -0,0 +1,17 @@
1{ stdenv, fetchFromGitHub }:
2stdenv.mkDerivation (rec {
3 pname = "yourls-ldap-plugin";
4 version = "2a3cb03-master";
5 src = fetchFromGitHub {
6 owner = "k3a";
7 repo = "yourls-ldap-plugin";
8 rev = "2a3cb0334b8a6b81b284a7196e614bbd2b2b1615";
9 sha256 = "0cchbnli77d295lzf7kjmn4dcxj2bmdqa9qc3f8l8qgmp4n5n0gh";
10 fetchSubmodules = true;
11 };
12 installPhase = ''
13 mkdir -p $out
14 cp plugin.php $out
15 '';
16 passthru.pluginName = "ldap";
17})