mirror of
				https://github.com/paperless-ngx/paperless-ngx.git
				synced 2025-11-03 19:17:13 -05:00 
			
		
		
		
	Sort package arguments in Dockerfile
This applies the Dockerfile best practices from dockerhub. Also it adds `--no-cache` to the `apk add` calls. This has got the same effect like `apk update`, but doesn't store the package lists in the container.
This commit is contained in:
		
							parent
							
								
									94c2950afe
								
							
						
					
					
						commit
						a590fdaec6
					
				
							
								
								
									
										29
									
								
								Dockerfile
									
									
									
									
									
								
							
							
						
						
									
										29
									
								
								Dockerfile
									
									
									
									
									
								
							@ -12,11 +12,30 @@ COPY scripts/docker-entrypoint.sh /sbin/docker-entrypoint.sh
 | 
			
		||||
ENV PAPERLESS_EXPORT_DIR=/export \
 | 
			
		||||
    PAPERLESS_CONSUMPTION_DIR=/consume
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
RUN apk update --no-cache && apk add python3 gnupg libmagic libpq bash shadow curl \
 | 
			
		||||
        sudo poppler tesseract-ocr imagemagick ghostscript unpaper optipng && \
 | 
			
		||||
    apk add --virtual .build-dependencies \
 | 
			
		||||
        python3-dev poppler-dev postgresql-dev gcc g++ musl-dev zlib-dev jpeg-dev && \
 | 
			
		||||
RUN apk add --no-cache \
 | 
			
		||||
      bash \
 | 
			
		||||
      curl \
 | 
			
		||||
      ghostscript \
 | 
			
		||||
      gnupg \
 | 
			
		||||
      imagemagick \
 | 
			
		||||
      libmagic \
 | 
			
		||||
      libpq \
 | 
			
		||||
      optipng \
 | 
			
		||||
      poppler \
 | 
			
		||||
      python3 \
 | 
			
		||||
      shadow \
 | 
			
		||||
      sudo \
 | 
			
		||||
      tesseract-ocr \
 | 
			
		||||
      unpaper && \
 | 
			
		||||
    apk add --no-cache --virtual .build-dependencies \
 | 
			
		||||
      g++ \
 | 
			
		||||
      gcc \
 | 
			
		||||
      jpeg-dev \
 | 
			
		||||
      musl-dev \
 | 
			
		||||
      poppler-dev \
 | 
			
		||||
      postgresql-dev \
 | 
			
		||||
      python3-dev \
 | 
			
		||||
      zlib-dev && \
 | 
			
		||||
# Install python dependencies
 | 
			
		||||
    python3 -m ensurepip && \
 | 
			
		||||
    rm -r /usr/lib/python*/ensurepip && \
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user