wsimageconvert.cfg file in the auto-konvertierung directory.
The file has two sections. Basic controls what applies to the entire run, that is, transfer lists and the handling of subdirectories. Convert contains one +Entry subsection per target format, with source, target, file type, and the arguments for the conversion program.
To edit the file, download it, change it, and upload it back to the server.
Guide: Image converter
File structure
Basic
Transfer lists
A transfer list is a text file containing all files that a run has converted. It serves as a handover to downstream systems that need to know which images are new.TransferListDirectory is required as soon as TransferList-Allow is set to yes. You must create the directory manually on the server beforehand; the converter doesn’t create it.
TransferListSrcDirectory is optional. Without this parameter, all converted images end up in the list. With it, only those from the specified subdirectory do; all others are left out. TransferListRemoveSrcDirectory can only be used together with TransferListSrcDirectory and strips its name from the entries.
The file name of a transfer list consists of the date and a sequential number that restarts each day.
Subdirectories
You can create subdirectories in the source directoryauto-konvertierung/quellbilder, for example auto-konvertierung/quellbilder/produkte. The converter searches the source directory including all its subdirectories for files.
By default, all converted files are placed flat, directly in the target directory. The structure from the source directory is lost in the process.
KeepSubDirectories = yes replicates it in the target directory and creates missing directories automatically.
DeleteSrcSubDirectories = yes cleans up the subdirectories in the source directory after the run. A directory is deleted only if it no longer contains any images.
Convert
One +Entry subsection per target format. A source image passes through all entries that match it and thus produces multiple outputs in different sizes and formats.
Required parameters
Name appears in the online service area in the Image converter service on the start page under the heading “Konvertierungs-Formate”. Choose the text so that you can recognize the format there.
The converter normalizes the path in
DestDir so that it can’t lead outside the shop directory. Paths with .. therefore have no effect.Restricting the source
Both settings refer to subdirectories of
auto-konvertierung/quellbilder.
SrcDir, all directories including the main directory are considered. With SrcDir, only the listed ones are; all others are ignored. You usually need ExclDir only when no SrcDir is set.
ExclDir compares the beginning of the path, not an arbitrary part of it. ExclDir = produkte therefore excludes produkte/gross, but not archiv/produkte. Spaces around the directory names are removed. Neither of these is documented; both have been added here.File type
If
Type is left empty, the file keeps its type. The following table shows which conversions are possible.
Conversion arguments
ConvertArgs contains the command-line arguments that are passed to ImageMagick. This is where you define what happens to the file, such as cropping, padding, scaling, or compressing.
The extensions are recognized regardless of upper and lower case.
The converter splits the arguments at spaces. An argument value that itself contains a space therefore can’t be passed. This isn’t documented and has been added here.
Converting to webp
For webp, the converter works in two stages, because ImageMagick doesn’t generate this format on the platform in use.- ImageMagick applies the changes from
ConvertArgsand writes a temporary file. - The
cwebpprogram converts this temporary file to webp using the arguments fromConvertArgs-Webp.
cwebp in Google’s documentation at developers.google.com/speed/webp/docs/cwebp.
What happens to faulty source files
The converter checks each source file twice: first the file extension, then the first bytes of the file to determine whether the content really matches the specified format.When something doesn’t work
You can find the error messages of a run in the online service area in the Image converter service.
