1 changed files with 27 additions and 15 deletions
			
			
		| @ -1,25 +1,37 @@ | |||
| name: build wg-dashboard | |||
| name: build and publish | |||
| 
 | |||
| on: | |||
|   push: | |||
|     branches: | |||
|       - master | |||
|       - 'main' | |||
| 
 | |||
| jobs: | |||
|   build: | |||
|   docker: | |||
|     runs-on: ubuntu-latest | |||
|     steps: | |||
|       - name: checkout code | |||
|       - | |||
|         name: Checkout | |||
|         uses: actions/checkout@v2 | |||
|       - name: install buildx | |||
|         id: buildx | |||
|         uses: crazy-max/ghaction-docker-buildx@v1 | |||
|       - | |||
|         name: Set up QEMU | |||
|         uses: docker/setup-qemu-action@v1 | |||
|       - | |||
|         name: Set up Docker Buildx | |||
|         uses: docker/setup-buildx-action@v1 | |||
|       - | |||
|         name: Login to DockerHub | |||
|         uses: docker/login-action@v1 | |||
|         with: | |||
|           version: latest | |||
|       - name: login to docker hub | |||
|         run: echo "${{ secrets.DOCKER_PASSWORD }}" | docker login -u "${{ secrets.DOCKER_USERNAME }}" --password-stdin | |||
|       - name: build the image | |||
|         run: | | |||
|           docker buildx build --push \ | |||
|             --tag perara/wg-manager:latest \ | |||
|             --platform linux/amd64 . | |||
|           username: ${{ secrets.DOCKER_USERNAME }} | |||
|           password: ${{ secrets.DOCKER_PASSWORD }} | |||
|       - | |||
|         name: Build and push | |||
|         uses: docker/build-push-action@v2 | |||
|         with: | |||
|           context: . | |||
|           platforms: linux/amd64,linux/arm64 | |||
|           push: true | |||
|           tags: user/app:latest | |||
| 
 | |||
| 
 | |||
| 
 | |||
|  | |||
					Loading…
					
					
				
		Reference in new issue