Skip to content

Commit 611ec39

Browse files
committed
Fix literalis WFS import
1 parent 42fa6be commit 611ec39

File tree

3 files changed

+15
-0
lines changed

3 files changed

+15
-0
lines changed

.github/workflows/litteralis_import.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,10 @@ jobs:
8686
- name: Run import
8787
run: make ci_litteralis_import BIN_PHP="php" BIN_CONSOLE="php bin/console" BIN_COMPOSER="composer"
8888

89+
- name: Run communication import
90+
if: ${{ vars.APP_LITTERALIS_COMMUNICATION_ENABLED_ORGS != '' && vars.APP_LITTERALIS_COMMUNICATION_ENABLED_ORGS != '[]' }}
91+
run: make ci_litteralis_import_communication BIN_PHP="php" BIN_CONSOLE="php bin/console"
92+
8993
- name: Get log file path
9094
id: logfile
9195
if: ${{ !cancelled() }}

Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -289,6 +289,8 @@ ci_litteralis_import: ## Run CI steps for Litteralis Import workflow
289289
scalingo login --ssh --ssh-identity ~/.ssh/id_rsa
290290
./tools/scalingodbtunnel dialog --host-url --port 10000 & ./tools/wait-for-it.sh 127.0.0.1:10000
291291
make console CMD="app:litteralis:import"
292+
293+
ci_litteralis_import_communication: ## Run CI steps for Litteralis Communication Import workflow
292294
make console CMD="app:litteralis:import-communication"
293295

294296
ci_bdtopo_migrate: ## Run CI steps for BD TOPO Migrate workflow

src/Infrastructure/Integration/Litteralis/LitteralisCommunicationExtractor.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,15 @@ public function configure(array $enabledOrgs, LitteralisCredentials $credentials
3939

4040
foreach ($enabledOrgs as $name) {
4141
$orgCredentials = $credentials->getCredentials($name);
42+
43+
if (empty($orgCredentials)) {
44+
throw new \RuntimeException(\sprintf(
45+
'Organization "%s": missing credentials (check APP_LITTERALIS_ORG_%s_CREDENTIALS)',
46+
$name,
47+
strtoupper($name),
48+
));
49+
}
50+
4251
$client = $this->clientFactory->create($orgCredentials);
4352
$this->clients[$name] = $client;
4453
}

0 commit comments

Comments
 (0)