1.2.1 • Published 6 years ago
@ouest-france/validator-server v1.2.1
Validator Server
Use it online
Validator server is available at https://validator-server.cleverapps.io/
Validate a BlockProviderConfig from a CI job
Let say we want to validate the configuration (BlockProviderConfig) of our sample BlockProvider currently deployed at https://blockprovider-example.cleverapps.io
We would use:
If it yields HTTP 200
it passes, otherwise it does not and will display why.
Validate a BlockProviderConfig from a CI job
Let say we want to validate our local BlockProvider
(http://localhost:8081/configurations
) in our CI process (using
jq.node)
curl --silent https://validator-server.cleverapps.io/validate\?schema\=https%3A%2F%2Fraw.githubusercontent.com%2FOuest-France%2Fplatform%2Fmaster%2Fpackages%2Fschemas%2FBlockProviderConfig.json\&url\=http://localhost:8081/configurations | jqn -r process 'tap(console.log) | thru(x => process.exit(!!x.errors+0))'
This line will first print the validation output and then yield an exitcode=1 if the validation failed.
Use it locally
npm install
npm start
Use it locally (development)
npm install
npm run start:dev