Granty1 4 years ago
parent
commit
c3b8f10bc2
2 changed files with 31 additions and 6 deletions
  1. 4 6
      .github/workflow/go.yml
  2. 27 0
      .github/workflows/go.yml

+ 4 - 6
.github/workflow/go.yml

@@ -2,15 +2,11 @@ name: Go
 
 on:
   push:
-    branches: [ master ]
-  pull_request:
-    branches: [ master ]
-
+    branches: [ action-ci ]
 jobs:
-
   build:
     name: Build
-    runs-on: ubuntu-latest
+    runs-on: VM_0_11_centos
     steps:
 
     - name: Set up Go 1.13
@@ -32,6 +28,8 @@ jobs:
 
     - name: Build
       run: |
+        pwd
+        ls -la
         cd server
         go build -v .
 

+ 27 - 0
.github/workflows/go.yml

@@ -0,0 +1,27 @@
+name: Go
+
+on:
+  push:
+    branches: [ action-ci ]
+
+jobs:
+
+  build:
+    name: Build
+    runs-on: [ VM_0_11_centos ]
+    steps:
+    - name: Get dependencies
+      run: |
+        go get -v -t -d ./...
+        if [ -f Gopkg.toml ]; then
+            curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
+            dep ensure
+        fi
+
+    - name: Build
+      run: |
+        pwd
+        ls -la
+        cd server
+        go build -v .
+