Skip to content

Commit ca7bb22

Browse files
committed
Published source code
0 parents  commit ca7bb22

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+9609
-0
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+
]

.github/workflows/ci.yml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
branches:
9+
- main
10+
11+
jobs:
12+
build:
13+
runs-on: ubuntu-latest
14+
permissions:
15+
contents: read
16+
packages: write
17+
18+
steps:
19+
- name: Checkout code
20+
uses: actions/checkout@v3
21+
with:
22+
fetch-depth: 0
23+
24+
- name: Setup Node.js
25+
uses: actions/setup-node@v3
26+
with:
27+
node-version: "18"
28+
29+
- name: Install dependencies
30+
run: cd ./site/ && npm install
31+
32+
- name: Build site
33+
run: cd ./site/ && npm run build
34+
env:
35+
VITE_SCIM_TEST_SERVER_URL: ${{ secrets.VITE_SCIM_TEST_SERVER_URL }}
36+
VITE_TURNSTILE_SITE_KEY: ${{ secrets.VITE_TURNSTILE_SITE_KEY }}
37+
38+
- name: Install Netlify CLI
39+
run: npm install -g netlify-cli
40+
41+
- name: Deploy to Netlify
42+
run: netlify deploy --prod --dir=./site/.vitepress/dist
43+
env:
44+
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
45+
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
46+
47+
- name: Push to dokku
48+
uses: dokku/github-action@master
49+
with:
50+
git_remote_url: "ssh://[email protected]:22/api"
51+
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}
52+
53+
- name: Build image
54+
run: docker build -f Dockerfile.cli -t ghcr.io/${{ github.repository }}:latest .
55+
56+
- name: Authenticate to GHCR
57+
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $GITHUB_ACTOR --password-stdin
58+
59+
- name: Push image
60+
run: docker push ghcr.io/${{ github.repository }}:latest

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
node_modules
2+
.env
3+
site/.vitepress/cache/
4+
5+
# Local Netlify folder
6+
.netlify

.vscode/launch.json

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
// Use IntelliSense to learn about possible attributes.
3+
// Hover to view descriptions of existing attributes.
4+
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
5+
"version": "0.2.0",
6+
"configurations": [
7+
{
8+
"type": "node",
9+
"request": "launch",
10+
"name": "Launch Program",
11+
"skipFiles": [
12+
"<node_internals>/**"
13+
],
14+
"program": "${workspaceFolder}/index.js",
15+
"console": "integratedTerminal"
16+
}
17+
]
18+
}

Dockerfile

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Use the official Node.js image from the Docker Hub
2+
FROM node:22-alpine
3+
4+
# Create and change to the app directory
5+
WORKDIR /usr/src/app
6+
7+
# Copy package.json and package-lock.json
8+
COPY package*.json ./
9+
10+
# Install app dependencies
11+
RUN npm install
12+
13+
# Copy the rest of the application code
14+
COPY . .
15+
16+
# Expose the port the app runs on
17+
EXPOSE 3000
18+
19+
# Command to run the server
20+
CMD ["node", "server.js"]

Dockerfile.cli

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# docker build -f Dockerfile.cli -t my-cli .
2+
# docker run -e CONFIG_FILE=/app/config.yaml -e AUTH_HEADER="Bearer JdwETA7axAMc6AK35KYRclJDaoDkkRo4BaQtUnZZBvh1BqZ5RPSBZdA18ydD" -e BASE_URL="https://api.scim.dev/scim/v2" -e HAR_FILE_NAME="/output/output.har" -v $(pwd)/site/.vitepress/theme/components/config.yaml:/app/config.yaml -v $(pwd)/output/:/output my-cli
3+
4+
FROM node:21-alpine AS build
5+
6+
WORKDIR /app
7+
8+
# Copy package files
9+
COPY package*.json ./
10+
11+
# Install dependencies
12+
RUN npm ci --only=production
13+
14+
# Create a smaller final image
15+
FROM node:21-alpine
16+
17+
WORKDIR /app
18+
19+
# Copy only the necessary files from the build stage
20+
COPY --from=build /app/node_modules ./node_modules
21+
COPY src/ ./src/
22+
COPY reporters/ ./reporters/
23+
COPY *.js ./
24+
COPY *.json ./
25+
26+
# Set the entrypoint
27+
ENTRYPOINT ["node", "--test"]
28+
CMD ["--test-reporter=spec"]

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.

0 commit comments

Comments
 (0)