📦 Migrate to ghcr.io
This commit is contained in:
		
							parent
							
								
									9b40e10904
								
							
						
					
					
						commit
						0453267020
					
				
							
								
								
									
										10
									
								
								.github/workflows/build.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										10
									
								
								.github/workflows/build.yml
									
									
									
									
										vendored
									
									
								
							@ -9,11 +9,11 @@ jobs:
 | 
				
			|||||||
      - uses: actions/checkout@master
 | 
					      - uses: actions/checkout@master
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      - name: Log into registry
 | 
					      - name: Log into registry
 | 
				
			||||||
        run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login docker.pkg.github.com -u ${{ github.actor }} --password-stdin
 | 
					        run: echo "${{ secrets.CR_PAT }}" | docker login ghcr.io -u ${{ github.repository_owner }} --password-stdin
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      - name: docker
 | 
					      - name: docker
 | 
				
			||||||
        run: |
 | 
					        run: |
 | 
				
			||||||
          docker build -t docker.pkg.github.com/${{ github.repository }}/agent -f Dockerfile.agent .
 | 
					          docker build -t ghcr.io/${{ github.repository_owner }}/nezha-agent -f Dockerfile.agent .
 | 
				
			||||||
          docker build -t docker.pkg.github.com/${{ github.repository }}/dashboard -f Dockerfile.dashboard .
 | 
					          docker build -t ghcr.io/${{ github.repository_owner }}/nezha-dashboard -f Dockerfile.dashboard .
 | 
				
			||||||
          docker push docker.pkg.github.com/${{ github.repository }}/agent
 | 
					          docker push ghcr.io/${{ github.repository_owner }}/nezha-agent
 | 
				
			||||||
          docker push docker.pkg.github.com/${{ github.repository }}/dashboard
 | 
					          docker push ghcr.io/${{ github.repository_owner }}/nezha-dashboard
 | 
				
			||||||
 | 
				
			|||||||
@ -34,7 +34,7 @@ C/S 采用 gRPC 通信,客户端通过添加主机生成的单独 Token 上报
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    services:
 | 
					    services:
 | 
				
			||||||
      dashboard:
 | 
					      dashboard:
 | 
				
			||||||
        image: docker.pkg.github.com/naiba/nezha/dashboard
 | 
					        image: ghcr.io/naiba/nezha-dashboard
 | 
				
			||||||
        restart: always
 | 
					        restart: always
 | 
				
			||||||
        volumes:
 | 
					        volumes:
 | 
				
			||||||
          - ./data:/dashboard/data
 | 
					          - ./data:/dashboard/data
 | 
				
			||||||
@ -42,7 +42,7 @@ C/S 采用 gRPC 通信,客户端通过添加主机生成的单独 Token 上报
 | 
				
			|||||||
          - 8008:80
 | 
					          - 8008:80
 | 
				
			||||||
          - 5555:5555
 | 
					          - 5555:5555
 | 
				
			||||||
      agent:
 | 
					      agent:
 | 
				
			||||||
        image: docker.pkg.github.com/naiba/nezha/agent
 | 
					        image: ghcr.io/naiba/nezha-agent
 | 
				
			||||||
        restart: always
 | 
					        restart: always
 | 
				
			||||||
        depends_on:
 | 
					        depends_on:
 | 
				
			||||||
          - dashboard
 | 
					          - dashboard
 | 
				
			||||||
@ -123,7 +123,7 @@ C/S 采用 gRPC 通信,客户端通过添加主机生成的单独 Token 上报
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    services:
 | 
					    services:
 | 
				
			||||||
      agent:
 | 
					      agent:
 | 
				
			||||||
        image: docker.pkg.github.com/naiba/nezha/agent
 | 
					        image: ghcr.io/naiba/nezha-agent
 | 
				
			||||||
        restart: always
 | 
					        restart: always
 | 
				
			||||||
        environment:
 | 
					        environment:
 | 
				
			||||||
          - ID=1 #节点ID,启动后在管理后台添加后显示
 | 
					          - ID=1 #节点ID,启动后在管理后台添加后显示
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user