Skip to content

Comments

YJDH-723 | Kesäseteli: Split .env.kesaseteli to .env.kesaseteli-(backend|handler|youth|employer) files#3883

Merged
karisal-anders merged 3 commits intomainfrom
YJDH-723-env-file-per-app
Feb 13, 2026
Merged

YJDH-723 | Kesäseteli: Split .env.kesaseteli to .env.kesaseteli-(backend|handler|youth|employer) files#3883
karisal-anders merged 3 commits intomainfrom
YJDH-723-env-file-per-app

Conversation

@karisal-anders
Copy link
Collaborator

@karisal-anders karisal-anders commented Feb 13, 2026

Description ✨

Kesäseteli: Split .env.kesaseteli to .env.kesaseteli-(backend|handler|youth|employer) files

Why?

  • So that UI specific Matomo site IDs can be configured using
    the same environment variable i.e. NEXT_PUBLIC_MATOMO_SITE_ID in the
    future in relation to YJDH-723
    ("Include Matomo analytics (Digia Iiris) to frontends").
  1. Move .env.kesaseteli.example verbatim to:
  • .env.kesaseteli-backend.example
  • .env.kesaseteli-employer.example
  • .env.kesaseteli-handler.example
  • .env.kesaseteli-youth.example
  1. Prune & augment env example files

Pruning (i.e. removing the unnecessary):

  • Went through all the .env.kesaseteli-*.example files that were copied
    in previous commit from .env.kesaseteli.example.
  • Removed from each .env.kesaseteli-*.example file what was not needed
    by the application in question
  • Removed unnecessary use of HANDLER_URL from youth frontend

Augmenting (i.e. adding what can be used):

  • Added to .env.kesaseteli-backend.example file the backend's sentry
    variables that were not listed, but were being used in kesaseteli's
    settings.py
  1. Use .env.kesaseteli- files

Change uses of .env.kesaseteli to .env.kesaseteli-backend,
.env.kesaseteli-handler, .env.kesaseteli-employer,
.env.kesaseteli-youth where applicable.

NOTE: Only a single code uses .env.kesaseteli anymore, and that's in
/frontend/next.config.js the loading of .env.kesaseteli:

const { parsed: env } = require('dotenv').config({
  path: '.env.kesaseteli',
});

which is actually weird, as that's the next.config.js file for the
monorepo's shared frontend, not Kesäseteli specific at all! This can be
removed in another PR handling the shared parts of the monorepo.

Issues 🐛

YJDH-723

Testing ⚗️

Screenshots 📸

Additional notes 🗒️

@karisal-anders karisal-anders requested review from a team as code owners February 13, 2026 09:23
@karisal-anders karisal-anders removed request for a team February 13, 2026 09:23
move .env.kesaseteli.example verbatim to:
- .env.kesaseteli-backend.example
- .env.kesaseteli-employer.example
- .env.kesaseteli-handler.example
- .env.kesaseteli-youth.example

refs YJDH-723 (needs site ID per app for Matomo)
Pruning (i.e. removing the unnecessary):
- Went through all the .env.kesaseteli-*.example files that were copied
  in previous commit from .env.kesaseteli.example.
- Removed from each .env.kesaseteli-*.example file what was not needed
  by the application in question
- Removed unnecessary use of HANDLER_URL from youth frontend

Augmenting (i.e. adding what can be used):
- Added to .env.kesaseteli-backend.example file the backend's sentry
  variables that were not listed, but were being used in kesaseteli's
  settings.py

refs YJDH-723
Change uses of `.env.kesaseteli` to `.env.kesaseteli-backend`,
`.env.kesaseteli-handler`, `.env.kesaseteli-employer`,
`.env.kesaseteli-youth` where applicable.

NOTE: Only a single code uses `.env.kesaseteli` anymore, and that's in
/frontend/next.config.js the loading of `.env.kesaseteli`:
```
const { parsed: env } = require('dotenv').config({
  path: '.env.kesaseteli',
});
```
which is actually weird, as that's the next.config.js file for the
monorepo's shared frontend, not Kesäseteli specific at all! This can be
removed in another PR handling the shared parts of the monorepo.

refs YJDH-723
@karisal-anders karisal-anders force-pushed the YJDH-723-env-file-per-app branch from a1a1e86 to 590c5f2 Compare February 13, 2026 09:26
@azure-pipelines
Copy link

YJDH-KESASETELI-API branch is deployed to platta: https://yjdh-kesaseteli-pr3883.api.dev.hel.ninja 🚀🚀🚀

@sonarqubecloud
Copy link

@azure-pipelines
Copy link

EMPLOYER branch is deployed to platta: https://kesaseteli-pr3883.dev.hel.ninja 🚀🚀🚀

@azure-pipelines
Copy link

HANDLER branch is deployed to platta: https://kesaseteli-handler-ui-pr3883.dev.hel.ninja 🚀🚀🚀

@azure-pipelines
Copy link

YOUTH branch is deployed to platta: https://nuortenkesaseteli-pr3883.dev.hel.ninja 🚀🚀🚀

@azure-pipelines
Copy link

TestCafe result is success for https://kesaseteli-pr3883.dev.hel.ninja 😆🎉🎉🎉

@azure-pipelines
Copy link

TestCafe result is success for https://kesaseteli-handler-ui-pr3883.dev.hel.ninja 😆🎉🎉🎉

@azure-pipelines
Copy link

TestCafe result is success for https://nuortenkesaseteli-pr3883.dev.hel.ninja 😆🎉🎉🎉

@karisal-anders karisal-anders merged commit 246be9b into main Feb 13, 2026
74 checks passed
@karisal-anders karisal-anders deleted the YJDH-723-env-file-per-app branch February 13, 2026 10:35
karisal-anders added a commit that referenced this pull request Feb 13, 2026
As mentioned in 246be9b in PR #3883
> NOTE: Only a single code uses `.env.kesaseteli` anymore, and that's in
> /frontend/next.config.js the loading of `.env.kesaseteli`:
> ```
> const { parsed: env } = require('dotenv').config({
>   path: '.env.kesaseteli',
> });
> ```
> which is actually weird, as that's the next.config.js file for the
> monorepo's shared frontend, not Kesäseteli specific at all! This can
> be removed in another PR handling the shared parts of the monorepo.

Remove the above leftover loading of `.env.kesaseteli` file from shared
frontend code.

refs YJDH-723
karisal-anders added a commit that referenced this pull request Feb 16, 2026
As mentioned in 246be9b in PR #3883
> NOTE: Only a single code uses `.env.kesaseteli` anymore, and that's in
> /frontend/next.config.js the loading of `.env.kesaseteli`:
> ```
> const { parsed: env } = require('dotenv').config({
>   path: '.env.kesaseteli',
> });
> ```
> which is actually weird, as that's the next.config.js file for the
> monorepo's shared frontend, not Kesäseteli specific at all! This can
> be removed in another PR handling the shared parts of the monorepo.

Remove the above leftover loading of `.env.kesaseteli` file from shared
frontend code.

refs YJDH-723
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.

1 participant