Skip to content

CI/workflow and devcontainer optimizations for build speed and developer experience - #43

Draft
Snapp949 with Copilot wants to merge 4 commits into
mainfrom
copilot/featureci-optimizations-again
Draft

CI/workflow and devcontainer optimizations for build speed and developer experience#43
Snapp949 with Copilot wants to merge 4 commits into
mainfrom
copilot/featureci-optimizations-again

Conversation

Copilot AI commented Nov 28, 2025

Copy link
Copy Markdown

Packages impacted by this PR

None (CI/DevOps infrastructure only)

Issues associated with this PR

N/A

Describe the problem that is addressed by this PR

Adds CI optimizations and devcontainer support for the samples/horizon-ui-pro-nextjs-ts sample project:

  • New sample CI workflow (.github/workflows/sample-ci.yml)

    • Triggers on push/workflow_dispatch with branch-scoped concurrency (cancel-in-progress)
    • Node.js setup with npm cache + actions/cache for node_modules
    • Graceful handling of private package auth failures via continue-on-error
    • Explicit permissions: contents: read for security
  • Concurrency for existing workflows

    • event-processor.yml and scheduled-event-processor.yml: Added concurrency: group: ${{ github.workflow }} with cancel-in-progress: true
    • Added comments showing where to add actions/cache for NuGet packages
  • Devcontainer (samples/horizon-ui-pro-nextjs-ts/.devcontainer/devcontainer.json)

    • Port 3000 forwarding, remoteUser: codespace, postCreateCommand runs npm ci
  • Documentation (.github/DEVOPS.md)

    • Caching patterns, concurrency config, secrets guidance (NPM_TOKEN, ZILLOW_API_KEY), local CI execution with act

What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?

Standard GitHub Actions patterns. Used continue-on-error with conditional steps for graceful private package handling rather than exit 0 to avoid masking failures in subsequent steps.

Are there test cases added in this PR? (If not, why?)

No—these are workflow/infrastructure files. Validation via YAML/JSON parsing and CodeQL security scanning.

Provide a list of related PRs (if any)

None

Command used to generate this PR:**(Applicable only to SDK release request PRs)

N/A

Checklists

  • Added impacted package name to the issue description
  • Does this PR needs any fixes in the SDK Generator?** (If so, create an Issue in the Autorest/typescript repository and link it here)
  • Added a changelog (if necessary)
Original prompt

Implement CI/workflow and devcontainer optimizations to improve build speed and developer experience. Create a new branch feature/ci-optimizations and open a draft PR against main. Changes to make (do not commit any secrets):

  1. Add a minimal sample CI workflow at .github/workflows/sample-ci.yml that:

    • triggers on push to branches and workflow_dispatch
    • checks out code, sets up Node (cache: 'npm'), installs dependencies in samples/horizon-ui-pro-nextjs-ts using npm ci, runs npm run build in that folder
    • uses concurrency: cancel-in-progress for same branch
    • uses actions/cache to cache node_modules keyed on package-lock
    • if npm ci fails due to private packages, exit gracefully without failing the job
  2. Modify existing workflows to add concurrency keys and helpful comments about caching:

    • .github/workflows/event-processor.yml: add top-level concurrency: group: ${{ github.workflow }} and cancel-in-progress: true and add a comment showing where to add actions/cache for node/dotnet steps
    • .github/workflows/scheduled-event-processor.yml: add top-level concurrency: group: ${{ github.workflow }} and cancel-in-progress: true and similar comment
  3. Add samples/horizon-ui-pro-nextjs-ts/.devcontainer/devcontainer.json to speed up Codespaces for the sample. It should forward port 3000, set remoteUser to 'codespace', and run postCreateCommand 'cd samples/horizon-ui-pro-nextjs-ts && npm ci'. Do not include tokens.

  4. Add .github/DEVOPS.md with short documentation describing caching, concurrency, how to add NPM_TOKEN and ZILLOW_API_KEY safely, and how to run the sample CI locally. Keep it concise.

