# The port the application will listen to. port: 3000 logs: # Accepted values, in order of severity: DEBUG, INFO, WARN, ERROR, FATAL, PANIC. # Messages at and above the selected level will be logged. level: "INFO" # Accepted values: text, json. # When a TTY is not attached, the output will be in the defined format. formatter: "text" # You don't like a library which is used for a conversion? You want to handle a new file type? # You may provide here your own implementation! commands: # Some libraries like unoconv cannot perform concurrent conversions. That's why the API does only one conversion at a time. # If your current implementation uses libraries which are able to perform concurrent conversions, you may # change this value to false. lock: true # Unlike others commands' templates, you have access to FilesPaths instead of FilePath: it gathers all PDF files which should be merged. merge: template: "pdftk {{ range $filePath := .FilesPaths }} {{ $filePath }} {{ end }} cat output {{ .ResultFilePath }}" interpreter: "/bin/sh -c" timeout: 30 conversions: # The command template: you have access to FilePath and ResultFilePath variables. - template: "markdown-pdf {{ .FilePath }} -o {{ .ResultFilePath }}" # The binary which will call the command. interpreter: "/bin/sh -c" # Duration in seconds after which the command will be killed if it has not finished. timeout: 30 # Files with the following extensions will be converted by the current command. extensions: - ".md" - template: "xvfb-run -e /dev/stdout wkhtmltopdf {{ .FilePath }} {{ .ResultFilePath }}" interpreter: "/bin/sh -c" timeout: 30 extensions: - ".html" - ".htm" - template: "unoconv --format pdf --output \"{{ .ResultFilePath }}\" \"{{ .FilePath }}\"" interpreter: "/bin/sh -c" timeout: 30 extensions: - ".doc" - ".docx" - ".odt" - ".xls" - ".xlsx" - ".ods" - ".ppt" - ".pptx" - ".odp"