Allowing "tasks" instead of only allowing "pipeline" in turbo.json #1272
+4
−1
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.
Issue Description
Nixpacks does not support
turbo
versions >= 1.7. Specifically,turborepo.rs
attempts to readturbo.json
and looks for the"pipeline"
key, butturbo
versions 1.7 and above use the"tasks"
key instead. This mismatch results in Nixpacks failing silently and throwing an error like "start command not found," without clearly indicating the underlying issue.Additionally, the documentation does not explicitly state that only
turbo
versions < 1.7 are supported.Possible Solutions
turbo
to v1.6: This is a temporary workaround, but it’s not ideal for users who rely on newerturbo
features."tasks"
key in this repository: This would involve updating the code to handleturbo
versions >= 1.7. However, it’s unclear whether this change only requires supporting the new JSON key or if additional implementation is needed to fully support newerturbo
versions.Proposed Fix
This PR implements Solution 2 by adding support for the
"tasks"
key inturborepo.rs
. This ensures compatibility withturbo
versions >= 1.7 while maintaining backward compatibility with older versions. The changes include:"pipeline"
and"tasks"
keys.turbo.json
.