Using convert utility we can join multiple image files (png, jpeg, pdf) into one pdf.

convert -density 250 file1.pdf file2.JPG file3.pdf -compress JPEG -quality 70 combined.pdf

we use JPEG compression with quality =90 for images inside PDF. Otherwise the PDF will be too large.

source