mirror of
				https://github.com/DarkflameUniverse/DarkflameServer.git
				synced 2025-10-31 12:41:55 +00:00 
			
		
		
		
	 9116317834
			
		
	
	9116317834
	
	
	
		
			
			* greatly simplify docker * back to gcc since I can't the libs to load properly * fix typo add set -e to entrypoint better copy of entrypoint.sh and use proper entrypoint * use debian instead of gcc for runtime comment and organize it a bit drop gcc to 12 since we are using debian 12 as well * explicitly include mariadb libs * Make the server not crash in the case we are using only env-vars make the dockerfile have configs in the expected location incase of bypassing entrypoint.sh * remove unneede var from example, since it's in the container now * coments to dockerfile * Revert master server changes * Resolve conflicting port options between chat, master, and world move chat_server_port to shared since it's used by world and chat * Don't error if file does not exists when updating a config option move update before and use bin dir var
		
			
				
	
	
		
			57 lines
		
	
	
		
			1.4 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
			
		
		
	
	
			57 lines
		
	
	
		
			1.4 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
| name: ci
 | |
| 
 | |
| on:
 | |
|   push:
 | |
|     branches:
 | |
|       - "main"
 | |
|     tags:
 | |
|       - "v*.*.*"
 | |
|   pull_request:
 | |
|     branches:
 | |
|       - "main"
 | |
| 
 | |
| env:
 | |
|   REGISTRY: ghcr.io
 | |
|   IMAGE_NAME: ${{ github.repository }}
 | |
| 
 | |
| jobs:
 | |
|   build-and-push-image:
 | |
|     runs-on: ubuntu-latest
 | |
|     permissions:
 | |
|       contents: read
 | |
|       packages: write
 | |
| 
 | |
|     steps:
 | |
|       - name: Checkout repository
 | |
|         uses: actions/checkout@v4
 | |
|         with:
 | |
|           submodules: recursive
 | |
| 
 | |
|       - name: Log in to the Container registry
 | |
|         uses: docker/login-action@v3
 | |
|         with:
 | |
|           registry: ${{ env.REGISTRY }}
 | |
|           username: ${{ github.actor }}
 | |
|           password: ${{ secrets.GITHUB_TOKEN }}
 | |
| 
 | |
|       - name: Extract metadata (tags, labels) for Docker
 | |
|         id: meta
 | |
|         uses: docker/metadata-action@v5
 | |
|         with:
 | |
|           images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
 | |
|           # generate Docker tags based on the following events/attributes
 | |
|           tags: |
 | |
|             type=ref,event=pr
 | |
|             type=raw,value=latest,enable=${{ github.ref == format('refs/heads/{0}', 'main') }}
 | |
|             type=semver,pattern={{version}}
 | |
|             type=semver,pattern={{major}}.{{minor}}
 | |
|             type=semver,pattern={{major}}
 | |
| 
 | |
|       - name: Build and push Docker image
 | |
|         uses: docker/build-push-action@v5
 | |
|         with:
 | |
|           context: .
 | |
|           push: ${{ github.event_name != 'pull_request' }}
 | |
|           tags: ${{ steps.meta.outputs.tags }}
 | |
|           labels: ${{ steps.meta.outputs.labels }}
 |