Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitd38027c

Browse files
committed
feat(flake.nix): switch dogfood dev image to buildNixShellImage from dockerTools
Change-Id: I4e011fe3a19d9a1375fbfd5223c910e59d66a5d9Signed-off-by: Thomas Kosiewski <tk@coder.com>
1 parentb44ae40 commitd38027c

File tree

34 files changed

+1770
-1754
lines changed

34 files changed

+1770
-1754
lines changed

‎.dockerignore

Lines changed: 0 additions & 6 deletions
This file was deleted.

‎.github/actions/setup-sqlc/action.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ runs:
77
-name:Setup sqlc
88
uses:sqlc-dev/setup-sqlc@c0209b9199cd1cce6a14fc27cabcec491b651761# v4.0.0
99
with:
10-
sqlc-version:"1.25.0"
10+
sqlc-version:"1.27.0"

‎.github/workflows/ci.yaml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -251,16 +251,16 @@ jobs:
251251
-name:go install tools
252252
run:|
253253
go install google.golang.org/protobuf/cmd/protoc-gen-go@v1.30
254-
go install storj.io/drpc/cmd/protoc-gen-go-drpc@v0.0.33
254+
go install storj.io/drpc/cmd/protoc-gen-go-drpc@v0.0.34
255255
go install golang.org/x/tools/cmd/goimports@latest
256-
go install github.com/mikefarah/yq/v4@v4.30.6
257-
go install go.uber.org/mock/mockgen@v0.4.0
256+
go install github.com/mikefarah/yq/v4@v4.44.3
257+
go install go.uber.org/mock/mockgen@v0.5.0
258258
259259
-name:Install Protoc
260260
run:|
261261
mkdir -p /tmp/proto
262262
pushd /tmp/proto
263-
curl -L -o protoc.zip https://github.com/protocolbuffers/protobuf/releases/download/v23.3/protoc-23.3-linux-x86_64.zip
263+
curl -L -o protoc.zip https://github.com/protocolbuffers/protobuf/releases/download/v23.4/protoc-23.4-linux-x86_64.zip
264264
unzip protoc.zip
265265
cp -r ./bin/* /usr/local/bin
266266
cp -r ./include /usr/local/bin/include
@@ -850,7 +850,7 @@ jobs:
850850
run:|
851851
mkdir -p /tmp/proto
852852
pushd /tmp/proto
853-
curl -L -o protoc.zip https://github.com/protocolbuffers/protobuf/releases/download/v23.3/protoc-23.3-linux-x86_64.zip
853+
curl -L -o protoc.zip https://github.com/protocolbuffers/protobuf/releases/download/v23.4/protoc-23.4-linux-x86_64.zip
854854
unzip protoc.zip
855855
cp -r ./bin/* /usr/local/bin
856856
cp -r ./include /usr/local/bin/include
@@ -862,10 +862,10 @@ jobs:
862862
-name:Install go tools
863863
run:|
864864
go install google.golang.org/protobuf/cmd/protoc-gen-go@v1.30
865-
go install storj.io/drpc/cmd/protoc-gen-go-drpc@v0.0.33
865+
go install storj.io/drpc/cmd/protoc-gen-go-drpc@v0.0.34
866866
go install golang.org/x/tools/cmd/goimports@latest
867-
go install github.com/mikefarah/yq/v4@v4.30.6
868-
go install go.uber.org/mock/mockgen@v0.4.0
867+
go install github.com/mikefarah/yq/v4@v4.44.3
868+
go install go.uber.org/mock/mockgen@v0.5.0
869869
870870
-name:Setup sqlc
871871
uses:./.github/actions/setup-sqlc

‎.github/workflows/dogfood.yaml

Lines changed: 22 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ permissions:
2424
jobs:
2525
build_image:
2626
if:github.actor != 'dependabot[bot]'# Skip Dependabot PRs
27-
runs-on:ubuntu-latest
27+
runs-on:${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-4' || 'ubuntu-latest' }}
2828
steps:
2929
-name:Harden Runner
3030
uses:step-security/harden-runner@cb605e52c26070c328afc4562f0b4ada7618a84e# v2.10.4
@@ -34,6 +34,12 @@ jobs:
3434
-name:Checkout
3535
uses:actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871# v4.2.1
3636

37+
-name:Setup Nix
38+
uses:DeterminateSystems/nix-installer-action@e50d5f73bfe71c2dd0aa4218de8f4afa59f8f81d# v16
39+
40+
-name:Setup GHA Nix cache
41+
uses:DeterminateSystems/magic-nix-cache-action@6221693898146dc97e38ad0e013488a16477a4c4# v9
42+
3743
-name:Get branch name
3844
id:branch-name
3945
uses:tj-actions/branch-names@6871f53176ad61624f978536bbf089c574dc19a2# v8.0.1
@@ -71,18 +77,21 @@ jobs:
7177
push:${{ github.ref == 'refs/heads/main' }}
7278
tags:"codercom/oss-dogfood:${{ steps.docker-tag-name.outputs.tag }},codercom/oss-dogfood:latest"
7379

74-
-name:Build and push Nix image
75-
uses:depot/build-push-action@636daae76684e38c301daa0c5eca1c095b24e780# v1.14.0
76-
with:
77-
project:b4q6ltmpzh
78-
token:${{ secrets.DEPOT_TOKEN }}
79-
buildx-fallback:true
80-
context:"."
81-
file:"dogfood/contents/Dockerfile.nix"
82-
pull:true
83-
save:true
84-
push:${{ github.ref == 'refs/heads/main' }}
85-
tags:"codercom/oss-dogfood-nix:${{ steps.docker-tag-name.outputs.tag }},codercom/oss-dogfood-nix:latest"
80+
-name:Build Nix image
81+
run:nix build .#dev_image
82+
83+
-name:Push Nix image
84+
if:github.ref == 'refs/heads/main'
85+
run:|
86+
docker load -i result
87+
88+
CURRENT_SYSTEM=$(nix eval --impure --raw --expr 'builtins.currentSystem')
89+
90+
docker image tag codercom/oss-dogfood-nix:latest-$CURRENT_SYSTEM codercom/oss-dogfood-nix:${{ steps.docker-tag-name.outputs.tag }}
91+
docker image push codercom/oss-dogfood-nix:${{ steps.docker-tag-name.outputs.tag }}
92+
93+
docker image tag codercom/oss-dogfood-nix:latest-$CURRENT_SYSTEM codercom/oss-dogfood-nix:latest
94+
docker image push codercom/oss-dogfood-nix:latest
8695
8796
deploy_template:
8897
needs:build_image

‎.github/workflows/security.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -86,13 +86,13 @@ jobs:
8686
uses:./.github/actions/setup-sqlc
8787

8888
-name:Install yq
89-
run:go run github.com/mikefarah/yq/v4@v4.30.6
89+
run:go run github.com/mikefarah/yq/v4@v4.44.3
9090
-name:Install mockgen
91-
run:go install go.uber.org/mock/mockgen@v0.4.0
91+
run:go install go.uber.org/mock/mockgen@v0.5.0
9292
-name:Install protoc-gen-go
9393
run:go install google.golang.org/protobuf/cmd/protoc-gen-go@v1.30
9494
-name:Install protoc-gen-go-drpc
95-
run:go install storj.io/drpc/cmd/protoc-gen-go-drpc@v0.0.33
95+
run:go install storj.io/drpc/cmd/protoc-gen-go-drpc@v0.0.34
9696
-name:Install Protoc
9797
run:|
9898
# protoc must be in lockstep with our dogfood Dockerfile or the

‎Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -957,3 +957,6 @@ else
957957
pnpm playwright:test
958958
endif
959959
.PHONY: test-e2e
960+
961+
dogfood/contents/nix.hash: flake.nix flake.lock
962+
sha256sum flake.nix flake.lock>./dogfood/contents/nix.hash

‎agent/proto/agent.pb.go

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more aboutcustomizing how changed files appear on GitHub.

‎agent/proto/agent_drpc.pb.go

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more aboutcustomizing how changed files appear on GitHub.

‎cli/testdata/TestProvisioners_Golden/list.golden

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
ID CREATED AT LAST SEEN AT NAME VERSION TAGS KEY NAME STATUS CURRENT JOB ID CURRENT JOB STATUS PREVIOUS JOB ID PREVIOUS JOB STATUS ORGANIZATION
1+
ID CREATED AT LAST SEEN ATNAME VERSION TAGS KEY NAME STATUS CURRENT JOB ID CURRENT JOB STATUS PREVIOUS JOB ID PREVIOUS JOB STATUS ORGANIZATION
22
00000000-0000-0000-aaaa-000000000000 ====[timestamp]===== ====[timestamp]===== default-provisioner v0.0.0-devel map[owner: scope:organization] built-in idle <nil> <nil> 00000000-0000-0000-bbbb-000000000001 succeeded Coder
33
00000000-0000-0000-aaaa-000000000001 ====[timestamp]===== ====[timestamp]===== provisioner-1 v0.0.0 map[foo:bar owner: scope:organization] built-in busy 00000000-0000-0000-bbbb-000000000002 running <nil> <nil> Coder
44
00000000-0000-0000-aaaa-000000000002 ====[timestamp]===== ====[timestamp]===== provisioner-2 v0.0.0 map[owner: scope:organization] built-in offline <nil> <nil> 00000000-0000-0000-bbbb-000000000003 succeeded Coder
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
CREATED AT LAST SEEN AT NAME VERSION TAGS KEY NAME STATUS ORGANIZATION
1+
CREATED AT LAST SEEN ATNAME VERSION TAGS KEY NAME STATUS ORGANIZATION
22
====[timestamp]===== ====[timestamp]===== test v0.0.0-devel map[owner: scope:organization] built-in idle Coder

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp