GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(@angular/build): resolve dev-server `sslKey` and `sslCert` relative to the workspace root by MeAkib · Pull Request #34399 · angular/angular-cli

Conversation

@MeAkib

@MeAkib MeAkib commented Oct 19, 2026

Copy link
Copy Markdown
Contributor

The Vite-based dev server read sslKey and sslCert relative to the current working directory, so serving failed with ENOENT when ng serve ran from a subdirectory of the workspace and the paths in angular.json were relative. Resolve both paths against the workspace root, as the webpack dev server already does.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

gemini-code-assist[bot] reacted with eyes emoji
All reactions
  • 👀 1 reaction
@MeAkib
fix(@angular/build): resolve dev-server sslKey and sslCert relati…
e6056d3
…ve to the workspace root

The Vite-based dev server read `sslKey` and `sslCert` relative to the current working directory,
so serving failed with `ENOENT` when `ng serve` ran from a subdirectory of the workspace and the
paths in `angular.json` were relative. Resolve both paths against the workspace root, as the
webpack dev server already does.

The new dev-server `ssl` spec covers relative paths. It fails with `ENOENT` without this change.
@angular-robot angular-robot Bot added the area: @angular/build label Oct 19, 2026
alan-agius4
alan-agius4 requested changes Oct 19, 2026
View reviewed changes

@alan-agius4 alan-agius4 left a comment •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Collaborator

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be done in https://github.com/angular/angular-cli/blob/main/packages/angular/build/src/builders/dev-server/options.ts

Similar to

angular-cli/packages/angular/build/src/builders/application/options.ts

Line 208 in 508d6a2

const tsconfig = path.join(workspaceRoot, options.tsConfig);
and

angular-cli/packages/angular/build/src/builders/application/options.ts

Line 218 in 508d6a2

const fileReplaceWith = path.join(workspaceRoot, replacement.with);

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@alan-agius4 alan-agius4 added action: cleanup The PR is in need of cleanup, either due to needing a rebase or in response to comments from reviews target: patch This PR is targeted for the next patch release labels Oct 19, 2026
gemini-code-assist[bot]
gemini-code-assist Bot reviewed Oct 19, 2026
View reviewed changes

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the Vite dev-server configuration to resolve the sslCert and sslKey paths relative to the workspace root. Additionally, a new test suite has been added to verify this behavior. There are no review comments, and I have no feedback to provide.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@MeAkib
fixup! fix(@angular/build): resolve dev-server sslKey and sslCert…
a41acae
… relative to the workspace root
@MeAkib
MeAkib requested a review from alan-agius4 October 19, 2026 09:27
alan-agius4
alan-agius4 reviewed Oct 19, 2026
View reviewed changes
Comment thread packages/angular/build/src/builders/dev-server/options.ts Resolved

Uh oh!

There was an error while loading. Please reload this page.

@MeAkib
fixup! fix(@angular/build): resolve dev-server sslKey and sslCert…
08e9727
… relative to the workspace root
@MeAkib
MeAkib force-pushed the fix/dev-server-ssl-paths branch from 0ae6773 to 08e9727 Compare October 19, 2026 09:37
alan-agius4
alan-agius4 approved these changes Oct 19, 2026
View reviewed changes
@alan-agius4 alan-agius4 added action: merge The PR is ready for merge by the caretaker and removed action: cleanup The PR is in need of cleanup, either due to needing a rebase or in response to comments from reviews labels Oct 19, 2026
clydin
clydin requested changes Oct 19, 2026
View reviewed changes

@clydin clydin left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This breaks legitimate use cases such as:
ng serve --ssl --ssl-key "$HOME/.certs/key.pem" --ssl-cert "$HOME/.certs/cert.pem"

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@clydin clydin removed the action: merge The PR is ready for merge by the caretaker label Oct 19, 2026
@MeAkib
fixup! fix(@angular/build): resolve dev-server sslKey and sslCert…
83c6edd
… relative to the workspace root
@MeAkib
MeAkib requested a review from clydin October 19, 2026 18:29
@alan-agius4 alan-agius4 added the action: review The PR is still awaiting reviews from at least one requested reviewer label Oct 19, 2026
thekhegay
thekhegay reviewed Oct 20, 2026
View reviewed changes
Comment thread packages/angular/build/src/builders/dev-server/options.ts Resolved

