Skip to content

Commit 884761d

Browse files
Feature/server (#2)
1 parent f3dcdbd commit 884761d

32 files changed

+7351
-527
lines changed

.deployed/versions.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
[
2+
{
3+
"apihost": "https://faas-ams3-2a2df116.doserverless.co",
4+
"namespace": "fn-5369a627-86bd-4113-98cb-5cd714fd1256",
5+
"packageVersions": {},
6+
"actionVersions": {
7+
"scim/verify": {
8+
"digest": "302cb01bd761564fee108a3242c6e7037c2c45eb91191f9e99b804200e4141ed",
9+
"version": "0.0.4"
10+
}
11+
}
12+
}
13+
]

Dockerfile

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,8 @@ RUN npm install
1313
# Copy the rest of the application code
1414
COPY . .
1515

16-
# Run the tests
17-
CMD ["node", "--test", "--test-reporter", "spec"]
16+
# Expose the port the app runs on
17+
EXPOSE 3000
18+
19+
# Command to run the server
20+
CMD ["node", "server.js"]

FAQ.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
2+
# Why don't you come up with user creations/updates
3+
4+
Because SCIM doesn't specify - or in a very limited form - the field value formatting.

README.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,8 @@ For organizations requiring additional assistance, commercial support options ar
2222

2323
## Contact
2424

25-
For more information, please visit [verify.scim.dev](https://verify.scim.dev/) or contact us at [email protected].
25+
For more information, please visit [verify.scim.dev](https://verify.scim.dev/) or contact us at [email protected].
26+
27+
## TODO:
28+
29+
1. Generate example requests and response schemas based on Schema and Resource Types. Leverage AI??

docker-compose.yml

Lines changed: 33 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,40 @@
11
version: '3.8'
22

33
services:
4-
app:
4+
# Node server for running SCIM verification tests
5+
scimserver:
56
build:
67
context: .
78
dockerfile: Dockerfile
9+
ports:
10+
- "3000:3000"
811
volumes:
9-
- .:/app
12+
- ./:/usr/src/app
13+
command: ["npx", "nodemon", "server.js"]
14+
environment:
15+
- NODE_ENV=development
16+
- PORT=3000
17+
networks:
18+
- scim-network
19+
restart: unless-stopped
20+
21+
# VitePress documentation site
22+
vitepress:
23+
build:
24+
context: ./site
25+
dockerfile: Dockerfile
26+
ports:
27+
- "5173:5173"
28+
volumes:
29+
- .:/usr/src/app
30+
working_dir: /usr/src/app/site/docs
31+
command: sh -c "npm install && npm run dev -- --host 0.0.0.0"
32+
environment:
33+
- NODE_ENV=development
34+
networks:
35+
- scim-network
36+
restart: unless-stopped
37+
38+
networks:
39+
scim-network:
40+
driver: bridge

index.js

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,17 @@
1-
const { spec } = require('node:test/reporters');
2-
const { run } = require('node:test');
3-
const path = require('node:path');
4-
const { tap } = require('node:test/reporters');
1+
import { run } from 'node:test';
2+
import path from 'path';
3+
import { fileURLToPath } from 'url';
54

5+
6+
const __filename = fileURLToPath(import.meta.url);
7+
const __dirname = path.dirname(__filename);
8+
9+
// Run tests sequentially and pipe directly to NDJSON reporter and stdout
610
run({
7-
files: [path.resolve(__dirname, 'scim.test.js')]
11+
files: [path.resolve(__dirname, 'scim.test.js')],
12+
concurrency: 1,
13+
reporter: 'spec'
814
}).on('test:fail', () => {
915
process.exitCode = 1;
10-
}).compose(spec).pipe(process.stdout);
16+
})
17+
.pipe(process.stdout);

0 commit comments

Comments
 (0)