-
Notifications
You must be signed in to change notification settings - Fork 1
Update README and fix frontend unit tests failing after wizgod's changes #35
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
Open
connellr023
wants to merge
22
commits into
master
Choose a base branch
from
connell/fix-unit-tests-wizgod
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
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
Modified port mappings for `frontend` and `backend` services. The `frontend` now maps host port `8081` to container port `80`, and the `backend` maps host port `8082` to container port `8080`. Added `depends_on` for `frontend` to ensure it starts after `backend`. Both services have a restart policy of `unless-stopped`.
Added module, target, and include properties. Retained moduleResolution with a trailing comma for consistency.
This change adds a reference to the Vite client types in the `vite-env.d.ts` file, enabling TypeScript to recognize Vite-specific types and features in the project.
Updated the `AppConfig` struct in `app_config.go` to include two new fields: `Host` and `Port`, both of type `string`. This enhancement allows for more flexible configuration of the application's host and port settings.
Updated the `EnvToml` struct to include nested `Dev` and `Prod` structs for environment-specific `Host` and `Port` settings. Enhanced the `ToAppConfig` method to select the appropriate host and port based on the application's production status. The `AppConfig` struct now reflects these dynamic values.
Explicitly set Go version to 1.23 for compatibility. Add copying of .env.toml to the container for environment setup. Updated comments for clarity on changes made.
Replaced hardcoded backend development port with a dynamic backend host that reads from an environment variable. Removed `backendDevPort` and introduced `backendHost`, defaulting to `http://localhost:8080`. Updated URLs in `endpointMapping` to utilize the new `backendHost` for improved environment configuration flexibility. Refactor backend URL configuration Replaced hardcoded backend development port with a dynamic backend host URL sourced from an environment variable. Removed `backendDevPort` and introduced `backendHost`, defaulting to `http://localhost:8080`. Updated `endpointMapping` to utilize the new `backendHost` for constructing API endpoint URLs, enhancing adaptability to different backend configurations.
- Updated the dependency injection to determine the base URL and port based on the environment (development or production). - Modified the redirect URL to use the dynamically determined host and port. - Adjusted the main function to listen on the correct port and display the public-facing host. - Cleaned up the code for better readability and maintainability.
Modified the conditions for omitting the default port suffix in the `initDependencyInjection` function to include port `8080` in production, in addition to the existing checks for ports `443` and `80`.
Modified the Dockerfile to use the latest Go image when root access is available, allowing for version flexibility. Retained the option to use Go version 1.23 for consistency in rootless Docker environments. Updated comments to clarify the rationale behind the choice of Go version based on access level.
Updated the `EnvToml` struct to include a `Cors` field in both `Dev` and `Prod` environments. The `ToAppConfig` method now captures CORS settings based on the `InProduction` flag and includes them in the returned `AppConfig` struct.
Updated the `AppConfig` struct in `app_config.go` to include a new `Cors` field, which is a slice of strings (`[]string`). This enhancement allows the application to specify Cross-Origin Resource Sharing (CORS) settings, improving its ability to handle requests from different origins.
Updated the CORS middleware to accept a dynamic list of allowed origins instead of a single origin based on the environment. This change improves flexibility by allowing multiple origins to be specified during configuration.
Replaced the use of i.AppConfig.InProduction with i.AppConfig.Cors to better manage CORS settings based on the application's configuration.
…, and simplify env selection logic
…pport unit testing Also ran Prettier on constants.ts to address PR formatting request.
AndreyDiDev
previously approved these changes
Aug 2, 2025
The merge-base changed after approval.
AndreyDiDev
previously approved these changes
Aug 14, 2025
The merge-base changed after approval.
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.
No description provided.