Skip to content

Commit ace062f

Browse files
Merge branch 'main' of github.com:AgenceBio/cartobio-api into feat/refonte-carto
2 parents 1d3804c + c9cf7ab commit ace062f

15 files changed

+1514
-882
lines changed

.example.env

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,4 @@ NOTIFICATIONS_AB_SSO_CALLBACK_URI="http://localhost:8000/api/auth-provider/agenc
1919
SENTRY_DSN="https://...@o375473.ingest.sentry.io/..."
2020
NOTIFICATIONS_AB_ENDPOINT=https://...
2121
NOTIFICATIONS_AB_ORIGIN=https://...
22+
ATTESTATIONS_PRODUCTIONS_DIRECTORY='/something/...'

.github/workflows/docker.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,8 @@ jobs:
119119
--env-file=.env.cartobio-api-staging \
120120
--env SENTRY_RELEASE=${{ needs.build.outputs.version }}-dev-${{ github.sha }} \
121121
--name cartobio-api-staging \
122+
--init \
123+
--volume /root/pdf:/usr/src/app/pdf \
122124
${{ needs.build.outputs.image }}
123125
deploy-test:
124126
needs: [build]
@@ -140,6 +142,8 @@ jobs:
140142
--env-file=.env.cartobio-api-test \
141143
--env SENTRY_RELEASE=${{ needs.build.outputs.version }}-test-${{ github.sha }} \
142144
--name cartobio-api-test \
145+
--init \
146+
--volume /root/pdf_test:/usr/src/app/pdf \
143147
${{ needs.build.outputs.image }}
144148
deploy-production:
145149
needs: [build]
@@ -160,4 +164,6 @@ jobs:
160164
-p 127.0.0.1:8000:8000 \
161165
--env-file=.env.cartobio-api-production \
162166
--name cartobio-api-production \
167+
--init \
168+
--volume /root/pdf:/usr/src/app/pdf \
163169
${{ needs.build.outputs.image }}

image-map/img/background.png

-2.99 MB
Loading

lib/config.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,9 @@ convict.addFormats(formatWithValidator)
6262
* },
6363
* sentry: {
6464
* dsn: string
65+
* };
66+
* attestationsProductions: {
67+
* directory: string
6568
* }
6669
* }>}
6770
*/
@@ -234,5 +237,11 @@ module.exports = convict({
234237
format: 'url',
235238
env: 'SENTRY_DSN'
236239
}
240+
},
241+
attestationsProductions: {
242+
directory: {
243+
default: '.',
244+
env: 'ATTESTATIONS_PRODUCTIONS_DIRECTORY'
245+
}
237246
}
238247
})

lib/enums.js

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,10 +80,20 @@ const RegionBounds = {
8080
[Area.MAYOTTE]: [45.0185, -13.0001, 45.298, -12.6366]
8181
}
8282

83+
/**
84+
* @enum {String}
85+
*/
86+
const AttestationsProductionsStatus = {
87+
STARTED: 'started',
88+
ERROR: 'error',
89+
GENERATED: 'generated'
90+
}
91+
8392
module.exports = {
8493
CertificationState,
8594
EtatProduction,
8695
EventType,
8796
LegalProjections,
88-
RegionBounds
97+
RegionBounds,
98+
AttestationsProductionsStatus
8999
}

0 commit comments

Comments
 (0)