├── .gitignore ├── Dockerfile ├── LICENSE ├── Makefile ├── README.md ├── RELEASE.md ├── media ├── digikam-setup-db.png ├── digikam-setup-faces.png ├── digikam-setup-images.png └── digikam_oxygen.svg ├── migrate_to_ls ├── migration.md ├── patches └── docker-baseimage-gui.3077e2c.patch └── startapp.sh /.gitignore: -------------------------------------------------------------------------------- 1 | digikam-build 2 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM jlesage/baseimage-gui:ubuntu-20.04 2 | ARG digikam_version=unknown 3 | 4 | ENV APP_NAME=$digikam_version \ 5 | USER_ID=1000 \ 6 | GROUP_ID=1000 \ 7 | UMASK=022 \ 8 | TZ=Etc/UTC \ 9 | KEEP_APP_RUNNING=1 \ 10 | TAKE_CONFIG_OWNERSHIP=1 \ 11 | CLEAN_TMP_DIR=1 \ 12 | DISPLAY_WIDTH=1920 \ 13 | DISPLAY_HEIGHT=1080 \ 14 | ENABLE_CJK_FONT=1 \ 15 | LANG=POSIX \ 16 | LC_ALL=POSIX \ 17 | LANGUAGE=POSIX \ 18 | FULLSCREEN=1 19 | 20 | # Install all locales for use. 21 | RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y locales locales-all 22 | 23 | # FUSE not supported in docker, pre-extract 24 | # image to squashfs-root for copying. 25 | #./digikam.appimage --appimage-extract 26 | 27 | COPY startapp.sh /startapp.sh 28 | COPY migrate_to_ls /migrate_to_ls 29 | COPY squashfs-root/ /digikam/ 30 | 31 | # Additional libraries needed for digikam: 32 | # asound - 6.1.0+ needed for audio. 33 | # udev - 6.1.0+ needed for devices. 34 | # dbus - 6.1.0+ needed for machine id generation. 35 | # libusb - 6.2.0 needed for 6.2.0 usb support. 36 | # p11-ki - 6.2.0 needed for pkcs#11 support. 37 | # libjack0 - 6.2.0 needed for audio connections. 38 | # libz.so.1.2.9 - 6.2.0 (only) needed for libpng16-16. 39 | # libgssapi-krb5-2 - 7.2.0 needed for digikam base. 40 | # libnss3 - 7.2.0 needed for digikam base. 41 | # libimage-exiftool-perl - 7.3.0 needed for digikam base. 42 | # firefox-esr - 7.3.0 needed for smugmug auth (firefox on ubuntu). 43 | # firefox-esr-l10n-all - 7.3.0 needed for smugmug auth (firefox on ubuntu). 44 | # libgl1-mesa-glx - 7.4.0 needed for digikam base. 45 | # Ensure en.UTF-8 set for locale. 46 | RUN \ 47 | update-locale LANG=${LANG} && \ 48 | apt-get --quiet update && add-pkg \ 49 | libusb-1.0 \ 50 | p11-kit \ 51 | libjack0 \ 52 | libudev1 \ 53 | libasound2 \ 54 | pulseaudio \ 55 | libgl1-mesa-dri \ 56 | libgssapi-krb5-2 \ 57 | libnss3 \ 58 | libimage-exiftool-perl \ 59 | firefox \ 60 | libgl1-mesa-glx \ 61 | dbus && \ 62 | apt-get clean autoclean && \ 63 | apt-get autoremove --yes && \ 64 | sed-patch 's/^load-module\ module-native-protocol-unix/#&/' /etc/pulse/default.pa && \ 65 | sed-patch 's/^#load-module\ module-native-protocol-tcp/load-module\ module-native-protocol-tcp auth-anonymous=1/' /etc/pulse/default.pa && \ 66 | # Tag Metadata is a zippy window and cannot be closed without app border. 67 | sed-patch 's///' /etc/xdg/openbox/rc.xml && \ 68 | rm -rfv /var/lib/{apt,dpkg,cache,log} 69 | 70 | volume ["/data"] 71 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | GNU GENERAL PUBLIC LICENSE 2 | Version 2, June 1991 3 | 4 | Copyright (C) 1989, 1991 Free Software Foundation, Inc., 5 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 6 | Everyone is permitted to copy and distribute verbatim copies 7 | of this license document, but changing it is not allowed. 8 | 9 | Preamble 10 | 11 | The licenses for most software are designed to take away your 12 | freedom to share and change it. By contrast, the GNU General Public 13 | License is intended to guarantee your freedom to share and change free 14 | software--to make sure the software is free for all its users. This 15 | General Public License applies to most of the Free Software 16 | Foundation's software and to any other program whose authors commit to 17 | using it. (Some other Free Software Foundation software is covered by 18 | the GNU Lesser General Public License instead.) You can apply it to 19 | your programs, too. 20 | 21 | When we speak of free software, we are referring to freedom, not 22 | price. Our General Public Licenses are designed to make sure that you 23 | have the freedom to distribute copies of free software (and charge for 24 | this service if you wish), that you receive source code or can get it 25 | if you want it, that you can change the software or use pieces of it 26 | in new free programs; and that you know you can do these things. 27 | 28 | To protect your rights, we need to make restrictions that forbid 29 | anyone to deny you these rights or to ask you to surrender the rights. 30 | These restrictions translate to certain responsibilities for you if you 31 | distribute copies of the software, or if you modify it. 32 | 33 | For example, if you distribute copies of such a program, whether 34 | gratis or for a fee, you must give the recipients all the rights that 35 | you have. You must make sure that they, too, receive or can get the 36 | source code. And you must show them these terms so they know their 37 | rights. 38 | 39 | We protect your rights with two steps: (1) copyright the software, and 40 | (2) offer you this license which gives you legal permission to copy, 41 | distribute and/or modify the software. 42 | 43 | Also, for each author's protection and ours, we want to make certain 44 | that everyone understands that there is no warranty for this free 45 | software. If the software is modified by someone else and passed on, we 46 | want its recipients to know that what they have is not the original, so 47 | that any problems introduced by others will not reflect on the original 48 | authors' reputations. 49 | 50 | Finally, any free program is threatened constantly by software 51 | patents. We wish to avoid the danger that redistributors of a free 52 | program will individually obtain patent licenses, in effect making the 53 | program proprietary. To prevent this, we have made it clear that any 54 | patent must be licensed for everyone's free use or not licensed at all. 55 | 56 | The precise terms and conditions for copying, distribution and 57 | modification follow. 58 | 59 | GNU GENERAL PUBLIC LICENSE 60 | TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 61 | 62 | 0. This License applies to any program or other work which contains 63 | a notice placed by the copyright holder saying it may be distributed 64 | under the terms of this General Public License. The "Program", below, 65 | refers to any such program or work, and a "work based on the Program" 66 | means either the Program or any derivative work under copyright law: 67 | that is to say, a work containing the Program or a portion of it, 68 | either verbatim or with modifications and/or translated into another 69 | language. (Hereinafter, translation is included without limitation in 70 | the term "modification".) Each licensee is addressed as "you". 71 | 72 | Activities other than copying, distribution and modification are not 73 | covered by this License; they are outside its scope. The act of 74 | running the Program is not restricted, and the output from the Program 75 | is covered only if its contents constitute a work based on the 76 | Program (independent of having been made by running the Program). 77 | Whether that is true depends on what the Program does. 78 | 79 | 1. You may copy and distribute verbatim copies of the Program's 80 | source code as you receive it, in any medium, provided that you 81 | conspicuously and appropriately publish on each copy an appropriate 82 | copyright notice and disclaimer of warranty; keep intact all the 83 | notices that refer to this License and to the absence of any warranty; 84 | and give any other recipients of the Program a copy of this License 85 | along with the Program. 86 | 87 | You may charge a fee for the physical act of transferring a copy, and 88 | you may at your option offer warranty protection in exchange for a fee. 89 | 90 | 2. You may modify your copy or copies of the Program or any portion 91 | of it, thus forming a work based on the Program, and copy and 92 | distribute such modifications or work under the terms of Section 1 93 | above, provided that you also meet all of these conditions: 94 | 95 | a) You must cause the modified files to carry prominent notices 96 | stating that you changed the files and the date of any change. 97 | 98 | b) You must cause any work that you distribute or publish, that in 99 | whole or in part contains or is derived from the Program or any 100 | part thereof, to be licensed as a whole at no charge to all third 101 | parties under the terms of this License. 102 | 103 | c) If the modified program normally reads commands interactively 104 | when run, you must cause it, when started running for such 105 | interactive use in the most ordinary way, to print or display an 106 | announcement including an appropriate copyright notice and a 107 | notice that there is no warranty (or else, saying that you provide 108 | a warranty) and that users may redistribute the program under 109 | these conditions, and telling the user how to view a copy of this 110 | License. (Exception: if the Program itself is interactive but 111 | does not normally print such an announcement, your work based on 112 | the Program is not required to print an announcement.) 113 | 114 | These requirements apply to the modified work as a whole. If 115 | identifiable sections of that work are not derived from the Program, 116 | and can be reasonably considered independent and separate works in 117 | themselves, then this License, and its terms, do not apply to those 118 | sections when you distribute them as separate works. But when you 119 | distribute the same sections as part of a whole which is a work based 120 | on the Program, the distribution of the whole must be on the terms of 121 | this License, whose permissions for other licensees extend to the 122 | entire whole, and thus to each and every part regardless of who wrote it. 123 | 124 | Thus, it is not the intent of this section to claim rights or contest 125 | your rights to work written entirely by you; rather, the intent is to 126 | exercise the right to control the distribution of derivative or 127 | collective works based on the Program. 128 | 129 | In addition, mere aggregation of another work not based on the Program 130 | with the Program (or with a work based on the Program) on a volume of 131 | a storage or distribution medium does not bring the other work under 132 | the scope of this License. 133 | 134 | 3. You may copy and distribute the Program (or a work based on it, 135 | under Section 2) in object code or executable form under the terms of 136 | Sections 1 and 2 above provided that you also do one of the following: 137 | 138 | a) Accompany it with the complete corresponding machine-readable 139 | source code, which must be distributed under the terms of Sections 140 | 1 and 2 above on a medium customarily used for software interchange; or, 141 | 142 | b) Accompany it with a written offer, valid for at least three 143 | years, to give any third party, for a charge no more than your 144 | cost of physically performing source distribution, a complete 145 | machine-readable copy of the corresponding source code, to be 146 | distributed under the terms of Sections 1 and 2 above on a medium 147 | customarily used for software interchange; or, 148 | 149 | c) Accompany it with the information you received as to the offer 150 | to distribute corresponding source code. (This alternative is 151 | allowed only for noncommercial distribution and only if you 152 | received the program in object code or executable form with such 153 | an offer, in accord with Subsection b above.) 154 | 155 | The source code for a work means the preferred form of the work for 156 | making modifications to it. For an executable work, complete source 157 | code means all the source code for all modules it contains, plus any 158 | associated interface definition files, plus the scripts used to 159 | control compilation and installation of the executable. However, as a 160 | special exception, the source code distributed need not include 161 | anything that is normally distributed (in either source or binary 162 | form) with the major components (compiler, kernel, and so on) of the 163 | operating system on which the executable runs, unless that component 164 | itself accompanies the executable. 165 | 166 | If distribution of executable or object code is made by offering 167 | access to copy from a designated place, then offering equivalent 168 | access to copy the source code from the same place counts as 169 | distribution of the source code, even though third parties are not 170 | compelled to copy the source along with the object code. 171 | 172 | 4. You may not copy, modify, sublicense, or distribute the Program 173 | except as expressly provided under this License. Any attempt 174 | otherwise to copy, modify, sublicense or distribute the Program is 175 | void, and will automatically terminate your rights under this License. 176 | However, parties who have received copies, or rights, from you under 177 | this License will not have their licenses terminated so long as such 178 | parties remain in full compliance. 179 | 180 | 5. You are not required to accept this License, since you have not 181 | signed it. However, nothing else grants you permission to modify or 182 | distribute the Program or its derivative works. These actions are 183 | prohibited by law if you do not accept this License. Therefore, by 184 | modifying or distributing the Program (or any work based on the 185 | Program), you indicate your acceptance of this License to do so, and 186 | all its terms and conditions for copying, distributing or modifying 187 | the Program or works based on it. 188 | 189 | 6. Each time you redistribute the Program (or any work based on the 190 | Program), the recipient automatically receives a license from the 191 | original licensor to copy, distribute or modify the Program subject to 192 | these terms and conditions. You may not impose any further 193 | restrictions on the recipients' exercise of the rights granted herein. 194 | You are not responsible for enforcing compliance by third parties to 195 | this License. 196 | 197 | 7. If, as a consequence of a court judgment or allegation of patent 198 | infringement or for any other reason (not limited to patent issues), 199 | conditions are imposed on you (whether by court order, agreement or 200 | otherwise) that contradict the conditions of this License, they do not 201 | excuse you from the conditions of this License. If you cannot 202 | distribute so as to satisfy simultaneously your obligations under this 203 | License and any other pertinent obligations, then as a consequence you 204 | may not distribute the Program at all. For example, if a patent 205 | license would not permit royalty-free redistribution of the Program by 206 | all those who receive copies directly or indirectly through you, then 207 | the only way you could satisfy both it and this License would be to 208 | refrain entirely from distribution of the Program. 209 | 210 | If any portion of this section is held invalid or unenforceable under 211 | any particular circumstance, the balance of the section is intended to 212 | apply and the section as a whole is intended to apply in other 213 | circumstances. 214 | 215 | It is not the purpose of this section to induce you to infringe any 216 | patents or other property right claims or to contest validity of any 217 | such claims; this section has the sole purpose of protecting the 218 | integrity of the free software distribution system, which is 219 | implemented by public license practices. Many people have made 220 | generous contributions to the wide range of software distributed 221 | through that system in reliance on consistent application of that 222 | system; it is up to the author/donor to decide if he or she is willing 223 | to distribute software through any other system and a licensee cannot 224 | impose that choice. 225 | 226 | This section is intended to make thoroughly clear what is believed to 227 | be a consequence of the rest of this License. 228 | 229 | 8. If the distribution and/or use of the Program is restricted in 230 | certain countries either by patents or by copyrighted interfaces, the 231 | original copyright holder who places the Program under this License 232 | may add an explicit geographical distribution limitation excluding 233 | those countries, so that distribution is permitted only in or among 234 | countries not thus excluded. In such case, this License incorporates 235 | the limitation as if written in the body of this License. 236 | 237 | 9. The Free Software Foundation may publish revised and/or new versions 238 | of the General Public License from time to time. Such new versions will 239 | be similar in spirit to the present version, but may differ in detail to 240 | address new problems or concerns. 241 | 242 | Each version is given a distinguishing version number. If the Program 243 | specifies a version number of this License which applies to it and "any 244 | later version", you have the option of following the terms and conditions 245 | either of that version or of any later version published by the Free 246 | Software Foundation. If the Program does not specify a version number of 247 | this License, you may choose any version ever published by the Free Software 248 | Foundation. 249 | 250 | 10. If you wish to incorporate parts of the Program into other free 251 | programs whose distribution conditions are different, write to the author 252 | to ask for permission. For software which is copyrighted by the Free 253 | Software Foundation, write to the Free Software Foundation; we sometimes 254 | make exceptions for this. Our decision will be guided by the two goals 255 | of preserving the free status of all derivatives of our free software and 256 | of promoting the sharing and reuse of software generally. 257 | 258 | NO WARRANTY 259 | 260 | 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY 261 | FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN 262 | OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES 263 | PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED 264 | OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 265 | MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS 266 | TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE 267 | PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, 268 | REPAIR OR CORRECTION. 269 | 270 | 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING 271 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR 272 | REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, 273 | INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING 274 | OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED 275 | TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY 276 | YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER 277 | PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE 278 | POSSIBILITY OF SUCH DAMAGES. 279 | 280 | END OF TERMS AND CONDITIONS 281 | 282 | How to Apply These Terms to Your New Programs 283 | 284 | If you develop a new program, and you want it to be of the greatest 285 | possible use to the public, the best way to achieve this is to make it 286 | free software which everyone can redistribute and change under these terms. 287 | 288 | To do so, attach the following notices to the program. It is safest 289 | to attach them to the start of each source file to most effectively 290 | convey the exclusion of warranty; and each file should have at least 291 | the "copyright" line and a pointer to where the full notice is found. 292 | 293 | 294 | Copyright (C) 295 | 296 | This program is free software; you can redistribute it and/or modify 297 | it under the terms of the GNU General Public License as published by 298 | the Free Software Foundation; either version 2 of the License, or 299 | (at your option) any later version. 300 | 301 | This program is distributed in the hope that it will be useful, 302 | but WITHOUT ANY WARRANTY; without even the implied warranty of 303 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 304 | GNU General Public License for more details. 305 | 306 | You should have received a copy of the GNU General Public License along 307 | with this program; if not, write to the Free Software Foundation, Inc., 308 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 309 | 310 | Also add information on how to contact you by electronic and paper mail. 311 | 312 | If the program is interactive, make it output a short notice like this 313 | when it starts in an interactive mode: 314 | 315 | Gnomovision version 69, Copyright (C) year name of author 316 | Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. 317 | This is free software, and you are welcome to redistribute it 318 | under certain conditions; type `show c' for details. 319 | 320 | The hypothetical commands `show w' and `show c' should show the appropriate 321 | parts of the General Public License. Of course, the commands you use may 322 | be called something other than `show w' and `show c'; they could even be 323 | mouse-clicks or menu items--whatever suits your program. 324 | 325 | You should also get your employer (if you work as a programmer) or your 326 | school, if any, to sign a "copyright disclaimer" for the program, if 327 | necessary. Here is a sample; alter the names: 328 | 329 | Yoyodyne, Inc., hereby disclaims all copyright interest in the program 330 | `Gnomovision' (which makes passes at compilers) written by James Hacker. 331 | 332 | , 1 April 1989 333 | Ty Coon, President of Vice 334 | 335 | This General Public License does not permit incorporating your program into 336 | proprietary programs. If your program is a subroutine library, you may 337 | consider it more useful to permit linking proprietary applications with the 338 | library. If this is what you want to do, use the GNU Lesser General 339 | Public License instead of this License. 340 | -------------------------------------------------------------------------------- /Makefile: -------------------------------------------------------------------------------- 1 | # Makefile for digikam docker containers. 2 | # 3 | # Public Keys 4 | # Digikam: http://keys.gnupg.net/pks/lookup?search=digikamdeveloper%40gmail.com&fingerprint=on 5 | # 6 | # TODO: De-duplicate stable/unstable and finish simplifying build options. 7 | # 8 | version = 7.8.0 9 | pre_release = 7.8.0 10 | BUILD_DIR = digikam-build 11 | STAGING_DIR = $(BUILD_DIR)/staging 12 | GPG_DIR = $(BUILD_DIR)/gpg 13 | GPG_KEYSERVER = pool.sks-keyservers.net 14 | DIGI_BUILD = $(BUILD_DIR)/$(version)/squashfs-root 15 | PRE_DIGI_BUILD = $(BUILD_DIR)/$(pre_release)/squashfs-root 16 | DIGI_START = startapp.sh 17 | MIGRATE = migrate_to_ls 18 | DOCKER_FILE = Dockerfile 19 | 20 | DIGIKAM_PUBLIC_KEY = C2386E50 21 | DIGIKAM = digiKam-$(version)-x86-64.appimage 22 | PRE_DIGIKAM = digiKam-$(pre_release)-x86-64.appimage 23 | DIGIKAM_URI = https://download.kde.org/stable/digikam/$(version)/${DIGIKAM} 24 | PRE_DIGIKAM_URI = https://download.kde.org/unstable/digikam/${PRE_DIGIKAM} 25 | 26 | REGISTRY = rpufky 27 | TAGS_MAJOR = $(REGISTRY)/digikam:$(version) 28 | TAGS_PRE = $(REGISTRY)/digikam:$(pre_release) 29 | TAGS_STABLE = $(REGISTRY)/digikam:stable 30 | TAGS_LATEST = $(REGISTRY)/digikam:latest 31 | 32 | help: 33 | @echo "USAGE:" 34 | @echo " make digikam[_no_gpg] [version=$(version)]" 35 | @echo " Build digikam docker container with specified values." 36 | @echo 37 | @echo " make stable[_no_gpg] [version=$(version)]" 38 | @echo " Tags completed build as stable with specified values." 39 | @echo 40 | @echo " make latest[_no_gpg] [version=$(version)]" 41 | @echo " Tags completed build as latest with specified values." 42 | @echo 43 | @echo " digkam, stable, latest may be used with _no_gpg (digikam_no_gpg)" 44 | @echo " to disable GPG verification during build. Occasionally digikam GPG" 45 | @echo " certs will not be updated on time and cause build to fail." 46 | @echo 47 | @echo " make pre_release" 48 | @echo " Uses static pre_release: $(pre_release) build, tags as latest." 49 | @echo " Build is nevered verifed against GPG." 50 | @echo 51 | @echo " make clean" 52 | @echo " Removes all build artifacts on filesystem. Does NOT remove docker images." 53 | @echo 54 | @echo " make clean_staging" 55 | @echo " Removes ONLY staging artifacts on filesystem. Does not remove downloaded files." 56 | @echo 57 | @echo " make all_clean" 58 | @echo " Removes all build artifacts and all docker images matching $(REGISTRY)/digikam." 59 | @echo 60 | @echo "OPTIONS:" 61 | @echo " version: Digikam release version to build from. Default: $(version)." 62 | 63 | .PHONY: help Makefile 64 | 65 | digikam: appimage verify extract staging docker_build 66 | digikam_no_gpg: appimage extract staging docker_build 67 | 68 | stable: digikam 69 | @echo 'Tagging docker container digikam:$(version) as stable' 70 | @docker image tag $(TAGS_MAJOR) $(TAGS_STABLE) 71 | @echo 'Remember to Verify container, then push to docker hub: docker push $(TAGS_STABLE)' 72 | 73 | stable_no_gpg: digikam_no_gpg 74 | @echo 'Tagging docker container digikam:$(version) as stable' 75 | @docker image tag $(TAGS_MAJOR) $(TAGS_STABLE) 76 | @echo 'Remember to Verify container, then push to docker hub: docker push $(TAGS_STABLE)' 77 | 78 | latest: digikam 79 | @echo 'Tagging docker container digikam:$(version) as latest' 80 | @docker image tag $(TAGS_MAJOR) $(TAGS_LATEST) 81 | @echo 'Remember to Verify container, then push to docker hub: docker push $(TAGS_LATEST)' 82 | 83 | latest_no_gpg: digikam_no_gpg 84 | @echo 'Tagging docker container digikam:$(version) as latest' 85 | @docker image tag $(TAGS_MAJOR) $(TAGS_LATEST) 86 | @echo 'Remember to Verify container, then push to docker hub: docker push $(TAGS_LATEST)' 87 | 88 | pre_release: appimage_unstable extract_unstable staging_unstable docker_build_unstable 89 | @echo 'Tagging docker container digikam:$(pre_release) as latest' 90 | @docker image tag $(TAGS_PRE) $(TAGS_LATEST) 91 | @echo 'Remember to Verify container, then push to docker hub: docker push $(TAGS_LATEST)' 92 | 93 | docker_build: 94 | @echo 'Building docker container version:$(version)' 95 | @cd $(STAGING_DIR) && \ 96 | docker build \ 97 | --build-arg digikam_version="Digikam $(version)" \ 98 | -t $(TAGS_MAJOR) \ 99 | . 100 | @echo 'Remember to Verify container, then push to docker hub: docker push $(TAGS_MAJOR)' 101 | 102 | docker_build_unstable: 103 | @echo 'Building docker container version:$(pre_release)' 104 | @cd $(STAGING_DIR) && \ 105 | docker build \ 106 | --build-arg digikam_version="Digikam $(pre_release)" \ 107 | -t $(TAGS_PRE) \ 108 | . 109 | 110 | staging: 111 | @echo 'Staging build for Dockerfile consumption ...' 112 | @rm -rfv $(STAGING_DIR) || exit 0 113 | @mkdir -p $(STAGING_DIR) $(DOCKER_STAGING) 114 | @cp -av $(DIGI_START) $(STAGING_DIR) 115 | @cp -av $(MIGRATE) $(STAGING_DIR) 116 | @cp -av $(DOCKER_FILE) $(STAGING_DIR) 117 | @cp -av $(DIGI_BUILD) $(STAGING_DIR) 118 | 119 | staging_unstable: 120 | @echo 'Staging build for Dockerfile consumption ...' 121 | @rm -rfv $(STAGING_DIR) || exit 0 122 | @mkdir -p $(STAGING_DIR) $(DOCKER_STAGING) 123 | @cp -av $(DIGI_START) $(STAGING_DIR) 124 | @cp -av $(MIGRATE) $(STAGING_DIR) 125 | @cp -av $(DOCKER_FILE) $(STAGING_DIR) 126 | @cp -av $(PRE_DIGI_BUILD) $(STAGING_DIR) 127 | 128 | extract: 129 | @echo 'Extracting packages ...' 130 | @chmod +x $(BUILD_DIR)/$(DIGIKAM) 131 | @mkdir -p $(BUILD_DIR)/$(version) 132 | @test ! -d $(DIGI_BUILD) && \ 133 | cd $(BUILD_DIR)/$(version) && \ 134 | ../$(DIGIKAM) --appimage-extract || exit 0 && \ 135 | cd - 136 | @cp -v $(BUILD_DIR)/$(DIGIKAM).sig $(DIGI_BUILD) 137 | @chmod o=u -Rv $(DIGI_BUILD) 138 | 139 | extract_unstable: 140 | @echo 'Extracting packages ...' 141 | @mkdir -p $(BUILD_DIR)/$(pre_release) 142 | @test ! -d $(PRE_DIGI_BUILD) && \ 143 | cd $(BUILD_DIR)/$(pre_release) && \ 144 | ../$(PRE_DIGIKAM) --appimage-extract || exit 0 && \ 145 | cd - 146 | @cp -v $(BUILD_DIR)/$(PRE_DIGIKAM).sig $(PRE_DIGI_BUILD) 147 | @chmod o=u -Rv $(PRE_DIGI_BUILD) 148 | 149 | appimage: 150 | @echo 'Downloading and verifying Digikam $(version) AppImage ...' 151 | @mkdir -p $(BUILD_DIR) $(GPG_DIR) 152 | @chmod 0700 $(GPG_DIR) 153 | @test ! -f $(BUILD_DIR)/$(DIGIKAM) && \ 154 | wget --directory-prefix=$(BUILD_DIR) $(DIGIKAM_URI) || exit 0 155 | @test ! -f $(BUILD_DIR)/$(DIGIKAM).sig && \ 156 | wget --directory-prefix=$(BUILD_DIR) $(DIGIKAM_URI).sig || exit 0 157 | 158 | verify: 159 | @echo 'Validating Digikam appimage ...' 160 | @gpg --homedir $(GPG_DIR) --keyserver $(GPG_KEYSERVER) --recv-keys $(DIGIKAM_PUBLIC_KEY) 161 | @gpg --homedir $(GPG_DIR) --keyserver $(GPG_KEYSERVER) --verify $(BUILD_DIR)/$(DIGIKAM).sig $(BUILD_DIR)/$(DIGIKAM) 162 | 163 | appimage_unstable: 164 | @echo 'Downloading and verifying Digikam $(pre_release) AppImage from unstable ...' 165 | @mkdir -p $(BUILD_DIR) $(GPG_DIR) 166 | @chmod 0700 $(GPG_DIR) 167 | @test ! -f $(BUILD_DIR)/$(PRE_DIGIKAM) && \ 168 | wget --directory-prefix=$(BUILD_DIR) $(PRE_DIGIKAM_URI) || exit 0 169 | @test ! -f $(BUILD_DIR)/$(PRE_DIGIKAM).sig && \ 170 | wget --directory-prefix=$(BUILD_DIR) $(PRE_DIGIKAM_URI).sig || exit 0 171 | @chmod +x $(BUILD_DIR)/$(PRE_DIGIKAM) 172 | 173 | clean: 174 | @echo 'Cleaning build directories ...' 175 | @rm -rfv "$(BUILD_DIR)" 176 | 177 | clean_staging: 178 | @echo 'Cleaning ONLY staging directories ...' 179 | @rm -rfv "$(STAGING_DIR)" 180 | 181 | all_clean: clean 182 | @echo 'Removing $(REGISTRY)/digikam images ...' 183 | @docker rmi -f `docker images --filter=reference=$(REGISTRY)/digikam --format '{{.ID}}'` || exit 0 184 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # [![digikam][f8]](https://www.digikam.org/documentation/) digikam 2 | 3 | :warning: DEPRECATION: Support will end on the next major digikam release. :warning: 4 | 5 | :warning: See [migration instructions](migration.md) for details and how to migrate to 6 | the linuxserver digikam image. :warning: 7 | 8 | digikam is an advanced open-source digital photo management application that 9 | runs on Linux, Windows, and MacOS. The application provides a comprehensive set 10 | of tools for importing, managing, editing, and sharing photos and raw files. 11 | 12 | This is a docker image that uses the [digikam AppImage][f9] combined with 13 | [jlesage/baseimage-gui:ubuntu-20.04][5t] to enable dockerized digikam usage with all 14 | plugins via any modern web browser without additional client configuration. 15 | 16 | Please read documentation on [jlesage/baseimage-gui][5t] for detailed baseimage 17 | usage. 18 | 19 | ## Version Tags 20 | This image provides various versions that are available via tags. Use `stable` 21 | or an explicit digikam version (e.g. 7.8.0), which will provide updates but 22 | minimize unexpected changes. 23 | 24 | * `stable` will provide the latest officially released version of digikam. 25 | * `latest` will provide the latest digikam build and **will** break. 26 | 27 | `stable` and `latest` containers are auto-rebuilt weekly. 28 | 29 | | Tag | Description | Comment | 30 | |--------|-------------------------|-----------------------------------------------------------------| 31 | | latest | digikam container 7.8.0 | [7.8.0 Release](https://download.kde.org/stable/digikam/7.8.0/) | 32 | | stable | digikam container 7.8.0 | [7.8.0 Release](https://download.kde.org/stable/digikam/7.8.0/) | 33 | 34 | * See detailed [release notes here][b2] for older container point releases. Only current and previous versions are kept. 35 | * Submit docker-related [bugs here][sl]. 36 | * See digikam [release plan here][2k]. 37 | * See [troubleshooting](#troubleshooting) for issues, like DB 10 to 11 upgrade failure. 38 | 39 | ### docker-compose 40 | ``` 41 | --- 42 | version: "3" 43 | services: 44 | digikam: 45 | image: rpufky/digikam:stable 46 | ports: 47 | - "5800:5800" 48 | environment: 49 | - USER_ID=1000 50 | - GROUP_ID=1000 51 | - UMASK=022 52 | - TZ=America/Los_Angeles 53 | - KEEP_APP_RUNNING=1 54 | - DISPLAY_WIDTH=1920 55 | - DISPLAY_HEIGHT=1080 56 | - ENABLE_CJK_FONT=1 57 | volumes: 58 | - /my/docker/service/config:/config 59 | - /my/photo/location:/data 60 | - /etc/localtime:/etc/localtime:ro 61 | ``` 62 | 63 | ## Parameters 64 | Please read documentation on [jlesage/baseimage-gui][5t] for detailed baseimage 65 | parameters. Only used and new default settings are listed here. 66 | 67 | | Parameter | Function | Default | 68 | |-----------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------| 69 | |`USER_ID` | ID of the user the application runs as. | `1000` | 70 | |`GROUP_ID` | ID of the group the application runs as. | `1000` | 71 | |`UMASK` | Octal mask that controls how file permissions are set for newly created files. Default of `022` mean newly created files are readable by everyone, but only writable by the owner. See the following online umask calculator: http://wintelguy.com/umask-calc.pl | 022 | 72 | |`TZ` | [TimeZone] of the container. Timezone can also be set by mapping `/etc/localtime` between the host and the container. | `Etc/UTC` | 73 | |`KEEP_APP_RUNNING` | When set to `1`, the application will be automatically restarted if it crashes or if user quits it. | `1` | 74 | |`TAKE_CONFIG_OWNERSHIP`| When set to `1`, owner and group of `/config` (including all its files and subfolders) are automatically set during container startup to `USER_ID` and `GROUP_ID` respectively. | `1` | 75 | |`CLEAN_TMP_DIR` | When set to `1`, all files in the `/tmp` directory are delete during the container startup. | `1` | 76 | |`DISPLAY_WIDTH` | Width (in pixels) of the application's window. | `1920` | 77 | |`DISPLAY_HEIGHT` | Height (in pixels) of the application's window. | `1080` | 78 | |`SECURE_CONNECTION` | When set to `1`, an encrypted connection is used to access the application's GUI (either via web browser or VNC client). See the [Security](#security) section for more details. | `0` | 79 | |`VNC_PASSWORD` | Password needed to connect to the application's GUI. See the [jlesage/baseimage-gui - VNC Password][5t] section for more details. | (unset) | 80 | |`X11VNC_EXTRA_OPTS` | Extra options to pass to the x11vnc server running in the Docker container. **WARNING**: For advanced users. Do not use unless you know what you are doing. | (unset) | 81 | |`ENABLE_CJK_FONT` | When set to `1`, open source computer font `WenQuanYi Zen Hei` is installed. This font contains a large range of Chinese/Japanese/Korean characters. | `1` | 82 | |`LANG` | System default locale. | `POSIX` | 83 | |`LANGUAGE` | System fallback locale. | `POSIX` | 84 | |`LC_ALL` | System locale override. | `POSIX` | 85 | 86 | ## Ports 87 | Here are the list of ports used by container. They can be mapped to the host 88 | via the `-p :` parameter. The port number inside the 89 | container cannot be changed, but you are free to use any port on the host side. 90 | 91 | | Port | Required? | Description | 92 | |------|-----------|-----------------------------------------------------------------------------------------------------| 93 | |`5800`| Mandatory | Port used to access the application's GUI via the web interface. | 94 | |`5900`| Optional | Port used to access the application's GUI via the VNC protocol. Optional if no VNC client is used. | 95 | 96 | ## Volumes 97 | 98 | | Volume | Function | 99 | |---------|--------------------------------------------| 100 | | /config | Stores digikam configuration and database. | 101 | | /data | User data location for images. | 102 | 103 | ## User/Group IDs 104 | When using data volumes (`-v` flags), permissions issues can occur between the 105 | host and the container. For example, the user within the container may not 106 | exists on the host. This could prevent the host from properly accessing files 107 | and folders on the shared volume. 108 | 109 | To avoid any problem, you can specify the user the application should run as. 110 | 111 | This is done by passing the user ID and group ID to the container via the 112 | `USER_ID` and `GROUP_ID` environment variables. 113 | 114 | To find the right IDs to use, issue the following command on the host, with the 115 | user owning the data volume on the host: 116 | 117 | id 118 | 119 | Which gives an output like this one: 120 | ``` 121 | uid=1000(myuser) gid=1000(myuser) groups=1000(myuser),4(adm),24(cdrom),27(sudo),46(plugdev),113(lpadmin) 122 | ``` 123 | 124 | The value of `uid` (user ID) and `gid` (group ID) are the ones that you should 125 | be given the container. 126 | 127 | ## Config Directory 128 | Inside the container, the application's configuration should be stored in the 129 | `/config` directory. 130 | 131 | This directory is also used to store the VNC password. 132 | 133 | **NOTE**: By default, during the container startup, the user which runs the 134 | application (i.e. user defined by `USER_ID`) will claim ownership of the 135 | entire content of this directory. This behavior can be changed via the 136 | `TAKE_CONFIG_OWNERSHIP` environment variable. 137 | 138 | ## Accessing the GUI 139 | Assuming that container's ports are mapped to the same host's ports, the 140 | graphical interface of the application can be accessed via: 141 | 142 | A web browser 143 | ``` 144 | http://{HOST IP}:5800 145 | ``` 146 | 147 | Any VNC client 148 | ``` 149 | {HOST IP}:5900 150 | ``` 151 | 152 | However, a **[reverse proxy web based](#reverse-proxy-setup)** connection is 153 | preferred. 154 | 155 | ## Security 156 | By default, access to the application's GUI is done over an unencrypted 157 | connection (HTTP or VNC). Secure connection can be enabled via the 158 | `SECURE_CONNECTION` environment variable. When enabled, application's GUI is 159 | performed over an HTTPs connection when accessed with a browser. All HTTP 160 | accesses are automatically redirected to HTTPs. 161 | 162 | When using a VNC client, the VNC connection is performed over SSL. Note that few 163 | VNC clients support this method. 164 | 165 | See [jlesage/baseimage-gui][5t] for additional documentation. 166 | 167 | ## Reverse Proxy Setup 168 | digikam should be operated behind a reverse proxy to isolate access to the 169 | container. The following reverse proxy example assumes that you have a 170 | digikam sub-domain setup for nginx. 171 | 172 | ```nginx 173 | server { 174 | listen 443 ssl http2; 175 | server_name digikam.example.com digikam; 176 | 177 | location / { 178 | proxy_pass https://digikam:5800/; 179 | } 180 | 181 | location /websockify { 182 | proxy_pass https://digikam:5800; 183 | proxy_http_version 1.1; 184 | proxy_set_header Upgrade $http_upgrade; 185 | proxy_set_header Connection "Upgrade"; 186 | } 187 | } 188 | ``` 189 | * `websockify` provides the web socket connection for the browser and needs to 190 | exposed for the GUI to render properly. 191 | 192 | ## digikam Setup 193 | When first launching digikam the only explicit settings that must be set are the 194 | following: 195 | 196 | ### Configure where you keep your images 197 | ![digikam images][5k] 198 | * Manually set to `/data` for your images. 199 | 200 | ### Configure where you will store databases 201 | ![digikam db][b7] 202 | * Type: `SQLite` 203 | * Manually set to `/config` for your db. 204 | 205 | ### Facial recognition training data 206 | ![digikam faces][c8] 207 | * Download **~335MB** 208 | * One time download if `/config` is mounted outside of docker. 209 | 210 | ## Troubleshooting 211 | 212 | ### Failed to update DB schema from [10 to 11][8s] 213 | Your digikam DB user does not have sufficient rights to modify the DB tables. 214 | 215 | By default stored functions [require superuser (root)][8h] permissions. 216 | 217 | Enable trusted stored functions. 218 | ```bash 219 | mysql -u root -p 220 | 221 | set global log_bin_trust_function_creators=1; 222 | ``` 223 | 224 | ## Manually Building 225 | Built using a Makefile to manage builds. Assumes current user is a privleged 226 | docker user. Common commands below: 227 | 228 | ```bash 229 | make 230 | ``` 231 | * Shows all make options. 232 | 233 | ```bash 234 | make digikam version=7.8.0 235 | ``` 236 | * Build 'stable' version using appimage 7.8.0. 237 | 238 | ```bash 239 | make latest version=7.8.0 240 | ``` 241 | * builds 'latest' version using appimage 7.8.0. 242 | 243 | ```bash 244 | make clean 245 | ``` 246 | * Cleans build artifacts on the filesystem. 247 | 248 | ## Licensing 249 | digikam is under the [GPLv2 license as stated here][2j]. digikam [icon image][f8] is 250 | unmodified and copied under this license. 251 | 252 | [8h]: https://mariadb.com/docs/reference/mdb/system-variables/log_bin_trust_function_creators/ 253 | [8s]: https://bugs.kde.org/show_bug.cgi?id=435065#c8 254 | [2k]: https://www.digikam.org/documentation/releaseplan/ 255 | [sl]: https://github.com/r-pufky/digikam/issues 256 | [5t]: https://hub.docker.com/r/jlesage/baseimage-gui/ 257 | [f9]: https://www.digikam.org/download/ 258 | [2j]: https://invent.kde.org/kde/digikam/blob/master/COPYING 259 | [f8]: https://raw.githubusercontent.com/r-pufky/digikam/master/media/digikam_oxygen.svg?sanitize=true 260 | [5k]: https://github.com/r-pufky/digikam/blob/master/media/digikam-setup-images.png?raw=true 261 | [b7]: https://github.com/r-pufky/digikam/blob/master/media/digikam-setup-db.png?raw=true 262 | [b2]: https://github.com/r-pufky/digikam/blob/master/RELEASE.md 263 | [c8]: https://github.com/r-pufky/digikam/blob/master/media/digikam-setup-faces.png?raw=true 264 | -------------------------------------------------------------------------------- /RELEASE.md: -------------------------------------------------------------------------------- 1 | # [Changelog][3g] 2 | Uses semantic versioning, with an additional container version number: 3 | 4 | `MAJOR.MINOR.PATCH.CONTAINER` 5 | 6 | ## Unreleased 7 | 8 | ## 7.8.0 9 | Digikam [7.8.0 release][9f]. 10 | 11 | Changes: 12 | * Bump digikam release version. 13 | 14 | ## 7.7.0 15 | Digikam [7.7.0 release][9f]. 16 | 17 | Changes: 18 | * Bump digikam release version. 19 | * Updated deprecation message to final supported version (8.0). 20 | 21 | ## 7.6.0 22 | Digikam [7.6.0 relase][9f]. 23 | 24 | Added: 25 | * migrate_to_ls - linuxserver migration script. 26 | * migration.md - migration documentation. 27 | * Deprecation and support notice. 28 | 29 | Changes: 30 | * Bump digikam release version. 31 | 32 | ## 7.5.0 33 | Digikam [7.5.0 relase][9f]. 34 | 35 | Changes: 36 | * update baseimage-gui to ubuntu-20.04 due to digikam changes. 37 | 38 | ## 7.4.0 39 | Digikam [7.4.0 release][9f]. 40 | 41 | Changes: 42 | * update baseimage-gui to (custom) ubuntu-20.04 due to digikam changes. 43 | 44 | ## 7.3.0 45 | Digikam [7.3.0 release][9f]. 46 | 47 | Changes: 48 | * Update defaults for 7.3.0 release. 49 | * Add exiftool dependency. 50 | * Add Firefox Extended Support Release (ESR) w/ all language support for smugmug 51 | authentication support. 52 | 53 | Fixes: 54 | * #11 55 | * #12 56 | 57 | ## 7.2.0 58 | Digikam [7.2.0 release][9f]. 59 | 60 | Changes: 61 | * Added facial recognition training data configuration. 62 | * Update dependencies for facial recognition. 63 | * DB 10 to 11 stored functions troubleshooting. 64 | 65 | Fixes: 66 | * #8 67 | 68 | ## 7.1.0 69 | Digikam [7.1.0 release][9f]. 70 | 71 | ## 7.0.0 72 | Digikam [7.0.0 release][9f]. 73 | Digikam [7.0.0-rc release][9f] from 2020-06-14 build. 74 | Digikam [7.0.0-beta3 release][9f] from 2020-04-22T062854 build. 75 | Digikam [7.0.0-beta2 release][9f] from 2020-01-27 build. 76 | Digikam [7.0.0-beta1 release][9f] from 2019-12-22 build. 77 | 78 | ## 6.4.0 79 | Digikam [6.4.0 release][7b]. 80 | 81 | ## 6.4.0.1 82 | 83 | Changes: 84 | * Add libgl1-mesa-dri to resolve libEGL warning message. 85 | 86 | Fixed: 87 | * #2 88 | 89 | ## 6.4.0.0 90 | 91 | Release digikam 6.4.0 from 2019-11-02 build: 92 | https://download.kde.org/stable/digikam/6.4.0/. 93 | 94 | ## 6.3.0 95 | Digikam [6.3.0 release][9d]. 96 | 97 | ## 6.3.0.2 98 | 99 | Changes: 100 | * Removed manual zlib dependency, only needed for 6.2.0 version. 101 | 102 | ## 6.3.0.1 103 | 104 | Changes: 105 | * Include corrected 2019-09-04T22:22 6.3.0 build. 106 | * Include release signature within container `/digikam/digikam-*.sig` 107 | * Add `stable` and `major` tracks for releases. 108 | 109 | ## 6.3.0.0 110 | 111 | Release digikam 6.3.0 from 2019-09-04 build: 112 | https://download.kde.org/stable/digikam/6.3.0/. 113 | 114 | # Deprecated Releases 115 | All releases below are no longer maintained. 116 | 117 | ## 6.2.0 118 | Digikam [6.2.0 release][8v]. 119 | 120 | ### 6.2.0.1 121 | 122 | Changes: 123 | * Include release signature within container `/digikam/digikam-*.sig` 124 | * Add `stable` and `major` tracks for releases. 125 | 126 | ### 6.2.0.0 127 | 128 | Changes: 129 | * AppImage and zlib packages are now verified against GPG signatures before 130 | extracting. 131 | * 6.2.0 requires libz.so.1.2.9, debian stretch ships with 1.2.8. Build now 132 | includes zlib-1.2.9 source and builds a 1.2.9 shared object for use. 133 | * Added libusb, p11-ki, libjack0 packages to base install to support 6.2.0. 134 | 135 | ## 6.1.0 136 | Digikam 6.1.0 release. 137 | 138 | ### 6.1.0.3 139 | 140 | Changes: 141 | * Include release signature within container `/digikam/digikam-*.sig` 142 | * Add `stable` and `major` tracks for releases. 143 | * AppImage and zlib packages are now verified against GPG signatures before 144 | extracting. 145 | * Build now includes zlib-1.2.9 source and builds a 1.2.9 shared object for use. 146 | 147 | ### 6.1.0.2 148 | Set application permissions before add to docker layer; resulting in original 149 | deployment size (552MB) instead of 1GB. 150 | 151 | ### 6.1.0.1 152 | Address non-default permissions issue and tweak build settings for versioning 153 | change. 154 | 155 | Fixes: 156 | * #1 Setting USER_ID does not properly propagate permissions inside container. 157 | 158 | [9f]: https://www.digikam.org/documentation/releaseplan/ 159 | [7b]: https://cgit.kde.org/digikam.git/tree/project/NEWS.6.4.0 160 | [9d]: https://cgit.kde.org/digikam.git/tree/project/NEWS.6.3.0 161 | [8v]: https://cgit.kde.org/digikam.git/tree/project/NEWS.6.2.0 162 | [3g]: https://keepachangelog.com/en/1.0.0/ 163 | [7g]: https://nvd.nist.gov/vuln/detail/CVE-2021-44228 164 | -------------------------------------------------------------------------------- /media/digikam-setup-db.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/r-pufky/digikam/8d99924de03fdf59aeb0425ed20654db637bf156/media/digikam-setup-db.png -------------------------------------------------------------------------------- /media/digikam-setup-faces.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/r-pufky/digikam/8d99924de03fdf59aeb0425ed20654db637bf156/media/digikam-setup-faces.png -------------------------------------------------------------------------------- /media/digikam-setup-images.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/r-pufky/digikam/8d99924de03fdf59aeb0425ed20654db637bf156/media/digikam-setup-images.png -------------------------------------------------------------------------------- /migrate_to_ls: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # 3 | # Migrate well-know config locations from rpufky to ls digikam config. 4 | # 5 | 6 | USAGE=" 7 | Migrate well-known config locations from rpufky to ls digikam config. 8 | 9 | Assumes a base ls/digikam config location has been run once. This is 10 | non-destructive for the source config. 11 | 12 | See https://github.com/r-pufky/digikam/blob/master/migration.md for full 13 | migration instructions. 14 | 15 | Usage: $0 [OPTIONS] 16 | 17 | Options: 18 | -s [DIR] Source config mount (rpufky/digikam config mount). Use trailing 19 | slash. Required. 20 | -d [DIR] Dest config mount (ls/digikam config mount). Use trailing slash. 21 | Required. 22 | 23 | Examples: 24 | $0 -s /data/rp/config/ -d /data/ls/config/ 25 | " 26 | 27 | while getopts "s:d:h" options; do 28 | case "${options}" in 29 | s) 30 | SOURCE=${OPTARG%%/} 31 | ;; 32 | d) 33 | DEST=${OPTARG%%/} 34 | ;; 35 | h) 36 | echo "${USAGE}" 37 | exit 1 38 | ;; 39 | :) 40 | echo "${USAGE}" 41 | exit 1 42 | ;; 43 | esac 44 | done 45 | 46 | if [ -z ${SOURCE} ] || [ -z ${DEST} ]; then 47 | echo 'Error: source and destination config locations required.' 48 | exit 2 49 | fi 50 | 51 | # Migrate user settings. 52 | cp -av "${DEST}/.config/digikamrc" "${DEST}/.config/digikamrc.orig" 53 | cp -av "${SOURCE}/xdg/config/digikamrc" "${DEST}/.config/digikamrc" 54 | chown --reference="${DEST}/.config/digikamrc.orig" "${DEST}/.config/digikamrc" 55 | chmod --reference="${DEST}/.config/digikamrc.orig" "${DEST}/.config/digikamrc" 56 | 57 | # Migrate DBs. 58 | find "${DEST}" -type f -name "*.db" -exec mv -v {} {}.orig \; 59 | cp -av "${SOURCE}"/*.db "${DEST}" 60 | chown --reference="${DEST}/digikam4.db.orig" "${DEST}/"*.db 61 | chmod --reference="${DEST}/digikam4.db.orig" "${DEST}/"*.db 62 | -------------------------------------------------------------------------------- /migration.md: -------------------------------------------------------------------------------- 1 | # Migration to Linuxserver Digikam 2 | 3 | :warning: ALWAYS BACKUP YOUR DATA AND CONFIGS! :warning: 4 | 5 | ## TOC 6 | * [Migration Steps](#migration-steps) 7 | * [Manual Migration](#manual-migration) 8 | * [Setup a new linuxserver digikam container](#setup-a-new-linuxserver-digikam-container) 9 | * [File locations](#file-locations) 10 | * [Background](#background) 11 | * [FAQS](#faqs) 12 | 13 | ## Migration Steps 14 | Database backend types (sqlite3/SQL) do not affect which migration process you 15 | use. If you have used custom storage locations see [Manual Migration](#manual-migration). 16 | 17 | These instructions assume you used the default locations in the original setup 18 | [instructions](https://github.com/r-pufky/digikam/blob/master/README.md#digikam-setup). 19 | 20 | Only docker-compose steps are covered. 21 | 22 | ### Setup new linuxserver container 23 | Run through [setup a new linuxserver/digikam container](#setup-a-new-linuxserver-digikam-container) 24 | 25 | This will get the new digikam container in the appropriate state for migration. 26 | 27 | ### Update rpufky digikam to latest release 28 | Standard upgrade steps. Use the `latest` tag in `docker-compose.yml` and update 29 | your container. Be sure to add a `container_name` if you haven't set one 30 | before. 31 | 32 | `rpufky-digikam/docker-compose.yml` 33 | ```yaml 34 | --- 35 | version: "3" 36 | services: 37 | digikam: 38 | image: rpufky/digikam:latest # USE LATEST RELEASE. 39 | container_name: rpufky-digikam # SET CONTAINER NAME. 40 | ports: 41 | - "5800:5800" 42 | environment: 43 | - USER_ID=1000 44 | - GROUP_ID=1000 45 | - UMASK=022 46 | - TZ=America/Los_Angeles 47 | - KEEP_APP_RUNNING=1 48 | - DISPLAY_WIDTH=1920 49 | - DISPLAY_HEIGHT=1080 50 | - ENABLE_CJK_FONT=1 51 | volumes: 52 | - /my/docker/service/config:/config 53 | - /my/photo/location:/data 54 | - /etc/localtime:/etc/localtime:ro 55 | ``` 56 | 57 | Update the container and copy the migration script to your system; this should 58 | use your `container_name`. 59 | ```bash 60 | docker-compose stop 61 | docker-compose pull 62 | docker-compose up -d 63 | docker cp rpufky-digikam:/migrate_to_ls /tmp 64 | docker-compose stop 65 | chmod +x /tmp/migrate_to_ls 66 | ``` 67 | 68 | ### Migrate configuration data 69 | Use script previous copied to migrate configuration data to the new linuxserver 70 | container. This is non-destructive for the source container. 71 | 72 | Trailing slashes are required. 73 | ```bash 74 | /tmp/migrate_to_ls -s /my/docker/service/config/ -d /my/docker/service/NEW/config/ 75 | ``` 76 | 77 | Restart the linuxserver digikam container and verify settings are correct. Be 78 | aware that you may need to update reverse proxy or firewall rules for the new 79 | ports. 80 | 81 | ```bash 82 | docker-compose up -d 83 | ``` 84 | 85 | Once verified, the original digikam container may be deleted. 86 | 87 | ## Manual Migration 88 | Use [Migration Steps](#migration-steps). Only use this if you have a custom 89 | setup that did not follow original instructions. 90 | 91 | This assumes working knowledge and only covers major points. 92 | 93 | ### Setup new linuxserver container 94 | Run through [setup a new linuxserver/digikam container](#setup-a-new-linuxserver-digikam-container) 95 | 96 | This will get the new digikam container in the appropriate state for migration. 97 | 98 | ### Update rpufky digikam to latest release 99 | Standard upgrade steps. Use the `latest` tag for `rpufky/digikam` and update 100 | the image. Launch the container to update and shutdown. Only keep the container 101 | running if `/config` is not mounted externally. 102 | 103 | ### Migrate settings 104 | 105 | Migrate `digikamrc` to the new container config. 106 | 107 | ```bash 108 | cp -av "{NEW}/config/.config/digikamrc" "{NEW}/config/.config/digikamrc.orig" 109 | cp -av "{ORIGINAL}/config/xdg/config/digikamrc" "{NEW}/config/.config/digikamrc" 110 | ``` 111 | 112 | Migrate DBs. 113 | 114 | ```bash 115 | find "${NEW}/config" -type f -name "*.db" -exec mv -v {} {}.orig \; 116 | cp -av "${ORIGINAL}"/config/*.db "${NEW}/config" 117 | ``` 118 | 119 | Remember to set permissions on the copied files if different. Restart the 120 | linuxserver digikam container and verify settings are correct. Be aware that 121 | you may need to update reverse proxy or firewall rules for the new ports. 122 | 123 | Once verified, the original digikam container may be deleted. 124 | 125 | ## Setup a new linuxserver digikam container 126 | https://hub.docker.com/r/linuxserver/digikam 127 | 128 | Create a new digikam container, using the same settings as originally used 129 | creating the rpufky/digikam container. The `docker-compose.yml` file should be 130 | in a different location to preserve the original config. Use the **same** 131 | `data` location but a **new** `config` location. 132 | 133 | Adapt the following settings per your setup. 134 | 135 | `ls-digikam/docker-compose.yml` 136 | ```yaml 137 | --- 138 | version: "2.1" 139 | services: 140 | digikam: 141 | image: lscr.io/linuxserver/digikam 142 | container_name: ls-digikam # USE DIFFERENT CONTAINER NAME. 143 | network_mode: host 144 | environment: 145 | - PUID=1000 146 | - PGID=1000 147 | - UMASK=022 148 | - TZ=America/Los_Angeles 149 | - SUBFOLDER=/ 150 | - KEYBOARD=en-us-qwerty 151 | - AUTOLOGIN=true 152 | volumes: 153 | - /my/docker/service/NEW/config:/config # USE A NEW CONFIG LOCATION. 154 | - /my/photo/location:/data # USE SAME DATA LOCATION. 155 | ports: 156 | - "3000:3000" 157 | restart: unless-stopped 158 | ``` 159 | 160 | Start the container and explicitly set the following 161 | ```bash 162 | docker-compose up -d 163 | ``` 164 | 165 | ### Configure where you keep your images 166 |
Show GUI Screen 167 |

