mirror of
				https://git.yrzr.tk/docker/gitlab-ce-arm64.git
				synced 2025-05-29 05:49:16 +08:00 
			
		
		
		
	.github/workflows/buildx.yml: add github action
This commit is contained in:
		
							parent
							
								
									b81a6fc4a7
								
							
						
					
					
						commit
						1fb23ff747
					
				
							
								
								
									
										50
									
								
								.github/workflows/buildx.yml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										50
									
								
								.github/workflows/buildx.yml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@ -0,0 +1,50 @@
 | 
			
		||||
name: buildx
 | 
			
		||||
 | 
			
		||||
on:
 | 
			
		||||
  push:
 | 
			
		||||
    tags:
 | 
			
		||||
      - "*"
 | 
			
		||||
 | 
			
		||||
jobs:
 | 
			
		||||
  docker:
 | 
			
		||||
    runs-on: ubuntu-latest
 | 
			
		||||
    steps:
 | 
			
		||||
      - name: Checkout
 | 
			
		||||
        uses: actions/checkout@v3
 | 
			
		||||
      - name: Set up QEMU
 | 
			
		||||
        uses: docker/setup-qemu-action@v2
 | 
			
		||||
      - name: Set up Docker Buildx
 | 
			
		||||
        uses: docker/setup-buildx-action@v2
 | 
			
		||||
      - name: Login to container registry
 | 
			
		||||
        uses: docker/login-action@v2
 | 
			
		||||
        with:
 | 
			
		||||
          username: ${{ secrets.REGISTRY_USERNAME }}
 | 
			
		||||
          password: ${{ secrets.REGISTRY_TOKEN }}
 | 
			
		||||
      - name: Set variables
 | 
			
		||||
        shell: bash
 | 
			
		||||
        run: |
 | 
			
		||||
          echo "GITLAB_DIR=omnibus-gitlab" >> $GITHUB_ENV
 | 
			
		||||
          echo "DOCKER_DIR=omnibus-gitlab/docker" >> $GITHUB_ENV
 | 
			
		||||
          echo "GITLAB_REF_TAG=$(echo ${{ github.ref_name }} | sed 's/\-/\+/')" >> $GITHUB_ENV
 | 
			
		||||
      - name: Check out https://github.com/gitlabhq/omnibus-gitlab.git
 | 
			
		||||
        uses: actions/checkout@v3
 | 
			
		||||
        with:
 | 
			
		||||
          repository: gitlabhq/omnibus-gitlab
 | 
			
		||||
          path: ${{ env.GITLAB_DIR }}
 | 
			
		||||
          ref: ${{ env.GITLAB_REF_TAG }}
 | 
			
		||||
      - name: Perpare for building
 | 
			
		||||
        shell: bash
 | 
			
		||||
        run: |
 | 
			
		||||
          echo "PACKAGECLOUD_REPO=gitlab-ce" > ./${{ env.DOCKER_DIR }}/RELEASE
 | 
			
		||||
          echo "RELEASE_PACKAGE=gitlab-ce" >> ./${{ env.DOCKER_DIR }}/RELEASE
 | 
			
		||||
          echo "RELEASE_VERSION=${{ github.ref_name }}"  >> ./${{ env.DOCKER_DIR }}/RELEASE
 | 
			
		||||
          echo "DOWNLOAD_URL=https://packages.gitlab.com/gitlab/gitlab-ce/packages/ubuntu/focal/gitlab-ce_${{ github.ref_name }}_arm64.deb/download.deb" >> ./${{ env.DOCKER_DIR }}/RELEASE
 | 
			
		||||
          cat ./${{ env.DOCKER_DIR }}/RELEASE
 | 
			
		||||
          sed -i 's/\-recommends/\-recommends libatomic1/' ./${{ env.DOCKER_DIR }}/Dockerfile
 | 
			
		||||
      - name: Build and Push Image
 | 
			
		||||
        uses: docker/build-push-action@v4
 | 
			
		||||
        with:
 | 
			
		||||
          context: ${{ env.DOCKER_DIR }}
 | 
			
		||||
          platforms: linux/arm64
 | 
			
		||||
          push: true
 | 
			
		||||
          tags: yrzr/gitlab-ce-arm64v8:${{ github.ref_name }}
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user