Skip to content

Commit 42cae32

Browse files
committed
Merge branch 'main' into jon/installmsg
2 parents d161287 + 46d92da commit 42cae32

File tree

583 files changed

+19918
-6815
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

583 files changed

+19918
-6815
lines changed

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,4 @@ provisionersdk/proto/*.go linguist-generated=true
1212
*.tfstate.dot linguist-generated=true
1313
*.tfplan.dot linguist-generated=true
1414
site/src/api/typesGenerated.ts linguist-generated=true
15+
site/src/pages/SetupPage/countries.tsx linguist-generated=true

.github/fly-wsproxies/paris-coder.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ primary_region = "cdg"
1313
CODER_HTTP_ADDRESS = "0.0.0.0:3000"
1414
CODER_PRIMARY_ACCESS_URL = "https://dev.coder.com"
1515
CODER_WILDCARD_ACCESS_URL = "*--apps.paris.fly.dev.coder.com"
16+
CODER_VERBOSE = "true"
1617

1718
[http_service]
1819
internal_port = 3000

.github/fly-wsproxies/sao-paulo-coder.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ primary_region = "gru"
1313
CODER_HTTP_ADDRESS = "0.0.0.0:3000"
1414
CODER_PRIMARY_ACCESS_URL = "https://dev.coder.com"
1515
CODER_WILDCARD_ACCESS_URL = "*--apps.sao-paulo.fly.dev.coder.com"
16+
CODER_VERBOSE = "true"
1617

1718
[http_service]
1819
internal_port = 3000

.github/fly-wsproxies/sydney-coder.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ primary_region = "syd"
1313
CODER_HTTP_ADDRESS = "0.0.0.0:3000"
1414
CODER_PRIMARY_ACCESS_URL = "https://dev.coder.com"
1515
CODER_WILDCARD_ACCESS_URL = "*--apps.sydney.fly.dev.coder.com"
16+
CODER_VERBOSE = "true"
1617

1718
[http_service]
1819
internal_port = 3000

.github/workflows/ci.yaml

Lines changed: 45 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646
fetch-depth: 1
4747
# For pull requests it's not necessary to checkout the code
4848
- name: check changed files
49-
uses: dorny/paths-filter@v2
49+
uses: dorny/paths-filter@v3
5050
id: filter
5151
with:
5252
filters: |
@@ -141,7 +141,7 @@ jobs:
141141
142142
# Check for any typos
143143
- name: Check for typos
144-
uses: crate-ci/typos@v1.17.0
144+
uses: crate-ci/typos@v1.17.2
145145
with:
146146
config: .github/workflows/typos.toml
147147

@@ -655,7 +655,7 @@ jobs:
655655
# to main branch. We are only building this for amd64 platform. (>95% pulls
656656
# are for amd64)
657657
needs: changes
658-
if: github.ref == 'refs/heads/main' && needs.changes.outputs.docs-only == 'false'
658+
if: needs.changes.outputs.docs-only == 'false' && !github.event.pull_request.head.repo.fork
659659
runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }}
660660
env:
661661
DOCKER_CLI_EXPERIMENTAL: "enabled"
@@ -692,46 +692,70 @@ jobs:
692692
go mod download
693693
694694
version="$(./scripts/version.sh)"
695+
tag="main-$(echo "$version" | sed 's/+/-/g')"
696+
echo "tag=$tag" >> $GITHUB_OUTPUT
697+
695698
make gen/mark-fresh
696699
make -j \
697-
build/coder_linux_amd64 \
700+
build/coder_linux_{amd64,arm64,armv7} \
698701
build/coder_"$version"_windows_amd64.zip \
699702
build/coder_"$version"_linux_amd64.{tar.gz,deb}
700703
701-
- name: Build and Push Linux amd64 Docker Image
704+
- name: Build Linux Docker images
702705
id: build-docker
706+
env:
707+
CODER_IMAGE_BASE: ghcr.io/coder/coder-preview
708+
CODER_IMAGE_TAG_PREFIX: main
709+
DOCKER_CLI_EXPERIMENTAL: "enabled"
703710
run: |
704711
set -euxo pipefail
712+
713+
# build Docker images for each architecture
705714
version="$(./scripts/version.sh)"
706715
tag="main-$(echo "$version" | sed 's/+/-/g')"
707-
708-
export CODER_IMAGE_BUILD_BASE_TAG="$(CODER_IMAGE_BASE=coder-base ./scripts/image_tag.sh --version "$version")"
709-
./scripts/build_docker.sh \
710-
--arch amd64 \
711-
--target "ghcr.io/coder/coder-preview:$tag" \
712-
--version $version \
713-
--push \
714-
build/coder_linux_amd64
715-
716-
# Tag as main
717-
docker tag "ghcr.io/coder/coder-preview:$tag" ghcr.io/coder/coder-preview:main
718-
docker push ghcr.io/coder/coder-preview:main
719-
720-
# Store the tag in an output variable so we can use it in other jobs
721716
echo "tag=$tag" >> $GITHUB_OUTPUT
722717
718+
# build images for each architecture
719+
make -j build/coder_"$version"_linux_{amd64,arm64,armv7}.tag
720+
721+
# only push if we are on main branch
722+
if [ "${{ github.ref }}" == "refs/heads/main" ]; then
723+
# build and push multi-arch manifest, this depends on the other images
724+
# being pushed so will automatically push them
725+
make -j push/build/coder_"$version"_linux_{amd64,arm64,armv7}.tag
726+
727+
# Define specific tags
728+
tags=("$tag" "main" "latest")
729+
730+
# Create and push a multi-arch manifest for each tag
731+
# we are adding `latest` tag and keeping `main` for backward
732+
# compatibality
733+
for t in "${tags[@]}"; do
734+
./scripts/build_docker_multiarch.sh \
735+
--push \
736+
--target "ghcr.io/coder/coder-preview:$t" \
737+
--version $version \
738+
$(cat build/coder_"$version"_linux_{amd64,arm64,armv7}.tag)
739+
done
740+
fi
741+
723742
- name: Prune old images
724-
uses: vlaurin/action-ghcr-prune@v0.5.0
743+
if: github.ref == 'refs/heads/main'
744+
uses: vlaurin/action-ghcr-prune@v0.6.0
725745
with:
726746
token: ${{ secrets.GITHUB_TOKEN }}
727747
organization: coder
728748
container: coder-preview
729749
keep-younger-than: 7 # days
750+
keep-tags: latest
730751
keep-tags-regexes: ^pr
731-
prune-tags-regexes: ^main-
752+
prune-tags-regexes: |
753+
^main-
754+
^v
732755
prune-untagged: true
733756

734757
- name: Upload build artifacts
758+
if: github.ref == 'refs/heads/main'
735759
uses: actions/upload-artifact@v4
736760
with:
737761
name: coder

.github/workflows/dogfood.yaml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,26 +58,38 @@ jobs:
5858

5959
deploy_template:
6060
needs: build_image
61-
if: github.ref == 'refs/heads/main'
6261
runs-on: ubuntu-latest
6362
steps:
6463
- name: Checkout
6564
uses: actions/checkout@v4
6665

66+
- name: Setup Terraform
67+
uses: ./.github/actions/setup-tf
68+
69+
- name: Terraform init and validate
70+
run: |
71+
cd dogfood
72+
terraform init -upgrade
73+
terraform validate
74+
6775
- name: Get short commit SHA
76+
if: github.ref == 'refs/heads/main'
6877
id: vars
6978
run: echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
7079

7180
- name: Get latest commit title
81+
if: github.ref == 'refs/heads/main'
7282
id: message
7383
run: echo "pr_title=$(git log --format=%s -n 1 ${{ github.sha }})" >> $GITHUB_OUTPUT
7484

7585
- name: "Get latest Coder binary from the server"
86+
if: github.ref == 'refs/heads/main'
7687
run: |
7788
curl -fsSL "https://dev.coder.com/bin/coder-linux-amd64" -o "./coder"
7889
chmod +x "./coder"
7990
8091
- name: "Push template"
92+
if: github.ref == 'refs/heads/main'
8193
run: |
8294
./coder templates push $CODER_TEMPLATE_NAME --directory $CODER_TEMPLATE_DIR --yes --name=$CODER_TEMPLATE_VERSION --message="$CODER_TEMPLATE_MESSAGE" --variable jfrog_url=${{ secrets.JFROG_URL }}
8395
env:

.github/workflows/pr-auto-assign.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@ jobs:
1414
runs-on: ubuntu-latest
1515
steps:
1616
- name: Assign author
17-
uses: toshimaru/auto-author-assign@v2.0.1
17+
uses: toshimaru/auto-author-assign@v2.1.0

.github/workflows/pr-deploy.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ jobs:
119119
echo "NEW=$NEW" >> $GITHUB_OUTPUT
120120
121121
- name: Check changed files
122-
uses: dorny/paths-filter@v2
122+
uses: dorny/paths-filter@v3
123123
id: filter
124124
with:
125125
base: ${{ github.ref }}
@@ -163,7 +163,7 @@ jobs:
163163
runs-on: "ubuntu-latest"
164164
steps:
165165
- name: Find Comment
166-
uses: peter-evans/find-comment@v2
166+
uses: peter-evans/find-comment@v3
167167
id: fc
168168
with:
169169
issue-number: ${{ needs.get_info.outputs.PR_NUMBER }}
@@ -173,7 +173,7 @@ jobs:
173173

174174
- name: Comment on PR
175175
id: comment_id
176-
uses: peter-evans/create-or-update-comment@v3
176+
uses: peter-evans/create-or-update-comment@v4
177177
with:
178178
comment-id: ${{ steps.fc.outputs.comment-id }}
179179
issue-number: ${{ needs.get_info.outputs.PR_NUMBER }}
@@ -441,7 +441,7 @@ jobs:
441441
echo "Slack notification sent"
442442
443443
- name: Find Comment
444-
uses: peter-evans/find-comment@v2
444+
uses: peter-evans/find-comment@v3
445445
id: fc
446446
with:
447447
issue-number: ${{ env.PR_NUMBER }}
@@ -450,7 +450,7 @@ jobs:
450450
direction: last
451451

452452
- name: Comment on PR
453-
uses: peter-evans/create-or-update-comment@v3
453+
uses: peter-evans/create-or-update-comment@v4
454454
env:
455455
STATUS: ${{ needs.get_info.outputs.NEW == 'true' && 'Created' || 'Updated' }}
456456
with:

.github/workflows/release.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -321,7 +321,7 @@ jobs:
321321

322322
- name: Start Packer builds
323323
if: ${{ !inputs.dry_run }}
324-
uses: peter-evans/repository-dispatch@v2
324+
uses: peter-evans/repository-dispatch@v3
325325
with:
326326
token: ${{ secrets.CDRCI_GITHUB_TOKEN }}
327327
repository: coder/packages
@@ -408,6 +408,11 @@ jobs:
408408
if: ${{ !inputs.dry_run }}
409409

410410
steps:
411+
- name: Sync fork
412+
run: gh repo sync cdrci/winget-pkgs -b master
413+
env:
414+
GH_TOKEN: ${{ secrets.WINGET_GH_TOKEN }}
415+
411416
- name: Checkout
412417
uses: actions/checkout@v4
413418
with:

.github/workflows/typos.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ darcula = "darcula"
1414
Hashi = "Hashi"
1515
trialer = "trialer"
1616
encrypter = "encrypter"
17-
hel = "hel" # as in helsinki
17+
hel = "hel" # as in helsinki
1818

1919
[files]
2020
extend-exclude = [
@@ -31,4 +31,5 @@ extend-exclude = [
3131
"**/*.test.tsx",
3232
"**/pnpm-lock.yaml",
3333
"tailnet/testdata/**",
34+
"site/src/pages/SetupPage/countries.tsx",
3435
]