168 | 169 | ![digikam images][5k] 170 | 171 |

172 |
173 | 174 | * Manually set to `/data` for your images (or where your data is set to). 175 | 176 | ### Configure where you will store databases 177 |
Show GUI Screen 178 |

179 | 180 | ![digikam db][b7] 181 | 182 |

183 |
184 | 185 | * Type: `SQLite` 186 | * Manually set to `/config` for your db (or where your config is set to). 187 | * Set SQLite even if you are using a SQL backend. This will setup the initial 188 | container, and migrating the settings will configure SQL for you. 189 | 190 | ### Facial recognition training data 191 |
Show GUI Screen 192 |

193 | 194 | ![digikam faces][c8] 195 | 196 |

197 |
198 | 199 | * Download **~335MB** 200 | * One time download if `/config` is mounted outside of docker. 201 | 202 | All other settings will be overwritten when migration is completed. Once the 203 | facial recognition data is downloaded, shutdown the container for migration. 204 | 205 | ```bash 206 | docker-compose stop 207 | ``` 208 | 209 | The new linuxserver container is ready to migrate data to. 210 | 211 | ## File locations 212 | Files locations have changed in the linuxserver container. 213 | 214 | | type | rpufky/digikam | linuxserver/digikam | 215 | | ------------- | ---------------------------- | ------------------------- | 216 | | configuration | /config/xdg/config/digikamrc | /config/.config/digikamrc | 217 | | DB's | /config/*.db | /config/*.db | 218 | 219 | ## Background 220 | I originally created this image to fit my need for a WebUI docker-based photo 221 | management tool; I modeled this off of linuxserver images at the time and it 222 | quickly grew to become a massive success. 223 | 224 | Without getting into the technical back and forth, I moved away from docker 225 | containers a few years ago, but have maintained this image given the popularity 226 | and no drop-in replacement. Now that linuxserver has produced a viable digikam 227 | image, the original purpose for this image no longer exists; and I'm left 228 | solely maintaining software on a platform that I have not used as a daily 229 | driver in years. 230 | 231 | It's time to retire this original image and migrate to linuxserver images. When 232 | I used docker, linuxserver images were the only images I used if I didn't build 233 | them myself. You're in good hands. 234 | 235 | This repo will be archived on the next major digikam release and support will 236 | cease. Feel free to clone and maintain this if you need to, or spend a few 237 | minutes and migrate to linuxserver/digikam image. 238 | 239 | ## FAQS 240 | 241 | ### I need more time to migrate! 242 | If the timeline does not fit your needs; please fork and build your own image 243 | to use. This will be a 1:1 image of the current container. Be sure to update 244 | your docker config to use the new image. 245 | 246 | ### Can I continue to use this image? 247 | This image will be supported until the next major release. After that you 248 | should fork this repository and maintain it yourself. Be sure to update your 249 | image name in your docker config if you do so. 250 | 251 | There will be no support for the image once it is archived. 252 | 253 | ### How do I build it myself? 254 | A `Makefile` is provided to automatically verify and build from source. Read 255 | through the [build instructions](https://github.com/r-pufky/digikam#manually-building) 256 | and update the `Makefile` accordingly. 257 | 258 | ### What are the main differences? 259 | 1. Only WebGUI via rdesktop is supported. VNC connections are not supported. 260 | 1. It is now a full desktop environment. Digikam not longer restarts 261 | automatically if it crashes; right click on the desktop and re-launch it. 262 | 1. The top bar is remove and replaced by a dot on the left hand side for copy 263 | paste / keyboard operations. 264 | 1. International glyphs are supported but the keyboard input mechanism does 265 | not support this currently. This will be supported when the underlying 266 | library in the new container enables support. 267 | 1. The default port has changed from `5800` to `3000`. Either redirect this in 268 | the new container or update your reverse proxy. 269 | 270 | [5k]: https://github.com/r-pufky/digikam/blob/master/media/digikam-setup-images.png?raw=true 271 | [b7]: https://github.com/r-pufky/digikam/blob/master/media/digikam-setup-db.png?raw=true 272 | [c8]: https://github.com/r-pufky/digikam/blob/master/media/digikam-setup-faces.png?raw=true 273 | -------------------------------------------------------------------------------- /patches/docker-baseimage-gui.3077e2c.patch: -------------------------------------------------------------------------------- 1 | diff --git a/.github/workflows/build-baseimage.yml b/.github/workflows/build-baseimage.yml 2 | index 60998bd..be1d1b9 100644 3 | --- a/.github/workflows/build-baseimage.yml 4 | +++ b/.github/workflows/build-baseimage.yml 5 | @@ -1,8 +1,8 @@ 6 | name: Docker Baseimage CI 7 | 8 | env: 9 | - DOCKERHUB_USERNAME: jlesage 10 | - DOCKER_IMAGE_NAME: jlesage/baseimage-gui 11 | + DOCKERHUB_USERNAME: rpufky 12 | + DOCKER_IMAGE_NAME: rpufky/baseimage-gui 13 | 14 | on: 15 | push: 16 | diff --git a/Dockerfile b/Dockerfile 17 | index c8f42f5..f02ddc7 100644 18 | --- a/Dockerfile 19 | +++ b/Dockerfile 20 | @@ -4,7 +4,10 @@ 21 | # https://github.com/jlesage/docker-baseimage-gui 22 | # 23 | 24 | -ARG BASEIMAGE=unknown 25 | +#ARG BASEIMAGE=unknown 26 | +ARG BASEIMAGE=jlesage/baseimage:debian-11-v3.0.0-pre.6 27 | +ARG BUILDPLATFORM=linux/amd64 28 | + 29 | 30 | # Define the Alpine packages to be installed into the image. 31 | ARG ALPINE_PKGS="\ 32 | -------------------------------------------------------------------------------- /startapp.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | export HOME=/config 3 | export LC_ALL=${LC_ALL} 4 | export LANGUAGE=${LANGUAGE} 5 | export LANG=${LANG} 6 | update-locale LANG=${LANG} 7 | 8 | echo 9 | echo "-------------------------------------------------------------------------" 10 | echo "| DEPRECATION WARNING |" 11 | echo "-------------------------------------------------------------------------" 12 | echo "| |" 13 | echo "| Support will end on the next major release (8.0). See migration link. |" 14 | echo "| |" 15 | echo "| https://github.com/r-pufky/digikam/blob/master/migration.md |" 16 | echo "| |" 17 | echo "-------------------------------------------------------------------------" 18 | echo "| DEPRECATION WARNING |" 19 | echo "-------------------------------------------------------------------------" 20 | echo 21 | 22 | exec /digikam/AppRun 23 | --------------------------------------------------------------------------------