mirror of
				https://github.com/f-droid/fdroidserver.git
				synced 2025-11-04 14:30:30 +03:00 
			
		
		
		
	Merge branch 'git-tag-docker-tag' into 'master'
gitlab-ci: sanitize git ref names for use as docker tags See merge request fdroid/fdroidserver!1289
This commit is contained in:
		
						commit
						6b9db76c8b
					
				
					 1 changed files with 2 additions and 1 deletions
				
			
		| 
						 | 
				
			
			@ -574,9 +574,10 @@ docker:
 | 
			
		|||
  services:
 | 
			
		||||
    - docker:dind
 | 
			
		||||
  variables:
 | 
			
		||||
    TEST_IMAGE: $CI_REGISTRY_IMAGE:$CI_BUILD_REF_NAME
 | 
			
		||||
    RELEASE_IMAGE: $CI_REGISTRY_IMAGE:buildserver
 | 
			
		||||
  script:
 | 
			
		||||
    # git ref names can contain many chars that are not allowed in docker tags
 | 
			
		||||
    - export TEST_IMAGE=$CI_REGISTRY_IMAGE:$(printf $CI_BUILD_REF_NAME | sed 's,[^a-zA-Z0-9_.-],_,g')
 | 
			
		||||
    - cd buildserver
 | 
			
		||||
    - docker build -t $TEST_IMAGE --build-arg GIT_REV_PARSE_HEAD=$(git rev-parse HEAD) .
 | 
			
		||||
    - docker tag $TEST_IMAGE $RELEASE_IMAGE
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue