52 Commits

Author SHA1 Message Date
claude 65ae4b42da myai: document MSSQL host as mssql.easysoft.ro (DNS name) in the env template
Deployed staging/prod envs now use Database__Host=mssql.easysoft.ro (LAN DNS -> the MSSQL
VM 10.0.0.240) instead of the raw IP, matching the infra DNS standardization. The
docker-compose default stays 'sqlserver' for local dev. (.env/.env.staging/.env.production
are gitignored; their deployed values were updated locally and apply on redeploy.)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-23 17:01:06 +03:00
claude df011f2a03 Fix PageFetcherApi BaseUrl default to use Docker service name, not container name
Use http://page-fetcher-api:8080 (the Compose service key) for Docker DNS
resolution, consistent with all other internal service URLs (rag-api,
email-api, cv-matcher-api).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-08 17:49:00 +03:00
claude 898dd09d50 feat: add page-fetcher-api — centralised Playwright page fetcher
Introduces page-fetcher-api, a new internal ASP.NET Core service that
centralises all web-page fetching through a single Playwright (headless
Chromium) browser instance. All fetches are persisted to the pageFetcher
SQL schema for auditing.

New projects:
- Apis/page-fetcher-api-models: FetchPageRequest, FetchPageResponse, IPageFetcherApiClient
- Apis/page-fetcher-data: PageFetchDbContext, PageFetchEntity, InitialSchema migration (schema: pageFetcher)
- Apis/page-fetcher-api: PlaywrightBrowserService (singleton), PageFetcherService, PageController

Changes to existing services:
- cv-matcher-api: JobTextExtractor now calls IPageFetcherApiClient instead of HttpClient
- cv-search-job: HtmlJobSearcher uses IPageFetcherApiClient (removes inline Playwright);
  CvSearchJobTask fetches individual job pages and applies keyword pre-filter before
  LLM call; passes pre-fetched JobDescription to cv-matcher-api to skip re-fetch
- common: add PageFetcherApiSettings
- docker-compose.yml, build.yml: add new service + env vars for callers

Closes #43

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-08 17:43:56 +03:00
claude b67e926c5f Fix Serilog email sink: configure in code, not JSON config
Serilog.Settings.Configuration cannot deserialize NetworkCredential or
MailKit's SecureSocketOptions from JSON, causing an InvalidOperationException
in the binder and preventing containers from starting.

Fix: remove Email from the WriteTo JSON array entirely and wire it in code
inside ConfigureJsonSerilog using a dedicated SerilogEmail:* config section.
The sink is skipped when From/To/Host are absent, so local dev is unaffected.

Also renames the docker-compose env vars from the verbose
Serilog__WriteTo__2__Args__* prefix to the clean SerilogEmail__* prefix.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-01 22:25:26 +03:00
claude 8679bd1efd Fix Serilog email sink config for v4 API breaking changes
Serilog.Sinks.Email v4 renamed all configuration parameters from their
v2 names. The old names were silently ignored, so no error alert emails
were ever sent.

Parameter renames applied across all 6 appsettings.json and docker-compose:
  fromEmail → from
  toEmail   → to
  mailServer → host
  networkCredential → credentials
  enableSsl: true → connectionSecurity: StartTls
  emailSubject → subject
  outputTemplate → body
  batchPostingLimit / period removed (v4 batching uses a separate overload)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-01 21:57:06 +03:00
claude 1bcf95d8d4 Add download rate limit policy to template and docker-compose
Build and Push Docker Images Staging / build (push) Failing after 1m38s
5 requests / 1 min per IP. docker-compose.yml wired with ${VAR:-default}.
Staging and production .env files updated locally (gitignored).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-01 20:40:25 +03:00
claude 9d2c7af8eb Changes
Build and Push Docker Images Staging / build (push) Successful in 19s
2026-05-28 17:08:22 +03:00
claude cb45c8a312 Change 2026-05-28 14:24:12 +03:00
claude e17f17b566 feat(cv-search-job): replace MyAiDbContext+ITemplateService with IEmailTemplateService
- Add ProjectReference to email-api-data; remove myai-data reference
- Program.cs: register EmailApiDbContext (no migrate), IEmailTemplateRepository
  (scoped), IEmailTemplateService (singleton); remove MyAiDbContext +
  ITemplateService registrations and their migration call
- CvSearchEmailSender: inject IEmailTemplateService; replace
  _config["Contact:ToEmail"] with GetOperatorCopy("email.search-results.subject")
  for operator copy logic; remove IConfiguration injection
- docker-compose: remove Contact__ToEmail from cv-search-job service block;
  add Database__* env vars to email-api service (needed for EmailApiDbContext)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-28 08:45:18 +03:00
claude ba92c9f793 feat: wire email-api into docker-compose, .sln and CLAUDE.md
- docker-compose: add email-api service (internal, no ports)
  with Smtp__* + FileStorage__Path + Files volume mount
- api + cv-search-job: remove Smtp__* vars, add EmailApi__BaseUrl
  and EmailApi__InternalApiKey; add depends_on: email-api
- .sln: move email-api-models to Models virtual folder
- CLAUDE.md: add email-api/email-api-models to layout, update
  service dependency diagram and internal API key table

Closes #22

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-27 16:26:56 +03:00
Claude Dev Environment 9d8db59825 fix: update web project port from 5000 to 5140 for Caddy reverse proxy alignment
- Changed CORS allowed origin from localhost:5000 to localhost:5140
- Updated docker-compose.override.yml port mapping from 5000:8080 to 5140:8080
- Aligns local development port with staging (myai.easysoft.ro) and production (myai.ro) Caddy reverse proxy configuration on port 5140
2026-05-27 13:05:40 +03:00
claude d08eb5d1dc fix: restore published port for myai-web + watchtower label
The docker-compose refactor moved port 5000:8080 to the override file.
Caddy on staging routes myai.easysoft.ro → localhost:5000, so the port
must be present in the deployment compose. Restoring it as WEB_PORT env var
(default 5000) and adding missing watchtower label.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-24 18:40:24 +03:00
claude 3cb6a8d702 fix: add Database env vars to api service in docker-compose
api now registers MyAiDbContext for template loading and needs
Database__* connection string vars like the other DB-connected services.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-24 18:16:34 +03:00
claude 7441eb8cda Remove APP_VERSION from docker-compose — version is baked into image by CI
Setting APP_VERSION in docker-compose with a :-unknown fallback would override
the version baked into the image at build time. The CI already embeds it via
--build-arg APP_VERSION=1.0.<commit-count>, so compose should stay silent.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-22 20:20:56 +03:00
claude 0154b56881 Add auto-incrementing version display to web UI footer
Exposes GET /version endpoint in the web container (reads APP_VERSION env var).
CI computes the version as 1.0.<git-commit-count> and passes it via --build-arg at build time.
Both index.html and cv-matcher/index.html show the version in the footer via a JS fetch.
docker-compose passes APP_VERSION through to the running container.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-22 20:18:31 +03:00
claude eced9531bc Merge 2026-05-22 20:04:12 +03:00
claude cf064531c5 Refactor docker-compose: single deployable file + local override
Build and Push Docker Images / build (push) Successful in 11s
- docker-compose.yml is now the single file for Portainer (staging and prod).
  Uses registry images with ${IMAGE_TAG:-staging}, ${LOGS_PATH:-/opt/myai/logs},
  and ${FILES_PATH:-/opt/myai/files} so the same file works for all environments.
- docker-compose.override.yml adds build context, ports, and env_file for local dev
  and is auto-merged by "docker compose up" (no extra flags needed).
- .env.template documents IMAGE_TAG, LOGS_PATH, FILES_PATH alongside existing vars.
- docker-compose.dcproj updated so override file nests under docker-compose.yml in
  Solution Explorer.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-22 18:52:39 +03:00