Files to add/modify (exact paths):

  • Add: .github/workflows/sample-ci.yml
  • Modify: .github/workflows/event-processor.yml
  • Modify: .github/workflows/scheduled-event-processor.yml
  • Add: samples/horizon-ui-pro-nextjs-ts/.devcontainer/devcontainer.json
  • Add: .github/DEVOPS.md

Constraints and notes:

  • Do not add or commit any secrets or tokens.
  • Keep changes focused and safe: do not modify or remove event logic; only add concurrency and comments for cache usage.
  • Open the PR as a Draft and include a descriptive PR body explaining what changed and why, and how to test.

Please create the branch, commit the changes, and open the draft PR. Thank you.

This pull request was created as a result of the following prompt from Copilot chat.

Implement CI/workflow and devcontainer optimizations to improve build speed and developer experience. Create a new branch feature/ci-optimizations and open a draft PR against main. Changes to make (do not commit any secrets):

  1. Add a minimal sample CI workflow at .github/workflows/sample-ci.yml that:

    • triggers on push to branches and workflow_dispatch
    • checks out code, sets up Node (cache: 'npm'), installs dependencies in samples/horizon-ui-pro-nextjs-ts using npm ci, runs npm run build in that folder
    • uses concurrency: cancel-in-progress for same branch
    • uses actions/cache to cache node_modules keyed on package-lock
    • if npm ci fails due to private packages, exit gracefully without failing the job
  2. Modify existing workflows to add concurrency keys and helpful comments about caching:

    • .github/workflows/event-processor.yml: add top-level concurrency: group: ${{ github.workflow }} and cancel-in-progress: true and add a comment showing where to add actions/cache for node/dotnet steps
    • .github/workflows/scheduled-event-processor.yml: add top-level concurrency: group: ${{ github.workflow }} and cancel-in-progress: true and similar comment
  3. Add samples/horizon-ui-pro-nextjs-ts/.devcontainer/devcontainer.json to speed up Codespaces for the sample. It should forward port 3000, set remoteUser to 'codespace', and run postCreateCommand 'cd samples/horizon-ui-pro-nextjs-ts && npm ci'. Do not include tokens.

  4. Add .github/DEVOPS.md with short documentation describing caching, concurrency, how to add NPM_TOKEN and ZILLOW_API_KEY safely, and how to run the sample CI locally. Keep it concise.

Files to add/modify (exact paths):

  • Add: .github/workflows/sample-ci.yml
  • Modify: .github/workflows/event-processor.yml
  • Modify: .github/workflows/scheduled-event-processor.yml
  • Add: samples/horizon-ui-pro-nextjs-ts/.devcontainer/devcontainer.json
  • Add: .github/DEVOPS.md

Constraints and notes:

  • Do not add or commit any secrets or tokens.
  • Keep changes focused and safe: do not modify or remove event logic; only add concurrency and comments for cache usage.
  • Open the PR as a Draft and include a descriptive PR body explaining what changed and why, and how to test.

Please create the branch, commit the changes, and open the draft PR. Thank you.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Copilot AI and others added 3 commits November 28, 2025 07:09
Co-authored-by: Snapp949 <173113150+Snapp949@users.noreply.github.com>
Co-authored-by: Snapp949 <173113150+Snapp949@users.noreply.github.com>
Co-authored-by: Snapp949 <173113150+Snapp949@users.noreply.github.com>
Copilot AI changed the title [WIP] Add CI workflow and optimize build process CI/workflow and devcontainer optimizations for build speed and developer experience Nov 28, 2025
Copilot AI requested a review from Snapp949 November 28, 2025 07:13
@github-actions

Copy link
Copy Markdown

Hi @Copilot. Thank you for your interest in helping to improve the Azure SDK experience and for your contribution. We've noticed that there hasn't been recent engagement on this pull request. If this is still an active work stream, please let us know by pushing some changes or leaving a comment. Otherwise, we'll close this out in 7 days.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants