]> go.fuhry.dev Git - fsnotify.git/commitdiff
Run FreeBSD CI on Cirrus
authorMartin Tournoij <martin@arp242.net>
Wed, 16 Nov 2022 02:26:34 +0000 (03:26 +0100)
committerMartin Tournoij <martin@arp242.net>
Wed, 16 Nov 2022 02:32:04 +0000 (03:32 +0100)
.cirrus.yml [new file with mode: 0644]
.github/workflows/test.yml

diff --git a/.cirrus.yml b/.cirrus.yml
new file mode 100644 (file)
index 0000000..89cd022
--- /dev/null
@@ -0,0 +1,12 @@
+freebsd_task:
+  name: 'FreeBSD'
+  freebsd_instance:
+    image_family: freebsd-13-1
+  install_script:
+    - pkg update -f
+    - pkg install -y go
+  test_script:
+      # run tests as user "cirrus" instead of root
+    - pw useradd cirrus -m
+    - chown -R cirrus:cirrus .
+    - sudo -u cirrus go test -race ./...
index 23431e7442ca13f0239e57a97da95d301a87a701..98b86ea31623449660ed46f09b43da38fa6fe28c 100644 (file)
@@ -72,22 +72,6 @@ jobs:
         run: |
           go test -race ./...
 
-  # FreeBSD
-  testFreeBSD:
-    runs-on: macos-12
-    name: test (freebsd, 1.18)
-    steps:
-      - uses: actions/checkout@v3
-      - name: test (freebsd, 1.18)
-        id: test
-        uses: vmactions/freebsd-vm@v0
-        with:
-          usesh: true
-          prepare: pkg install -y go
-          run: |
-            pw user add -n action -m
-            su action -c 'go test -race ./...'
-
   # OpenBSD; no -race as the VM doesn't include the comp set.
   #
   # TODO: should probably add this, but on my local machine the tests time out