From 29dc5f66b864df215f376469cd5211c8b0da86d8 Mon Sep 17 00:00:00 2001 From: Kyle Carberry Date: Tue, 1 Nov 2022 13:56:33 -0700 Subject: [PATCH] experiment: Switch to BuildJet Linux Runners (#4846) --- .github/workflows/coder.yaml | 10 +++++----- .github/workflows/release.yaml | 2 +- tailnet/conn.go | 3 ++- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/.github/workflows/coder.yaml b/.github/workflows/coder.yaml index 295056905a..5f9557e69a 100644 --- a/.github/workflows/coder.yaml +++ b/.github/workflows/coder.yaml @@ -89,7 +89,7 @@ jobs: style-lint-golangci: name: style/lint/golangci timeout-minutes: 5 - runs-on: ubuntu-latest + runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }} steps: - uses: actions/checkout@v3 - uses: actions/setup-go@v3 @@ -171,7 +171,7 @@ jobs: gen: name: "style/gen" timeout-minutes: 8 - runs-on: ubuntu-latest + runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }} needs: changes if: needs.changes.outputs.docs-only == 'false' steps: @@ -276,7 +276,7 @@ jobs: test-go: name: "test/go" - runs-on: ${{ matrix.os }} + runs-on: ${{ matrix.os == 'ubuntu-latest' && github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || matrix.os }} timeout-minutes: 20 strategy: matrix: @@ -356,7 +356,7 @@ jobs: test-go-postgres: name: "test/go/postgres" - runs-on: ubuntu-latest + runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }} # This timeout must be greater than the timeout set by `go test` in # `make test-postgres` to ensure we receive a trace of running # goroutines. Setting this to the timeout +5m should work quite well @@ -417,7 +417,7 @@ jobs: deploy: name: "deploy" - runs-on: ubuntu-latest + runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }} timeout-minutes: 30 needs: changes if: | diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index a209df4343..1d8a85287d 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -26,7 +26,7 @@ env: jobs: release: - runs-on: ubuntu-latest + runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }} env: # Necessary for Docker manifest DOCKER_CLI_EXPERIMENTAL: "enabled" diff --git a/tailnet/conn.go b/tailnet/conn.go index 76577c8f56..108a7cc5dd 100644 --- a/tailnet/conn.go +++ b/tailnet/conn.go @@ -33,6 +33,7 @@ import ( "tailscale.com/wgengine/router" "tailscale.com/wgengine/wgcfg/nmcfg" + "github.com/coder/coder/coderd/database" "github.com/coder/coder/cryptorand" "cdr.dev/slog" @@ -447,7 +448,7 @@ func (c *Conn) sendNode() { } node := &Node{ ID: c.netMap.SelfNode.ID, - AsOf: c.lastStatus, + AsOf: database.Now(), Key: c.netMap.SelfNode.Key, Addresses: c.netMap.SelfNode.Addresses, AllowedIPs: c.netMap.SelfNode.AllowedIPs,