claude 6293fa89e3 Add internet job search feature (cv-search-job)
Build and Push Docker Images / build (push) Failing after 1m36s
- New cv-search-models shared library: EF entities + CvSearchDbContext for cvSearch schema (JobSearchTokens, JobSearchSessions, JobSearchResults tables)
- New cv-search-job worker service: polls DB for pending sessions, scrapes job boards via configurable HTML scraping, runs LLM scoring via cv-matcher-api, emails ranked results
- cv-matcher-api: JobTokenService creates one-time tokens; JobSearchController handles link clicks and creates sessions
- api: proxies job-search start endpoint, appends job search link to match result email
- CI workflow updated to build and push myai-cv-search-job:staging image
- CLAUDE.md documentation added for all affected services

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-22 17:56:23 +03:00
claude a0ae262afc Main build
Build and Push Docker Images / build (push) Successful in 7s
2026-05-20 21:16:34 +03:00
claude 6e54b20a02 Staging build 2026-05-20 21:11:25 +03:00
claude aa79b422e4 Changes
Build and Push Docker Images / build (push) Successful in 31s
2026-05-20 14:25:07 +03:00
claude 1a790ed9b4 Changes
Build and Push Docker Images / build (push) Successful in 5m57s
2026-05-14 15:04:30 +03:00
claude 9da9ac232b Changes
Build and Push Docker Images / build (push) Successful in 7s
2026-05-14 14:43:16 +03:00
claude 3b4f5a44b6 Refactor job configuration to rename and update CV cleanup job across Docker Compose files and build workflows
Build and Push Docker Images / build (push) Successful in 7s
2026-05-14 14:29:38 +03:00
claude 92278ae375 Update Dockerfile paths and project references to reflect new directory structure under 'Apis' and 'Jobs' 2026-05-14 13:56:45 +03:00
claude d4805b06e6 Changes 2026-05-13 09:38:52 +03:00
claude 5f69e0ffb4 Changes
Build and Push Docker Images / build (push) Successful in 29s
2026-05-12 10:20:03 +03:00
claude 0f7166c1a3 Changes
Build and Push Docker Images / build (push) Successful in 30s
2026-05-12 10:16:17 +03:00
claude cabf240397 Changes
Build and Push Docker Images / build (push) Successful in 35s
2026-05-11 16:50:05 +03:00
claude 66fe78a282 Changes
Build and Push Docker Images / build (push) Successful in 5s
2026-05-11 15:56:21 +03:00
claude 44aa19a92e Changes
Build and Push Docker Images / build (push) Successful in 17s
2026-05-11 13:09:09 +03:00
claude 3e1ea47007 Build changes
Build and Push Docker Images / build (push) Successful in 5s
2026-05-11 13:02:10 +03:00
claude e512317f33 Changes
Build and Push Docker Images / build (push) Successful in 43s
2026-05-11 12:33:51 +03:00
claude 25127f92a3 Changes
Build and Push Docker Images / build (push) Failing after 16s
2026-05-08 15:15:45 +03:00
claude 95e5d27140 Changes
Build and Push Docker Images / build (push) Failing after 3s
2026-05-08 15:09:05 +03:00
claude 68d7cef543 Changes
Build and Push Docker Images / build (push) Failing after 1s
2026-05-08 15:06:41 +03:00
claude 7d45daf393 Changes
Build and Push Docker Images / build (push) Failing after 1s
2026-05-08 14:52:04 +03:00
claude d8ed3c4fce Add ing labels 2026-05-08 14:37:22 +03:00
claude 845f41255f Changes
Build and Push Docker Images / build (push) Failing after 1s
2026-05-07 20:00:57 +03:00
claude fe3dbc37ad Changes
Build and Push Docker Images / build (push) Failing after 1s
2026-05-07 17:09:24 +03:00
claude 898f4987a5 Changes
Build and Push Docker Images / build (push) Failing after 1s
2026-05-07 14:48:00 +03:00
claude ae1db5e9a7 Changes
Build and Push Docker Images / build (push) Failing after 1s
2026-05-07 14:45:19 +03:00
claude 5f647b4561 Changes
Build and Push Docker Images / build (push) Failing after 1s
2026-05-07 14:40:49 +03:00
claude dc6b1afc1b Changes 2026-05-07 14:40:36 +03:00
claude 2807672074 Changes
Build and Push Docker Images / build (push) Failing after 1s
2026-05-07 14:25:16 +03:00
claude ebe4e449ad Changes
Build and Push Docker Images / build (push) Failing after 1s
2026-05-06 19:40:44 +03:00
claude 51933aaf1e Changes 2026-05-06 19:26:53 +03:00
claude a10908364b Changes 2026-05-06 15:17:20 +03:00
claude 711810d8c2 Changes 2026-05-06 14:48:12 +03:00
claude fa1ef23c02 Changes
Build and Push Docker Images / build (push) Successful in 37s
2026-05-04 21:02:35 +03:00