Makefile

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -475,7 +475,10 @@ gen: \
475475
site/.eslintignore \
476476
site/e2e/provisionerGenerated.ts \
477477
site/src/theme/icons.json \
478-
examples/examples.gen.json
478+
examples/examples.gen.json \
479+
tailnet/tailnettest/coordinatormock.go \
480+
tailnet/tailnettest/coordinateemock.go \
481+
tailnet/tailnettest/multiagentmock.go
479482
.PHONY: gen
480483

481484
# Mark all generated files as fresh so make thinks they're up-to-date. This is
@@ -502,6 +505,9 @@ gen/mark-fresh:
502505
site/e2e/provisionerGenerated.ts \
503506
site/src/theme/icons.json \
504507
examples/examples.gen.json \
508+
tailnet/tailnettest/coordinatormock.go \
509+
tailnet/tailnettest/coordinateemock.go \
510+
tailnet/tailnettest/multiagentmock.go \
505511
"
506512
for file in $$files; do
507513
echo "$$file"
@@ -529,6 +535,9 @@ coderd/database/querier.go: coderd/database/sqlc.yaml coderd/database/dump.sql $
529535
coderd/database/dbmock/dbmock.go: coderd/database/db.go coderd/database/querier.go
530536
go generate ./coderd/database/dbmock/
531537

