-
Notifications
You must be signed in to change notification settings - Fork 0
[build] deploy client as a server resource #126
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
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.
Pull request overview
This PR consolidates the client and server into a single deployable unit by bundling the client frontend assets into the server's resources. The architecture is simplified from a two-container deployment (separate client and server) to a single-container deployment where the server serves both API endpoints and static frontend assets.
Key Changes:
- Client assets are now bundled into the server's resources at build time and served via new resource routes
- Removed separate client Docker image and deployment; only a single server image is built
- Updated all client API calls to use relative paths instead of absolute URLs with a BASE_URI constant
Reviewed changes
Copilot reviewed 15 out of 16 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| server/src/main/scala/ru/trett/rss/server/Server.scala | Added resourceRoutes method to serve static client files from resources; reformatted imports to individual statements |
| server/src/main/resources/application.conf | Changed default port from 8080 to 80 and protocol from HTTPS to HTTP for local development |
| scripts/local-docker/docker-compose.yml | Removed client service and updated CORS URL to HTTP; removed deprecated version field |
| scripts/local-docker/Caddyfile | Simplified to proxy all requests to server; removed separate client routing |
| scripts/local-dev/docker-compose.yml | Removed entire local development docker-compose setup |
| scripts/local-dev/Caddyfile | Removed local development Caddyfile |
| client/vite.config.js | Removed trailing comma (formatting) |
| client/src/main/scala/client/SummaryPage.scala | Changed API call to use relative path instead of HOST constant |
| client/src/main/scala/client/SettingsPage.scala | Changed all API calls to use relative paths instead of HOST constant |
| client/src/main/scala/client/NetworkUtils.scala | Removed HOST constant definition |
| client/src/main/scala/client/NavBar.scala | Changed API call to use relative path; removed BASE_URI import |
| client/src/main/scala/client/LoginPage.scala | Changed OAuth URLs to use relative paths; removed HOST import |
| client/src/main/scala/client/Home.scala | Changed all API calls to use relative paths instead of HOST constant |
| build.sbt | Removed client Docker configuration; added resource generator to bundle client dist into server resources; renamed buildImages/pushImages tasks to singular form; removed AppConfig source generator |
| README.md | Updated documentation to reflect single-image deployment and simplified development workflow |
| .github/workflows/build.yml | Updated workflow to use singular pushImage task |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
|
@copilot update project version to 2.9.9. Don't forget docker-compose file. |
* Initial plan * chore: update project version to 2.9.9 Co-authored-by: trett <1980024+trett@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: trett <1980024+trett@users.noreply.github.com>
* Initial plan * fix: Update project version to 2.2.9 Co-authored-by: trett <1980024+trett@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: trett <1980024+trett@users.noreply.github.com>
No description provided.