Feature/cleanup#374
Conversation
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
🚀 Deploy this PR to an environmentYou can deploy this PR to either development or staging environment:
Alternatively, you can:
|
There was a problem hiding this comment.
Pull request overview
This PR cleans up and simplifies the bot by removing unused/legacy services (reaction roles + auto-threading), while also adding/bundling new profile-card skin assets and updating the Docker build to bake static assets and install required fonts.
Changes:
- Added new skin JSON configs and related image assets under
SERVER/skinsandSERVER/images. - Updated
Dockerfileand added.dockerignoreto improve build caching, bake static assets into the container, and install MS core fonts. - Removed the Reaction Roles feature and Auto-Thread feature (services, modules, settings, and preconditions), plus associated settings cleanup.
Reviewed changes
Copilot reviewed 18 out of 37 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| SERVER/skins/skin.json | Adds a new “Sleek” profile card skin configuration (currently invalid JSON). |
| SERVER/skins/skin.default.json | Adds a “Default” skin configuration. |
| SERVER/skins/skin.alaanor.json | Adds a “flat” skin configuration (currently not valid JSON due to comments/typos). |
| SERVER/skins/resources/foreground_sleek.png | Adds the Sleek foreground image asset. |
| SERVER/skins/foreground.png | Adds a foreground image asset used by skins. |
| SERVER/skins/alpha.png | Adds an alpha mask/asset used by skins. |
| SERVER/images/triangle.png | Adds triangle image asset (rank decoration). |
| SERVER/images/levelupcardbackground.png | Adds level-up card background image asset. |
| SERVER/images/levelupcard.png | Adds level-up card image asset. |
| SERVER/images/foreground.png | Adds/duplicates a foreground image asset under SERVER/images. |
| SERVER/images/default.png | Adds default avatar placeholder image. |
| SERVER/images/Layout.txt | Adds layout notes/spec for image composition. |
| Dockerfile | Improves build layering, bakes static assets into runtime image, and installs MS core fonts. |
| DiscordBot/Utils/Utils.cs | Removes GetMaxThreadDuration helper (auto-thread feature removal). |
| DiscordBot/Settings/Settings.example.json | Removes unused settings entries related to removed features. |
| DiscordBot/Settings/ReactionRoles.json | Deletes reaction role settings file. |
| DiscordBot/Settings/Deserialized/Settings.cs | Removes settings classes/fields tied to removed features (reaction roles + auto-thread). |
| DiscordBot/Settings/Deserialized/ReactionRole.cs | Deletes deserialized reaction role settings models. |
| DiscordBot/Services/UserService.cs | Unsubscribes/removes auto-thread handler code. |
| DiscordBot/Services/ReactRoleService.cs | Deletes the reaction role service implementation. |
| DiscordBot/Program.cs | Removes DI registration for ReactRoleService. |
| DiscordBot/Modules/UserModule.cs | Removes auto-thread commands and related code. |
| DiscordBot/Modules/ReactionRoleModule.cs | Deletes the reaction role command module. |
| DiscordBot/Extensions/ReactMessageExtensions.cs | Deletes reaction message extension helpers. |
| DiscordBot/Attributes/ThreadAttributes.cs | Deletes thread/auto-thread precondition attributes. |
| .dockerignore | Adds Docker ignore rules to reduce build context and avoid baking runtime Settings into the image. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <copilot@github.com>
|
/deploy_dev |
|
🚀 Starting deployment of |
|
/deploy_dev |
|
🚀 Starting deployment of |
- Add Assets/ directory inside DiscordBot/ for read-only static files (fonts, images, skins) with new AssetsRootPath setting - Move FAQs.json from SERVER/ to Settings/ (human-authored config) - Move reminders.json path from Settings/ to SERVER/ (bot-generated) - Update UserService to read skins/images from AssetsRootPath - Update Dockerfile to COPY assets from DiscordBot/Assets/ - Add read-only volume mount for Assets in docker-compose - Add DiscordBot/SERVER/ to .gitignore (runtime-generated data) - Remove stale .psd source files and duplicate static assets Co-authored-by: Copilot <copilot@github.com>
|
/deploy_dev |
|
🚀 Starting deployment of |
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 24 out of 49 changed files in this pull request and generated 5 comments.
Comments suppressed due to low confidence (2)
DiscordBot/Assets/skins/skin.default.json:96
- The
Layersarray no longer includes a layer with"Image": "avatar".UserService.GenerateProfileCardcomposites the user picture only when a layer’sImageis"avatar", so removing that layer will result in profile cards without an avatar unless the rendering code is updated to use the newAvatarX/AvatarYfields.
DiscordBot/Assets/skins/skin.alaanor.json:115 - The newly added module uses
"TextAlignmnent"(misspelled). The skin text modules expectTextAlignment(seeBaseTextSkinModule.TextAlignment), so this field will be ignored and alignment will default, likely producing incorrect layout. Rename the key toTextAlignmentin the skin JSON.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Namespace, bot deployment, MySQL, backup, phpMyAdmin, ExternalSecrets - ConfigMaps for bot settings (Settings.json, Rules.json, FAQs.json, UserSettings.json) - Moved from GitOps cluster repo to live alongside application code
Co-authored-by: Copilot <copilot@github.com>
- Add deploy-dev.yml: push to dev -> build -> GHCR -> update manifest - Add deploy-prod.yml: push to master -> build -> GHCR -> update manifest - Add deploy-pr-to-dev.yml: /deploy_dev PR command for GitOps - Add pr-deploy-instructions.yml: PR deploy instructions comment - Update Dotnet.yml: action versions v4, add permissions - Fix prod bot.yaml: use udc-bot image instead of udc-bot-dev - Remove old SSH-based workflows (Build&Deploy, DeployDev, DeployProd, AddCommentOnPR, HandleDeployCommand)
|
/deploy_dev |
|
🚀 Starting deployment of |
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 51 out of 76 changed files in this pull request and generated 5 comments.
Comments suppressed due to low confidence (1)
DiscordBot/Assets/skins/skin.alaanor.json:91
- The JSON uses
TextAlignmnent(misspelled) instead of theTextAlignmentproperty expected byBaseTextSkinModule. This means alignment settings from this skin won't be applied (and may leave text mis-positioned). Rename these keys toTextAlignment(and keep the value formatting consistent with other skins).
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- phpmyadmin:5 -> phpmyadmin:5.2.3 - databack/mysql-backup:latest -> databack/mysql-backup:1.4.0
Add author_association check to deploy-pr-to-dev workflow. Only MEMBER, COLLABORATOR, and OWNER can trigger PR deploys, preventing untrusted users from building arbitrary code.
Replace single deploy-pr-to-dev.yml with two workflows to resolve CodeQL untrusted-checkout alert (actions/untrusted-checkout/high): - deploy-pr-build.yml: unprivileged, builds and pushes image (no contents:write) - deploy-pr-push.yml: privileged, updates manifest (no untrusted code checkout)
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
- Create build-and-deploy.yml reusable workflow (workflow_call) - Simplify deploy-dev.yml and deploy-prod.yml to thin wrappers - Replace issue_comment trigger with workflow_dispatch for PR deploys (resolves CodeQL untrusted-checkout/high alert) - Delete deploy-pr-build.yml and deploy-pr-push.yml (two-workflow split) - Update pr-deploy-instructions.yml to reference Actions tab
|
/deploy dev |
|
/deploy_dev |
|
🚀 Starting deployment of |
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 52 out of 77 changed files in this pull request and generated 8 comments.
Comments suppressed due to low confidence (1)
DiscordBot/Assets/skins/skin.alaanor.json:115
TextAlignmnentis misspelled and won’t bind toBaseTextSkinModule.TextAlignment, so alignment will silently fall back to the enum default. Rename this field toTextAlignment(including in the newly addedTotalXpmodule) to get the intended text positioning.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| readinessProbe: | ||
| exec: | ||
| command: | ||
| - mysqladmin | ||
| - ping | ||
| - -h | ||
| - localhost | ||
| initialDelaySeconds: 15 |
There was a problem hiding this comment.
mysqladmin ping is executed without any credentials. With MYSQL_ROOT_PASSWORD set, mysqladmin typically returns "Access denied" and the readiness probe will fail continuously. Update the probe command to authenticate (e.g., pass -u root and a password via env) and consider using 127.0.0.1 to avoid DNS issues.
| readinessProbe: | ||
| exec: | ||
| command: | ||
| - mysqladmin | ||
| - ping | ||
| - -h | ||
| - localhost | ||
| initialDelaySeconds: 15 |
There was a problem hiding this comment.
Same issue as prod: mysqladmin ping is run without credentials while MYSQL_ROOT_PASSWORD is set, so the readiness probe is likely to fail ("Access denied"). Update the probe to provide -u/-p (from env) so the pod can become Ready.
| types: [opened] | ||
|
|
||
| permissions: | ||
| pull-requests: write |
There was a problem hiding this comment.
This workflow calls github.rest.issues.createComment(...), but the workflow permissions only grant pull-requests: write. Add issues: write (or switch to the pulls API) so the comment creation isn’t rejected with a 403 due to insufficient permissions.
| pull-requests: write | |
| pull-requests: write | |
| issues: write |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…Community/UDC-Bot into feature/cleanup
No description provided.