1
0
mirror of https://github.com/imapsync/imapsync.git synced 2024-11-17 00:02:29 +01:00
imapsync/FAQ.d/FAQ.Docker.txt

161 lines
5.1 KiB
Plaintext
Raw Permalink Normal View History

2020-04-11 01:15:57 +02:00
#!/bin/cat
2022-02-15 19:29:45 +01:00
# $Id: FAQ.Docker.txt,v 1.10 2021/07/12 21:22:14 gilles Exp gilles $
2020-04-11 01:15:57 +02:00
This document is also available online at
https://imapsync.lamiral.info/FAQ.d/
https://imapsync.lamiral.info/FAQ.d/FAQ.Docker.txt
2022-02-15 19:29:45 +01:00
======================================================================
Installing and using imapsync docker image
======================================================================
2020-04-11 01:15:57 +02:00
Questions answered in this FAQ are:
2021-05-01 17:46:04 +02:00
Q. How can I install and use the imapsync Docker image on my amd64 system?
Q. How can I install and use the imapsync Docker image on my i386 system?
2020-04-11 01:15:57 +02:00
Q. How can I install or update only the imapsync Docker image on my system?
Q. Where is the imapsync Docker hub location?
2021-05-01 17:46:04 +02:00
Q. How can I mask the passwords on the command line without mounting
inside the container?
2021-08-04 21:14:36 +02:00
Q. Why imapsync isn't logging to a file in Docker context.
How can I allow it?
2020-04-11 01:15:57 +02:00
Q. Any tips for the Docker Mailcow distribution?
2022-02-15 19:29:45 +01:00
Q. How can I build my own image?
Q. What do you do to update the docker hub image?
2020-04-11 01:15:57 +02:00
Now the questions again with their answers.
2022-02-15 19:29:45 +01:00
======================================================================
2021-05-01 17:46:04 +02:00
Q. How can I install and use the imapsync Docker image on my amd64 system?
2020-04-11 01:15:57 +02:00
R. Install Docker on your system. Once Docker is installed on your system,
2022-02-15 19:29:45 +01:00
all you have to do in order install and run imapsync is the command line:
2020-04-11 01:15:57 +02:00
docker run gilleslamiral/imapsync imapsync <usual imapsync arguments>
2022-02-15 19:29:45 +01:00
======================================================================
2021-05-01 17:46:04 +02:00
Q. How can I install and use the imapsync Docker image on my i386 system?
2022-02-15 19:29:45 +01:00
R1. You can't do it directly for now. It will throw this error when running it:
2021-05-01 17:46:04 +02:00
docker run gilleslamiral/imapsync imapsync
standard_init_linux.go:211: exec user process caused "exec format error"
I plan to make the image multi-plateform. Drop me a note if you are
eager to have it.
2022-02-15 19:29:45 +01:00
R2. Build the image on a i386 system with the exact same Dockerfile provided
and run it on your i386 system.
======================================================================
2020-04-11 01:15:57 +02:00
Q. How can I install or update only the imapsync Docker image on my system?
R. To install or update the imapsync image, run:
docker pull gilleslamiral/imapsync
2022-02-15 19:29:45 +01:00
======================================================================
2020-04-11 01:15:57 +02:00
Q. Where is the imapsync Docker hub location?
R. Here:
https://hub.docker.com/r/gilleslamiral/imapsync/
2022-02-15 19:29:45 +01:00
======================================================================
2021-05-01 17:46:04 +02:00
Q. How can I mask the passwords on the command line without mounting
anything inside the container?
R. Use a file defining the environment variables
IMAPSYNC_PASSWORD1 and IMAPSYNC_PASSWORD2
cat ./secret.txt
IMAPSYNC_PASSWORD1=secret1
IMAPSYNC_PASSWORD2=secret2
Use that file like this for a run:
docker run --env-file ./secret.txt gilleslamiral/imapsync imapsync ...
See:
https://docs.docker.com/engine/reference/commandline/run/#set-environment-variables--e---env---env-file
https://stackoverflow.com/a/30494145/491175
2022-02-15 19:29:45 +01:00
======================================================================
2021-08-04 21:14:36 +02:00
Q. Why imapsync isn't logging to a file in Docker context.
How can I allow it?
R. In Docker context, writing the log is disabled by default because you
don't have an easy access to the logfile after the sync. The logfile is
inside the docker and no longer available after the sync, unless
a special mount is done before.
2022-02-15 19:29:45 +01:00
Starting with imapsync release 2.113 the logging can be turned on
2021-08-04 21:14:36 +02:00
by using the option --log. You can add access to the logfile with a mount
or similar. See https://docs.docker.com/storage/volumes/"
See also
https://github.com/imapsync/imapsync/issues/283
2022-02-15 19:29:45 +01:00
======================================================================
2020-04-11 01:15:57 +02:00
Q. Any tips for the Docker Mailcow distribution?
R. With the Mailcow distribution, imapsync is running inside a Docker
container. Quoting Mathilde:
To make it work with Mailcow, options should be added like this:
--regexflag=s/\\Indexed//gi
Without spaces, without quotes.
See the original Mathilde's comment:
https://github.com/imapsync/imapsync/issues/201#issuecomment-559500077
2022-02-15 19:29:45 +01:00
======================================================================
Q. How can I build my own image?
R. Use the following command to build the image:
docker build -t gilleslamiral/imapsync .
with the Dockerfile in the current directory.
The latest Dockerfile can be found at
https://imapsync.lamiral.info/INSTALL.d/Dockerfile
or
https://hub.docker.com/r/gilleslamiral/imapsync
or
https://imapsync.lamiral.info/INSTALL.d/INSTALL.Docker_build.txt
======================================================================
Q. What do you do to update the docker hub image?
R. I do in my imapsync directory:
make docker_build
make docker_upload_docker_hub
Then I go to
https://hub.docker.com/r/gilleslamiral/imapsync
I edit and update the docker "Readme" with the last Dockerfile I used.
I also update INSTALL.Docker_build.txt with the last Dockerfile
I also update the last Dockerfile on the imapsync site with:
make upload_index
2020-04-11 01:15:57 +02:00
2022-02-15 19:29:45 +01:00
======================================================================
======================================================================