Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
2941d0f
feat(codespace): add remote development environments
ExplodingDragon Aug 1, 2026
44e3cef
test(codespace): align integration creation flow
ExplodingDragon Aug 1, 2026
3033dd4
test(codespace): submit selected dev container
ExplodingDragon Aug 1, 2026
1f32fe7
refactor(codespace): use natural relation keys
ExplodingDragon Aug 1, 2026
925cd69
logging: reduce codespace RPC request noise
ExplodingDragon Aug 1, 2026
c3ceb64
tests: remove codespace request logging test
ExplodingDragon Aug 1, 2026
a2ee4aa
build: use canonical codespace protocol module
ExplodingDragon Aug 1, 2026
a128db8
Merge upstream main into feat-remote-dev
ExplodingDragon Aug 3, 2026
793eff1
refactor: simplify Codespace persistence and configuration
ExplodingDragon Aug 3, 2026
4afbd8a
refactor: simplify Codespace frontend styles
ExplodingDragon Aug 3, 2026
adf8df8
refactor(codespace): simplify service state coordination
ExplodingDragon Aug 3, 2026
4e7ca74
feat(codespace): add Dev Container templates
ExplodingDragon Aug 4, 2026
4eae974
refactor(codespace): simplify Dev Container template UI
ExplodingDragon Aug 4, 2026
e0ee46f
feat: refine codespace manager identity flow
ExplodingDragon Aug 6, 2026
154c005
enhance(codespace): require manager display names
ExplodingDragon Aug 20, 2026
61b1746
Merge remote-tracking branch 'upstream/main' into feat-remote-dev
ExplodingDragon Aug 20, 2026
24603c1
refactor(codespace): align with upstream frontend conventions
ExplodingDragon Aug 20, 2026
90b4bde
fix(codespace): align with upstream and stabilize CI
ExplodingDragon Sep 7, 2026
900bddc
enhance(codespace): streamline management and align settings UI
ExplodingDragon Sep 8, 2026
034996b
chore: merge upstream main
ExplodingDragon Oct 1, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions assets/go-licenses.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 5 additions & 1 deletion cmd/serv.go
Original file line number Diff line number Diff line change
Expand Up @@ -173,12 +173,16 @@ func runServ(ctx context.Context, c *cli.Command) error {
}
var authSuccessMsg string
switch key.Type {
case asymkey_model.KeyTypeUser:
authSuccessMsg = "Hi there, " + user.Name + "! You've successfully authenticated with the SSH key named " + key.Name + "."
case asymkey_model.KeyTypeDeploy:
authSuccessMsg = "Hi there! You've successfully authenticated with an SSH deploy key."
case asymkey_model.KeyTypePrincipal:
authSuccessMsg = "Hi there! You've successfully authenticated with the SSH principal " + key.Content + "."
case asymkey_model.KeyTypeCodespace:
authSuccessMsg = "Hi there! You've successfully authenticated with the codespace key named " + key.Name + "."
default:
authSuccessMsg = "Hi there, " + user.Name + "! You've successfully authenticated with the SSH key named " + key.Name + "."
return fail(ctx, "Unsupported key type", "Unsupported key type %d for key %d", key.Type, key.ID)
}
_, _ = fmt.Fprintf(c.ErrWriter, "%s\n%s",
authSuccessMsg,
Expand Down
62 changes: 62 additions & 0 deletions custom/conf/app.example.ini
Original file line number Diff line number Diff line change
Expand Up @@ -2217,6 +2217,20 @@ LEVEL = Info
;; Archives created more than OLDER_THAN ago are subject to deletion
;OLDER_THAN = 24h

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Reconcile Codespace operation timeouts and failed retention
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;[cron.reconcile_codespaces]
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;ENABLED = true
;RUN_AT_START = true
;NOTICE_ON_SUCCESS = false
;SCHEDULE = @every 1m
;; Failed Codespaces older than OLDER_THAN are deleted locally by Gitea
;OLDER_THAN = 8760h

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Update mirrors
Expand Down Expand Up @@ -3107,6 +3121,54 @@ LEVEL = Info
;; In a multi-instance deployment the cluster-wide limit is this value times the number of instances. Default value is 16.
;MAX_CONCURRENT_TASK_PICKS = 16

; [codespace]
;; Enable Codespace integration.
;ENABLED = true
;;
;; Default Git protocol used by new Codespaces when preparing clone URLs.
;; Valid values are `http` and `ssh`; empty values use `http`.
;; The selected protocol must be available when Codespace integration is enabled.
;GIT_PROTOCOL = http
;;
;; Comma-separated SSH known_hosts lines returned to Codespace runtimes for Git SSH clone access.
;; These lines identify the Gitea SSH clone endpoint for strict Host Key checking.
;; Leave empty to use Gitea's configured SSH host keys when the built-in SSH server is enabled.
;; When using an external SSH server, leave empty with GIT_PROTOCOL=http to disable Codespace SSH clone,
;; or set this explicitly before choosing GIT_PROTOCOL=ssh or disabling HTTP Git.
;GIT_SSH_KNOWN_HOSTS =
;;
;; Require Manager-declared Gateway URLs to use HTTPS.
;; This protects browser Gateway session cookies in production deployments.
;GATEWAY_REQUIRE_HTTPS = false
;;
;; Timeout for Gitea-to-Manager control-plane RPC requests.
;CONTROL_PLANE_TIMEOUT = 30s
;;
;; Time since the last successful Manager declaration after which the Manager is treated as offline.
;MANAGER_OFFLINE_TIMEOUT = 120s
;;
;; Lease duration granted to a Manager after it claims an operation.
;OPERATION_LEASE_TIMEOUT = 300s
;;
;; Maximum time a running operation may remain active before Gitea times it out.
;OPERATION_MAX_DURATION = 2h
;;
;; Maximum time a queued operation may wait before Gitea applies the queued timeout result.
;QUEUE_TIMEOUT = 5m
;;
;; Maximum stored operation log size per Codespace.
;; Gitea uses internal defaults for per-line, page-read, and final-summary reserves so ordinary deployments only tune the total log budget.
;LOG_MAX_SIZE = 64MiB
;;
;; Default idle timeout for Codespaces that use the site default auto-stop policy.
;AUTO_STOP_DEFAULT_TIMEOUT = 30m
;;
;; Minimum custom idle timeout a user may configure for one Codespace.
;AUTO_STOP_MIN_TIMEOUT = 5m
;;
;; Maximum custom idle timeout a user may configure for one Codespace.
;AUTO_STOP_MAX_TIMEOUT = 168h

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; settings for action logs, will override storage setting
Expand Down
4 changes: 3 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ require (
gitea.com/lunny/dingtalk_webhook v0.0.0-20171025031554-e3534c89ef96
gitea.com/lunny/levelqueue v0.4.2-0.20230414023320-3c0159fe0fe4
gitea.dev/actionslib v1.2.1
gitea.dev/codespace-proto-go v0.0.0-20260907082402-c2857d30f25f
gitea.dev/sdk v1.2.0
github.com/42wim/httpsig v1.2.4
github.com/42wim/sshsig v0.0.0-20260317195500-b9f38cf0d432
Expand Down Expand Up @@ -55,6 +56,7 @@ require (
github.com/google/go-github/v92 v92.0.0
github.com/google/licenseclassifier/v2 v2.0.0
github.com/google/pprof v0.0.0-20260906184651-6331bc6350fe
github.com/google/uuid v1.6.0
github.com/gorilla/feeds v1.2.0
github.com/gorilla/sessions v1.4.0
github.com/hashicorp/go-version v1.9.0
Expand Down Expand Up @@ -86,6 +88,7 @@ require (
github.com/sergi/go-diff v1.4.0
github.com/stretchr/testify v1.12.1
github.com/syndtr/goleveldb v1.0.0
github.com/tailscale/hujson v0.0.0-20260727124030-b80ff77dac4f
github.com/ulikunitz/xz v0.5.17
github.com/urfave/cli-docs/v3 v3.1.0
github.com/urfave/cli/v3 v3.13.0
Expand Down Expand Up @@ -181,7 +184,6 @@ require (
github.com/google/flatbuffers v25.12.19+incompatible // indirect
github.com/google/go-querystring v1.2.0 // indirect
github.com/google/go-tpm v0.9.8 // indirect
github.com/google/uuid v1.6.0 // indirect
github.com/gorilla/css v1.0.1 // indirect
github.com/gorilla/mux v1.8.1 // indirect
github.com/gorilla/securecookie v1.1.2 // indirect
Expand Down
4 changes: 4 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ gitea.com/xorm/sqlfiddle v0.0.0-20180821085327-62ce714f951a h1:lSA0F4e9A2NcQSqGq
gitea.com/xorm/sqlfiddle v0.0.0-20180821085327-62ce714f951a/go.mod h1:EXuID2Zs0pAQhH8yz+DNjUbjppKQzKFAn28TMYPB6IU=
gitea.dev/actionslib v1.2.1 h1:GL//K/0zIZV6h1OOksv1awvFVg0rg7fug2xWcG7mkG0=
gitea.dev/actionslib v1.2.1/go.mod h1:1+gqOKGSEPn2IFHgY8S3GC5Ld+Hn8jF3OxiFHQ/fpx4=
gitea.dev/codespace-proto-go v0.0.0-20260907082402-c2857d30f25f h1:rcXIwyXtQUQ+IUFgTzPqrw3byaB6K5IZhNTnXD9rUeo=
gitea.dev/codespace-proto-go v0.0.0-20260907082402-c2857d30f25f/go.mod h1:HYAE81idAawJyuWFLref9Das+loyey9+q7gY/J1DZWw=
gitea.dev/sdk v1.2.0 h1:avRtJl/nKCGispgSalo9czoZM9Rto1awnE0caNAoXGo=
gitea.dev/sdk v1.2.0/go.mod h1:rfh5oNdIK24cbCREwIn1tqWKQW+IICXFGWJyebuOAOE=
github.com/42wim/httpsig v1.2.4 h1:mI5bH0nm4xn7K18fo1K3okNDRq8CCJ0KbBYWyA6r8lU=
Expand Down Expand Up @@ -614,6 +616,8 @@ github.com/stvp/tempredis v0.0.0-20181119212430-b82af8480203 h1:QVqDTf3h2WHt08Yu
github.com/stvp/tempredis v0.0.0-20181119212430-b82af8480203/go.mod h1:oqN97ltKNihBbwlX8dLpwxCl3+HnXKV/R0e+sRLd9C8=
github.com/syndtr/goleveldb v1.0.0 h1:fBdIW9lB4Iz0n9khmH8w27SJ3QEJ7+IgjPEwGSZiFdE=
github.com/syndtr/goleveldb v1.0.0/go.mod h1:ZVVdQEZoIme9iO1Ch2Jdy24qqXrMMOU6lpPAyBWyWuQ=
github.com/tailscale/hujson v0.0.0-20260727124030-b80ff77dac4f h1:9hiVElpCmKzsBKQHkBqZ8LGzt82iLfM8egxr4sew+Ys=
github.com/tailscale/hujson v0.0.0-20260727124030-b80ff77dac4f/go.mod h1:8/zr1Tv0+cKpVtGCEB/7YfRXr2TszsMxMXLaT8YuBgU=
github.com/tinylib/msgp v1.6.4 h1:mOwYbyYDLPj35mkA2BjjYejgJk9BuHxDdvRnb6v2ZcQ=
github.com/tinylib/msgp v1.6.4/go.mod h1:RSp0LW9oSxFut3KzESt5Voq4GVWyS+PSulT77roAqEA=
github.com/ulikunitz/xz v0.5.8/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14=
Expand Down
1 change: 1 addition & 0 deletions modelmigration/migrations.go
Original file line number Diff line number Diff line change
Expand Up @@ -429,6 +429,7 @@ func prepareMigrationTasks() []*migration {
newMigration(353, "Add audit event table", v28.AddAuditEventTable),
newMigration(354, "Add Actions job queue indexes", v28.AddActionQueueIndexes),
newMigration(355, "Add AutoMerge merged_commit_id column", v28.AddAutoMergeMergedCommitID),
newMigration(356, "Add Codespace tables", v28.AddCodespaceTables),
}
return preparedMigrations
}
Expand Down
Loading
Loading