538+
tailnet/tailnettest/coordinatormock.go tailnet/tailnettest/multiagentmock.go tailnet/tailnettest/coordinateemock.go: tailnet/coordinator.go tailnet/multiagent.go
539+
go generate ./tailnet/tailnettest/
540+
532541
tailnet/proto/tailnet.pb.go: tailnet/proto/tailnet.proto
533542
protoc \
534543
--go_out=. \

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
</a>
88

99
<h1>
10-
Self-Hosted Remote Development Environments
10+
Self-Hosted Cloud Development Environments
1111
</h1>
1212

1313
<a href="https://coder.com#gh-light-mode-only">
@@ -31,9 +31,9 @@
3131

3232
</div>
3333

34-
[Coder](https://coder.com) enables organizations to set up development environments in the cloud. Environments are defined with Terraform, connected through a secure high-speed Wireguard® tunnel, and are automatically shut down when not in use to save on costs. Coder gives engineering teams the flexibility to use the cloud for workloads that are most beneficial to them.
34+
[Coder](https://coder.com) enables organizations to set up development environments in their public or private cloud infrastructure. Cloud development environments are defined with Terraform, connected through a secure high-speed Wireguard® tunnel, and are automatically shut down when not in use to save on costs. Coder gives engineering teams the flexibility to use the cloud for workloads that are most beneficial to them.
3535

36-
- Define development environments in Terraform
36+
- Define cloud development environments in Terraform
3737
- EC2 VMs, Kubernetes Pods, Docker Containers, etc.
3838
- Automatically shutdown idle resources to save on costs
3939
- Onboard developers in seconds instead of days
@@ -44,7 +44,7 @@
4444

4545
## Quickstart
4646

47-
The most convenient way to try Coder is to install it on your local machine and experiment with provisioning development environments using Docker (works on Linux, macOS, and Windows).
47+
The most convenient way to try Coder is to install it on your local machine and experiment with provisioning cloud development environments using Docker (works on Linux, macOS, and Windows).
4848

4949
```
5050
# First, install Coder
@@ -100,7 +100,7 @@ Browse our docs [here](https://coder.com/docs/v2) or visit a specific section be
100100

101101
Feel free to [open an issue](https://github.com/coder/coder/issues/new) if you have questions, run into bugs, or have a feature request.
102102

103-
[Join our Discord](https://discord.gg/coder) to provide feedback on in-progress features, and chat with the community using Coder!
103+
[Join our Discord](https://discord.gg/coder) or [Slack](https://cdr.co/join-community) to provide feedback on in-progress features, and chat with the community using Coder!
104104

105105
## Contributing
106106

0 commit comments

Comments
 (0)