瀏覽代碼

build for linux

sunguroku 5 年之前
父節點
當前提交
224f7e519e
共有 1 個文件被更改,包括 10 次插入8 次删除
  1. 10 8
      .github/workflows/gcr.yaml

+ 10 - 8
.github/workflows/gcr.yaml

@@ -1,8 +1,7 @@
 name: Build, Push to GCR.
 name: Build, Push to GCR.
 on:
 on:
   push:
   push:
-    branches:
-      - staging
+    branches: staging
 jobs:
 jobs:
   login-build-push:
   login-build-push:
     runs-on: ubuntu-latest
     runs-on: ubuntu-latest
@@ -33,9 +32,12 @@ jobs:
       uses: docker/setup-qemu-action@v1
       uses: docker/setup-qemu-action@v1
     - name: Set up Docker Buildx
     - name: Set up Docker Buildx
       uses: docker/setup-buildx-action@v1
       uses: docker/setup-buildx-action@v1
-    - name: Build
-      run: |
-        DOCKER_BUILDKIT=1 docker build . -t gcr.io/porter-dev-273614/porter-prov:latest -f ./docker/dev.Dockerfile
-    - name: Push
-      run: |
-        docker push gcr.io/porter-dev-273614/porter-prov:latest
+    - name: Build and push
+      uses: docker/build-push-action@v2
+      with:
+        context: .
+        file: ./docker/dev.Dockerfile
+        platforms: linux/386,linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64,linux/ppc64le,linux/s390x
+        push: true
+        tags: |
+          gcr.io/porter-dev-273614/porter-prov:latest