Change Dockerfile to upgrade packages when building (#26922)
This commit is contained in:
		
							
								
								
									
										7
									
								
								.github/workflows/build-container-image.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										7
									
								
								.github/workflows/build-container-image.yml
									
									
									
									
										vendored
									
									
								
							@@ -4,6 +4,9 @@ on:
 | 
				
			|||||||
      platforms:
 | 
					      platforms:
 | 
				
			||||||
        required: true
 | 
					        required: true
 | 
				
			||||||
        type: string
 | 
					        type: string
 | 
				
			||||||
 | 
					      cache:
 | 
				
			||||||
 | 
					        type: boolean
 | 
				
			||||||
 | 
					        default: true
 | 
				
			||||||
      use_native_arm64_builder:
 | 
					      use_native_arm64_builder:
 | 
				
			||||||
        type: boolean
 | 
					        type: boolean
 | 
				
			||||||
      push_to_images:
 | 
					      push_to_images:
 | 
				
			||||||
@@ -92,5 +95,5 @@ jobs:
 | 
				
			|||||||
          push: ${{ inputs.push_to_images != '' }}
 | 
					          push: ${{ inputs.push_to_images != '' }}
 | 
				
			||||||
          tags: ${{ steps.meta.outputs.tags }}
 | 
					          tags: ${{ steps.meta.outputs.tags }}
 | 
				
			||||||
          labels: ${{ steps.meta.outputs.labels }}
 | 
					          labels: ${{ steps.meta.outputs.labels }}
 | 
				
			||||||
          cache-from: type=gha
 | 
					          cache-from: ${{ inputs.cache && 'type=gha' }}
 | 
				
			||||||
          cache-to: type=gha,mode=max
 | 
					          cache-to: ${{ inputs.cache && 'type=gha,mode=max' }}
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										1
									
								
								.github/workflows/build-nightly.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										1
									
								
								.github/workflows/build-nightly.yml
									
									
									
									
										vendored
									
									
								
							@@ -26,6 +26,7 @@ jobs:
 | 
				
			|||||||
    with:
 | 
					    with:
 | 
				
			||||||
      platforms: linux/amd64,linux/arm64
 | 
					      platforms: linux/amd64,linux/arm64
 | 
				
			||||||
      use_native_arm64_builder: true
 | 
					      use_native_arm64_builder: true
 | 
				
			||||||
 | 
					      cache: false
 | 
				
			||||||
      push_to_images: |
 | 
					      push_to_images: |
 | 
				
			||||||
        tootsuite/mastodon
 | 
					        tootsuite/mastodon
 | 
				
			||||||
        ghcr.io/mastodon/mastodon
 | 
					        ghcr.io/mastodon/mastodon
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										2
									
								
								.github/workflows/build-releases.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										2
									
								
								.github/workflows/build-releases.yml
									
									
									
									
										vendored
									
									
								
							@@ -17,6 +17,8 @@ jobs:
 | 
				
			|||||||
      push_to_images: |
 | 
					      push_to_images: |
 | 
				
			||||||
        tootsuite/mastodon
 | 
					        tootsuite/mastodon
 | 
				
			||||||
        ghcr.io/mastodon/mastodon
 | 
					        ghcr.io/mastodon/mastodon
 | 
				
			||||||
 | 
					      # Do not use cache when building releases, so apt update is always ran and the release always contain the latest packages
 | 
				
			||||||
 | 
					      cache: false
 | 
				
			||||||
      # Only tag with latest when ran against the latest stable branch
 | 
					      # Only tag with latest when ran against the latest stable branch
 | 
				
			||||||
      # This needs to be updated after each minor version release
 | 
					      # This needs to be updated after each minor version release
 | 
				
			||||||
      flavor: |
 | 
					      flavor: |
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -17,6 +17,7 @@ COPY Gemfile* package.json yarn.lock /opt/mastodon/
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
# hadolint ignore=DL3008
 | 
					# hadolint ignore=DL3008
 | 
				
			||||||
RUN apt-get update && \
 | 
					RUN apt-get update && \
 | 
				
			||||||
 | 
					    apt-get -yq dist-upgrade && \
 | 
				
			||||||
    apt-get install -y --no-install-recommends build-essential \
 | 
					    apt-get install -y --no-install-recommends build-essential \
 | 
				
			||||||
        git \
 | 
					        git \
 | 
				
			||||||
        libicu-dev \
 | 
					        libicu-dev \
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user