Uh oh!

There was an error while loading. Please reload this page.

@MeAkib
fix(@angular-devkit/build-angular): resolve dev-server sslKey and `…
9fc42b1
…sslCert` relative to the workspace root

Previously, the esbuild-based dev-server passed relative `sslKey` and `sslCert` paths to Vite as
is, so they were read relative to the current directory and `ng serve` failed with ENOENT when run
outside the workspace root. The paths are now resolved against the workspace root, matching
`@angular/build`.
@angular-robot angular-robot Bot added the area: @angular-devkit/build-angular label Oct 21, 2026
@MeAkib
MeAkib requested a review from thekhegay October 22, 2026 01:59
thekhegay
thekhegay approved these changes Oct 22, 2026
View reviewed changes

@thekhegay thekhegay left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, build-angular dev-server now resolves sslKey/sslCert from workspace root same as @angular/build, and new spec covers that path

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
clydin
clydin approved these changes Oct 22, 2026
View reviewed changes
@clydin clydin removed the action: review The PR is still awaiting reviews from at least one requested reviewer label Oct 22, 2026
@alan-agius4 alan-agius4 added the action: merge The PR is ready for merge by the caretaker label Oct 22, 2026
@clydin

clydin commented Oct 23, 2026

Copy link
Copy Markdown
Member

This PR was merged into the repository. The changes were merged into the following branches:

  • main: d2aafa2
  • 22.2.x: 0c4bd19
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@clydin clydin closed this in fe60e27 Oct 23, 2026
clydin pushed a commit that referenced this pull request Oct 23, 2026
@MeAkib @clydin
fix(@angular/build): resolve dev-server sslKey and sslCert relati…
47075be
…ve to the workspace root (#34399)

The Vite-based dev server read `sslKey` and `sslCert` relative to the current working directory,
so serving failed with `ENOENT` when `ng serve` ran from a subdirectory of the workspace and the
paths in `angular.json` were relative. Resolve both paths against the workspace root, as the
webpack dev server already does.

The new dev-server `ssl` spec covers relative paths. It fails with `ENOENT` without this change.

PR Close #34399
clydin pushed a commit that referenced this pull request Oct 23, 2026
@MeAkib @clydin
fix(@angular-devkit/build-angular): resolve dev-server sslKey and `…
0c4bd19
…sslCert` relative to the workspace root (#34399)

Previously, the esbuild-based dev-server passed relative `sslKey` and `sslCert` paths to Vite as
is, so they were read relative to the current directory and `ng serve` failed with ENOENT when run
outside the workspace root. The paths are now resolved against the workspace root, matching
`@angular/build`.

PR Close #34399
opensource-fork-sync Bot pushed a commit to cla7aye15I4nd/opensource-angular__angular-cli that referenced this pull request Oct 23, 2026
@MeAkib @clydin
fix(@angular-devkit/build-angular): resolve dev-server sslKey and `…
d2aafa2
…sslCert` relative to the workspace root (angular#34399)

Previously, the esbuild-based dev-server passed relative `sslKey` and `sslCert` paths to Vite as
is, so they were read relative to the current directory and `ng serve` failed with ENOENT when run
outside the workspace root. The paths are now resolved against the workspace root, matching
`@angular/build`.

PR Close angular#34399
@MeAkib
MeAkib deleted the fix/dev-server-ssl-paths branch October 27, 2026 15:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@alan-agius4 alan-agius4 alan-agius4 approved these changes
@clydin clydin clydin approved these changes
+2 more reviewers
@gemini-code-assist gemini-code-assist[bot] gemini-code-assist[bot] left review comments
@thekhegay thekhegay thekhegay approved these changes
Reviewers whose approvals may not affect merge requirements

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

action: merge The PR is ready for merge by the caretaker area: @angular/build area: @angular-devkit/build-angular target: patch This PR is targeted for the next patch release

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

4 participants

@MeAkib @clydin @thekhegay @alan-agius4
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.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.