Support code uploads without Git hoster#372
Draft
schmijos wants to merge 2 commits intoninech:mainfrom
Draft
Conversation
schmijos
commented
Mar 24, 2026
| "strings" | ||
| ) | ||
|
|
||
| const DefaultUploadURL = "https://gitonce.21ddead.deploio.app/upload" |
Contributor
Author
There was a problem hiding this comment.
That's for sure not the final idea.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This adds a parameter
--from-local-dir. So you can call nctl like this:This then will pack the folder into a ZIP and upload it to gitonce (a service Nine would still have to provide).
Deploio can then check it out and deploy once.
Would look like this:
sequenceDiagram autonumber actor Coder participant Nctl as nctl CLI participant GitOnce as gitonce participant Deploio as deplo.io (kpack) Coder->>Nctl: nctl create app DEMO_APP --from-local-dir=./ Nctl->>GitOnce: /upload ZIP GitOnce-->>Nctl: {"commit": COMMIT, "url": REPO_URL } Nctl->>Nctl: nctl create app DEMO_APP --git-url=REPO_URL --git-revision=COMMIT Nctl->>Deploio: Nine API Call Deploio->>Deploio: Start build from Git source Deploio->>GitOnce: GET REPO_URL/info/refs?service=git-upload-pack GitOnce-->>Deploio: Advertise refs Deploio->>GitOnce: POST REPO_URL/git-upload-pack GitOnce-->>Deploio: Send repository pack GitOnce->>GitOnce: Expire one-time repo and delete ZIP Deploio->>Deploio: Build and deploy app Coder->>Nctl: nctl logs build demo-app-1 Nctl->>Deploio: Nine API Call Deploio-->>Nctl: Successful build logs Note over Coder,Nctl: Later operations using same Git URL will fail, for example: Coder->>Nctl: nctl update app DEMO_APP --git-url=REPO_URL Nctl->>Deploio: Request redeploy with same Git URL Deploio->>Deploio: Try to fetch source again Deploio->>GitOnce: GET/POST Git fetch GitOnce-->>Deploio: 410 Gone Coder->>Nctl: nctl logs build demo-app-2 Nctl->>Deploio: Nine API Call Deploio-->>Nctl: Failed build logs