diff --git a/Docker-compose/djangosaml2_sp/.gitignore b/Docker-compose/djangosaml2_sp/.gitignore new file mode 100644 index 00000000..f935021a --- /dev/null +++ b/Docker-compose/djangosaml2_sp/.gitignore @@ -0,0 +1 @@ +!.gitignore diff --git a/Docker-compose/docker-compose.yml b/Docker-compose/docker-compose.yml index 1d07a0dc..258e1dae 100644 --- a/Docker-compose/docker-compose.yml +++ b/Docker-compose/docker-compose.yml @@ -9,8 +9,7 @@ services: MONGO_INITDB_ROOT_USERNAME: "${MONGO_DBUSER:-satosa}" MONGO_INITDB_ROOT_PASSWORD: "${MONGO_DBPASSWORD:-thatpassword}" volumes: - - mongodata:/data/db - - /usr/share/zoneinfo/Europe/Rome:/etc/localtime:ro + - ./mongo/db:/data/db - ./mongo/init-mongo.sh:/docker-entrypoint-initdb.d/init-mongo.sh ports: - '27017-27019:27017-27019' @@ -34,17 +33,16 @@ services: ## START: PARTE NUOVA django_sp: build: - context: ../ + context: ../ args: - - NODE_ENV=local + - NODE_ENV=local dockerfile: example_sp/django.Dockerfile container_name: django_sp #restart: always working_dir: /django_sp entrypoint: "sh ../entrypoint.sh" volumes: - - /usr/share/zoneinfo/Europe/Rome:/etc/localtime:ro - - ../example_sp/djangosaml2_sp:/django_sp:rw + - ./djangosaml2_sp:/django_sp:rw ports: - "8000:8000" networks: @@ -110,8 +108,7 @@ services: ports: - "10000:10000" volumes: - - /usr/share/zoneinfo/Europe/Rome:/etc/localtime:ro - - ../docker-example:/satosa_proxy:rw + - ./satosa:/satosa_proxy:rw working_dir: /satosa_proxy entrypoint: "sh entrypoint.sh" networks: @@ -136,7 +133,7 @@ services: - ./nginx/50x.html:/usr/share/nginx/html/50x.html:ro - ./nginx/404.html:/usr/share/nginx/html/404.html:ro - ./nginx/403.html:/usr/share/nginx/html/403.html:ro - - nginx_certs:/etc/nginx/certs:ro + - ./nginx/certs:/etc/nginx/certs:ro - ../docker-example/static:/var/www/html networks: - satosa-saml2spid @@ -150,17 +147,6 @@ services: - "8443:8443" networks: - satosa-saml2spid - -volumes: - - mongodata: - name: satosa-saml2spid_mongodata - external: true - - nginx_certs: - name: satosa-saml2spid_nginx_certs - external: true - networks: satosa-saml2spid: name: satosa-saml2spid diff --git a/Docker-compose/mongo/db/.gitignore b/Docker-compose/mongo/db/.gitignore new file mode 100644 index 00000000..f935021a --- /dev/null +++ b/Docker-compose/mongo/db/.gitignore @@ -0,0 +1 @@ +!.gitignore diff --git a/Docker-compose/mongo/db/.gitkeep b/Docker-compose/mongo/db/.gitkeep new file mode 100644 index 00000000..e69de29b diff --git a/Docker-compose/mongo/db/.mongodb/mongosh/66c864868081b0c453a26a12_log b/Docker-compose/mongo/db/.mongodb/mongosh/66c864868081b0c453a26a12_log new file mode 100644 index 00000000..e4434e1a --- /dev/null +++ b/Docker-compose/mongo/db/.mongodb/mongosh/66c864868081b0c453a26a12_log @@ -0,0 +1,5 @@ +{"t":{"$date":"2024-08-23T10:29:26.794Z"},"s":"I","c":"MONGOSH","id":1000000000,"ctx":"log","msg":"Starting log","attr":{"execPath":"/usr/bin/mongosh","envInfo":{"EDITOR":null,"NODE_OPTIONS":null,"TERM":null},"version":"2.2.6","distributionKind":"compiled","buildArch":"x64","buildPlatform":"linux","buildTarget":"linux-x64","buildTime":"2024-05-16T17:58:55.042Z","gitVersion":"6d11de2ccf5cdb827d7c170d0e7d1778aa98a0bc","nodeVersion":"v20.12.2","opensslVersion":"3.0.13+quic","sharedOpenssl":false,"runtimeArch":"x64","runtimePlatform":"linux","runtimeGlibcVersion":"2.35","deps":{"nodeDriverVersion":"6.6.2","libmongocryptVersion":"1.9.0-20230828+git8e7f69f1c0","libmongocryptNodeBindingsVersion":"6.0.0","kerberosVersion":"2.1.0"}}} +{"t":{"$date":"2024-08-23T10:29:26.810Z"},"s":"I","c":"MONGOSH","id":1000000048,"ctx":"config","msg":"Loading global configuration file","attr":{"filename":"/etc/mongosh.conf","found":false}} +{"t":{"$date":"2024-08-23T10:29:26.835Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000042,"ctx":"mongosh-connect","msg":"Initiating connection attempt","attr":{"uri":"mongodb://127.0.0.1:27017/admin?directConnection=true&serverSelectionTimeoutMS=2000&appName=mongosh+2.2.6","driver":{"name":"nodejs|mongosh","version":"6.6.2|2.2.6"},"devtoolsConnectVersion":"2.6.3","host":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T10:29:26.840Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000035,"ctx":"mongosh-connect","msg":"Server heartbeat succeeded","attr":{"connectionId":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T10:29:26.906Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000037,"ctx":"mongosh-connect","msg":"Connection attempt finished"} diff --git a/Docker-compose/mongo/db/.mongodb/mongosh/66c8648753e2f14983a26a12_log b/Docker-compose/mongo/db/.mongodb/mongosh/66c8648753e2f14983a26a12_log new file mode 100644 index 00000000..36142eee --- /dev/null +++ b/Docker-compose/mongo/db/.mongodb/mongosh/66c8648753e2f14983a26a12_log @@ -0,0 +1,53 @@ +{"t":{"$date":"2024-08-23T10:29:27.433Z"},"s":"I","c":"MONGOSH","id":1000000000,"ctx":"log","msg":"Starting log","attr":{"execPath":"/usr/bin/mongosh","envInfo":{"EDITOR":null,"NODE_OPTIONS":null,"TERM":null},"version":"2.2.6","distributionKind":"compiled","buildArch":"x64","buildPlatform":"linux","buildTarget":"linux-x64","buildTime":"2024-05-16T17:58:55.042Z","gitVersion":"6d11de2ccf5cdb827d7c170d0e7d1778aa98a0bc","nodeVersion":"v20.12.2","opensslVersion":"3.0.13+quic","sharedOpenssl":false,"runtimeArch":"x64","runtimePlatform":"linux","runtimeGlibcVersion":"2.35","deps":{"nodeDriverVersion":"6.6.2","libmongocryptVersion":"1.9.0-20230828+git8e7f69f1c0","libmongocryptNodeBindingsVersion":"6.0.0","kerberosVersion":"2.1.0"}}} +{"t":{"$date":"2024-08-23T10:29:27.439Z"},"s":"I","c":"MONGOSH","id":1000000005,"ctx":"config","msg":"User updated"} +{"t":{"$date":"2024-08-23T10:29:27.439Z"},"s":"I","c":"MONGOSH","id":1000000048,"ctx":"config","msg":"Loading global configuration file","attr":{"filename":"/etc/mongosh.conf","found":false}} +{"t":{"$date":"2024-08-23T10:29:27.465Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000042,"ctx":"mongosh-connect","msg":"Initiating connection attempt","attr":{"uri":"mongodb://127.0.0.1:27017/oidcop?directConnection=true&serverSelectionTimeoutMS=2000&appName=mongosh+2.2.6","driver":{"name":"nodejs|mongosh","version":"6.6.2|2.2.6"},"devtoolsConnectVersion":"2.6.3","host":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T10:29:27.471Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000035,"ctx":"mongosh-connect","msg":"Server heartbeat succeeded","attr":{"connectionId":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T10:29:27.479Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000037,"ctx":"mongosh-connect","msg":"Connection attempt finished"} +{"t":{"$date":"2024-08-23T10:29:27.490Z"},"s":"I","c":"MONGOSH","id":1000000004,"ctx":"connect","msg":"Connecting to server","attr":{"session_id":"66c8648753e2f14983a26a12","userId":null,"telemetryAnonymousId":"66c864868081b0c453a26a11","connectionUri":"mongodb://:27017/oidcop?directConnection=true&serverSelectionTimeoutMS=2000&appName=mongosh+2.2.6","is_atlas":false,"is_localhost":true,"is_do":false,"server_version":"7.0.11","node_version":"v20.12.2","mongosh_version":"2.2.6","server_os":"linux","server_arch":"x86_64","is_enterprise":false,"auth_type":null,"is_data_federation":false,"is_stream":false,"dl_version":null,"atlas_version":null,"is_genuine":true,"non_genuine_server_name":"mongodb","is_local_atlas":false,"fcv":"7.0","api_version":null,"api_strict":null,"api_deprecation_errors":null}} +{"t":{"$date":"2024-08-23T10:29:27.492Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"adminCommand","class":"Database","db":"oidcop","arguments":{"cmd":{"ping":1}}}} +{"t":{"$date":"2024-08-23T10:29:27.493Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"getSiblingDB","class":"Database","db":"oidcop","arguments":{"db":"admin"}}} +{"t":{"$date":"2024-08-23T10:29:27.520Z"},"s":"I","c":"MONGOSH","id":1000000010,"ctx":"shell-api","msg":"Initialized context","attr":{"method":"setCtx","arguments":{}}} +{"t":{"$date":"2024-08-23T10:29:27.522Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"adminCommand","class":"Database","db":"oidcop","arguments":{"cmd":{"getLog":"startupWarnings"}}}} +{"t":{"$date":"2024-08-23T10:29:27.523Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"getSiblingDB","class":"Database","db":"oidcop","arguments":{"db":"admin"}}} +{"t":{"$date":"2024-08-23T10:29:27.523Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"hello","class":"Database","db":"oidcop","arguments":{}}} +{"t":{"$date":"2024-08-23T10:29:27.525Z"},"s":"I","c":"MONGOSH-SNIPPETS","id":1000000024,"ctx":"snippets","msg":"Fetching snippet index","attr":{"refreshMode":"allow-cached"}} +{"t":{"$date":"2024-08-23T10:29:27.525Z"},"s":"I","c":"MONGOSH-SNIPPETS","id":1000000019,"ctx":"snippets","msg":"Loaded snippets","attr":{"installdir":"/data/db/.mongodb/mongosh/snippets"}} +{"t":{"$date":"2024-08-23T10:29:27.563Z"},"s":"I","c":"MONGOSH","id":1000000002,"ctx":"repl","msg":"Started REPL","attr":{"version":"2.2.6"}} +{"t":{"$date":"2024-08-23T10:29:27.583Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T10:29:27.708Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"var rootUser = 'satosa';"}} +{"t":{"$date":"2024-08-23T10:29:27.710Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"var rootPassword = 'thatpassword';"}} +{"t":{"$date":"2024-08-23T10:29:27.710Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T10:29:27.712Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"var admin = db.getSiblingDB('admin');"}} +{"t":{"$date":"2024-08-23T10:29:27.712Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"getSiblingDB","class":"Database","db":"oidcop","arguments":{"db":"admin"}}} +{"t":{"$date":"2024-08-23T10:29:27.713Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T10:29:27.713Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"auth","class":"Database","db":"admin","arguments":{}}} +{"t":{"$date":"2024-08-23T10:29:27.713Z"},"s":"I","c":"MONGOSH-SP","id":1000000040,"ctx":"connect","msg":"Reconnect because of changed connection options"} +{"t":{"$date":"2024-08-23T10:29:27.713Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000042,"ctx":"mongosh-connect","msg":"Initiating connection attempt","attr":{"uri":"mongodb://127.0.0.1:27017/oidcop?directConnection=true&serverSelectionTimeoutMS=2000&appName=mongosh+2.2.6","driver":{"name":"nodejs|mongosh","version":"6.6.2|2.2.6"},"devtoolsConnectVersion":"2.6.3","host":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T10:29:27.713Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000035,"ctx":"mongosh-connect","msg":"Server heartbeat succeeded","attr":{"connectionId":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T10:29:27.737Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000037,"ctx":"mongosh-connect","msg":"Connection attempt finished"} +{"t":{"$date":"2024-08-23T10:29:27.814Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T10:29:27.815Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"var user = 'satosa';"}} +{"t":{"$date":"2024-08-23T10:29:27.815Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"var passwd = 'thatpassword';"}} +{"t":{"$date":"2024-08-23T10:29:27.815Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T10:29:27.815Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"createUser","class":"Database","db":"oidcop","arguments":{}}} +{"t":{"$date":"2024-08-23T10:29:27.840Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T10:29:27.854Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"// make client_id unique"}} +{"t":{"$date":"2024-08-23T10:29:27.855Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"db.client.createIndex( { \"client_id\": 1 }, { unique: true } )"}} +{"t":{"$date":"2024-08-23T10:29:27.855Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"createIndex","class":"Collection","db":"oidcop","coll":"client","arguments":{"keys":{"client_id":1},"options":{"unique":true}}}} +{"t":{"$date":"2024-08-23T10:29:27.884Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"db.client.createIndex( { \"registration_access_token\": 1 }, { unique: true } )"}} +{"t":{"$date":"2024-08-23T10:29:27.885Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"createIndex","class":"Collection","db":"oidcop","coll":"client","arguments":{"keys":{"registration_access_token":1},"options":{"unique":true}}}} +{"t":{"$date":"2024-08-23T10:29:27.902Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T10:29:27.916Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"// make access_token and sid unique"}} +{"t":{"$date":"2024-08-23T10:29:27.917Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"db.session.createIndex( { \"sid\": 1 }, { unique: true } )"}} +{"t":{"$date":"2024-08-23T10:29:27.917Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"createIndex","class":"Collection","db":"oidcop","coll":"session","arguments":{"keys":{"sid":1},"options":{"unique":true}}}} +{"t":{"$date":"2024-08-23T10:29:27.948Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T10:29:27.967Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"// create expired session deletion"}} +{"t":{"$date":"2024-08-23T10:29:27.968Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"db.session.createIndex(\n { expires_at: 1 },\n { expireAfterSeconds: 0, partialFilterExpression: { count: { $gt: 2 } } }\n);"}} +{"t":{"$date":"2024-08-23T10:29:27.968Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"createIndex","class":"Collection","db":"oidcop","coll":"session","arguments":{"keys":{"expires_at":1},"options":{"expireAfterSeconds":0,"partialFilterExpression":{"count":{"$gt":2}}}}}} +{"t":{"$date":"2024-08-23T10:29:27.982Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T10:29:27.999Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"// insert a test client like this"}} +{"t":{"$date":"2024-08-23T10:29:28Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"db.client.insertOne(\n {\"client_id\": \"jbxedfmfyc\", \"client_name\": \"ciro\", \"client_salt\": \"6flfsj0Z\", \"registration_access_token\": \"z3PCMmC1HZ1QmXeXGOQMJpWQNQynM4xY\", \"registration_client_uri\": \"\", \"client_id_issued_at\": 1630952311.410208, \"client_secret\": \"19cc69b70d0108f630e52f72f7a3bd37ba4e11678ad1a7434e9818e1\", \"client_secret_expires_at\": 1662488311.410214, \"application_type\": \"web\", \"contacts\": [\"\"], \"token_endpoint_auth_method\": \"client_secret_basic\", \"redirect_uris\": [[\"\", {}]], \"post_logout_redirect_uris\": [[\"\", null]], \"response_types\": [\"code\"], \"grant_types\": [\"authorization_code\"], \"allowed_scopes\": [\"openid\", \"profile\", \"email\", \"offline_access\"]}\n)"}} +{"t":{"$date":"2024-08-23T10:29:28Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"insertOne","class":"Collection","db":"oidcop","coll":"client","arguments":{"options":{}}}} +{"t":{"$date":"2024-08-23T10:29:28.007Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T10:29:28.010Z"},"s":"I","c":"MONGOSH","id":1000000045,"ctx":"analytics","msg":"Flushed outstanding data","attr":{"flushError":"Trying to persist throttle state before userId is set","flushDuration":0}} diff --git a/Docker-compose/mongo/db/.mongodb/mongosh/66c864877182c3e993a26a12_log b/Docker-compose/mongo/db/.mongodb/mongosh/66c864877182c3e993a26a12_log new file mode 100644 index 00000000..df647d07 --- /dev/null +++ b/Docker-compose/mongo/db/.mongodb/mongosh/66c864877182c3e993a26a12_log @@ -0,0 +1,14 @@ +{"t":{"$date":"2024-08-23T10:29:27.060Z"},"s":"I","c":"MONGOSH","id":1000000000,"ctx":"log","msg":"Starting log","attr":{"execPath":"/usr/bin/mongosh","envInfo":{"EDITOR":null,"NODE_OPTIONS":null,"TERM":null},"version":"2.2.6","distributionKind":"compiled","buildArch":"x64","buildPlatform":"linux","buildTarget":"linux-x64","buildTime":"2024-05-16T17:58:55.042Z","gitVersion":"6d11de2ccf5cdb827d7c170d0e7d1778aa98a0bc","nodeVersion":"v20.12.2","opensslVersion":"3.0.13+quic","sharedOpenssl":false,"runtimeArch":"x64","runtimePlatform":"linux","runtimeGlibcVersion":"2.35","deps":{"nodeDriverVersion":"6.6.2","libmongocryptVersion":"1.9.0-20230828+git8e7f69f1c0","libmongocryptNodeBindingsVersion":"6.0.0","kerberosVersion":"2.1.0"}}} +{"t":{"$date":"2024-08-23T10:29:27.066Z"},"s":"I","c":"MONGOSH","id":1000000005,"ctx":"config","msg":"User updated"} +{"t":{"$date":"2024-08-23T10:29:27.066Z"},"s":"I","c":"MONGOSH","id":1000000048,"ctx":"config","msg":"Loading global configuration file","attr":{"filename":"/etc/mongosh.conf","found":false}} +{"t":{"$date":"2024-08-23T10:29:27.088Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000042,"ctx":"mongosh-connect","msg":"Initiating connection attempt","attr":{"uri":"mongodb://127.0.0.1:27017/admin?directConnection=true&serverSelectionTimeoutMS=2000&appName=mongosh+2.2.6","driver":{"name":"nodejs|mongosh","version":"6.6.2|2.2.6"},"devtoolsConnectVersion":"2.6.3","host":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T10:29:27.094Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000035,"ctx":"mongosh-connect","msg":"Server heartbeat succeeded","attr":{"connectionId":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T10:29:27.126Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000037,"ctx":"mongosh-connect","msg":"Connection attempt finished"} +{"t":{"$date":"2024-08-23T10:29:27.136Z"},"s":"I","c":"MONGOSH","id":1000000010,"ctx":"shell-api","msg":"Initialized context","attr":{"method":"setCtx","arguments":{}}} +{"t":{"$date":"2024-08-23T10:29:27.142Z"},"s":"I","c":"MONGOSH-SNIPPETS","id":1000000024,"ctx":"snippets","msg":"Fetching snippet index","attr":{"refreshMode":"allow-cached"}} +{"t":{"$date":"2024-08-23T10:29:27.143Z"},"s":"I","c":"MONGOSH-SNIPPETS","id":1000000019,"ctx":"snippets","msg":"Loaded snippets","attr":{"installdir":"/data/db/.mongodb/mongosh/snippets"}} +{"t":{"$date":"2024-08-23T10:29:27.178Z"},"s":"I","c":"MONGOSH","id":1000000004,"ctx":"connect","msg":"Connecting to server","attr":{"session_id":"66c864877182c3e993a26a12","userId":null,"telemetryAnonymousId":"66c864868081b0c453a26a11","connectionUri":"mongodb://:27017/admin?directConnection=true&serverSelectionTimeoutMS=2000&appName=mongosh+2.2.6","is_atlas":false,"is_localhost":true,"is_do":false,"server_version":"7.0.11","node_version":"v20.12.2","mongosh_version":"2.2.6","server_os":"linux","server_arch":"x86_64","is_enterprise":false,"auth_type":null,"is_data_federation":false,"is_stream":false,"dl_version":null,"atlas_version":null,"is_genuine":true,"non_genuine_server_name":"mongodb","is_local_atlas":false,"fcv":"7.0","api_version":null,"api_strict":null,"api_deprecation_errors":null}} +{"t":{"$date":"2024-08-23T10:29:27.179Z"},"s":"I","c":"MONGOSH-SNIPPETS","id":1000000028,"ctx":"snippets","msg":"Modifying snippets package.json failed","attr":{"error":"ENOENT: no such file or directory, open '/data/db/.mongodb/mongosh/snippets/package.json'"}} +{"t":{"$date":"2024-08-23T10:29:27.179Z"},"s":"I","c":"MONGOSH","id":1000000002,"ctx":"repl","msg":"Started REPL","attr":{"version":"2.2.6"}} +{"t":{"$date":"2024-08-23T10:29:27.273Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"createUser","class":"Database","db":"admin","arguments":{}}} +{"t":{"$date":"2024-08-23T10:29:27.324Z"},"s":"I","c":"MONGOSH","id":1000000045,"ctx":"analytics","msg":"Flushed outstanding data","attr":{"flushError":"Trying to persist throttle state before userId is set","flushDuration":1}} diff --git a/Docker-compose/mongo/db/.mongodb/mongosh/66c877678dabe957415e739b_log b/Docker-compose/mongo/db/.mongodb/mongosh/66c877678dabe957415e739b_log new file mode 100644 index 00000000..c19d295f --- /dev/null +++ b/Docker-compose/mongo/db/.mongodb/mongosh/66c877678dabe957415e739b_log @@ -0,0 +1,7 @@ +{"t":{"$date":"2024-08-23T11:49:59.725Z"},"s":"I","c":"MONGOSH","id":1000000000,"ctx":"log","msg":"Starting log","attr":{"execPath":"/usr/bin/mongosh","envInfo":{"EDITOR":null,"NODE_OPTIONS":null,"TERM":null},"version":"2.3.0","distributionKind":"compiled","buildArch":"x64","buildPlatform":"linux","buildTarget":"linux-x64","buildTime":"2024-08-15T21:23:23.577Z","gitVersion":"2013159f06f902b4e9a2060df411c6b5646d49d4","nodeVersion":"v20.16.0","opensslVersion":"3.0.13+quic","sharedOpenssl":false,"runtimeArch":"x64","runtimePlatform":"linux","runtimeGlibcVersion":"2.35","deps":{"nodeDriverVersion":"6.8.0","libmongocryptVersion":"1.11.0","libmongocryptNodeBindingsVersion":"6.1.0","kerberosVersion":"2.1.0"}}} +{"t":{"$date":"2024-08-23T11:49:59.742Z"},"s":"I","c":"MONGOSH","id":1000000005,"ctx":"config","msg":"User updated"} +{"t":{"$date":"2024-08-23T11:49:59.742Z"},"s":"I","c":"MONGOSH","id":1000000048,"ctx":"config","msg":"Loading global configuration file","attr":{"filename":"/etc/mongosh.conf","found":false}} +{"t":{"$date":"2024-08-23T11:49:59.787Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000049,"ctx":"mongosh-connect","msg":"Loaded system CA list","attr":{"caCount":284,"asyncFallbackError":null,"systemCertsError":null}} +{"t":{"$date":"2024-08-23T11:49:59.800Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000042,"ctx":"mongosh-connect","msg":"Initiating connection attempt","attr":{"uri":"mongodb://127.0.0.1:27017/admin?directConnection=true&serverSelectionTimeoutMS=2000&appName=mongosh+2.3.0","driver":{"name":"nodejs|mongosh","version":"6.8.0|2.3.0"},"devtoolsConnectVersion":"3.2.5","host":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T11:49:59.804Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000035,"ctx":"mongosh-connect","msg":"Server heartbeat succeeded","attr":{"connectionId":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T11:49:59.856Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000037,"ctx":"mongosh-connect","msg":"Connection attempt finished"} diff --git a/Docker-compose/mongo/db/.mongodb/mongosh/66c8776831e5574dd75e739b_log b/Docker-compose/mongo/db/.mongodb/mongosh/66c8776831e5574dd75e739b_log new file mode 100644 index 00000000..8cd6d58f --- /dev/null +++ b/Docker-compose/mongo/db/.mongodb/mongosh/66c8776831e5574dd75e739b_log @@ -0,0 +1,55 @@ +{"t":{"$date":"2024-08-23T11:50:00.478Z"},"s":"I","c":"MONGOSH","id":1000000000,"ctx":"log","msg":"Starting log","attr":{"execPath":"/usr/bin/mongosh","envInfo":{"EDITOR":null,"NODE_OPTIONS":null,"TERM":null},"version":"2.3.0","distributionKind":"compiled","buildArch":"x64","buildPlatform":"linux","buildTarget":"linux-x64","buildTime":"2024-08-15T21:23:23.577Z","gitVersion":"2013159f06f902b4e9a2060df411c6b5646d49d4","nodeVersion":"v20.16.0","opensslVersion":"3.0.13+quic","sharedOpenssl":false,"runtimeArch":"x64","runtimePlatform":"linux","runtimeGlibcVersion":"2.35","deps":{"nodeDriverVersion":"6.8.0","libmongocryptVersion":"1.11.0","libmongocryptNodeBindingsVersion":"6.1.0","kerberosVersion":"2.1.0"}}} +{"t":{"$date":"2024-08-23T11:50:00.485Z"},"s":"I","c":"MONGOSH","id":1000000005,"ctx":"config","msg":"User updated"} +{"t":{"$date":"2024-08-23T11:50:00.485Z"},"s":"I","c":"MONGOSH","id":1000000048,"ctx":"config","msg":"Loading global configuration file","attr":{"filename":"/etc/mongosh.conf","found":false}} +{"t":{"$date":"2024-08-23T11:50:00.521Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000049,"ctx":"mongosh-connect","msg":"Loaded system CA list","attr":{"caCount":284,"asyncFallbackError":null,"systemCertsError":null}} +{"t":{"$date":"2024-08-23T11:50:00.532Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000042,"ctx":"mongosh-connect","msg":"Initiating connection attempt","attr":{"uri":"mongodb://127.0.0.1:27017/oidcop?directConnection=true&serverSelectionTimeoutMS=2000&appName=mongosh+2.3.0","driver":{"name":"nodejs|mongosh","version":"6.8.0|2.3.0"},"devtoolsConnectVersion":"3.2.5","host":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T11:50:00.536Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000035,"ctx":"mongosh-connect","msg":"Server heartbeat succeeded","attr":{"connectionId":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T11:50:00.543Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000037,"ctx":"mongosh-connect","msg":"Connection attempt finished"} +{"t":{"$date":"2024-08-23T11:50:00.551Z"},"s":"I","c":"MONGOSH","id":1000000004,"ctx":"connect","msg":"Connecting to server","attr":{"userId":null,"telemetryAnonymousId":"66c864868081b0c453a26a11","connectionUri":"mongodb://:27017/oidcop?directConnection=true&serverSelectionTimeoutMS=2000&appName=mongosh+2.3.0","mongosh_version":"2.3.0","session_id":"66c8776831e5574dd75e739b","is_localhost":true,"is_do_url":false,"is_atlas_url":false,"is_atlas":false,"server_version":"7.0.12","node_version":"v20.16.0","server_os":"linux","server_arch":"x86_64","is_enterprise":false,"auth_type":null,"is_data_federation":false,"is_stream":false,"dl_version":null,"atlas_version":null,"is_genuine":true,"non_genuine_server_name":"mongodb","is_local_atlas":false,"fcv":"7.0","api_version":null,"api_strict":null,"api_deprecation_errors":null,"atlas_hostname":null}} +{"t":{"$date":"2024-08-23T11:50:00.553Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"adminCommand","class":"Database","db":"oidcop","arguments":{"cmd":{"ping":1}}}} +{"t":{"$date":"2024-08-23T11:50:00.573Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"getSiblingDB","class":"Database","db":"oidcop","arguments":{"db":"admin"}}} +{"t":{"$date":"2024-08-23T11:50:00.575Z"},"s":"I","c":"MONGOSH","id":1000000010,"ctx":"shell-api","msg":"Initialized context","attr":{"method":"setCtx","arguments":{}}} +{"t":{"$date":"2024-08-23T11:50:00.576Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"adminCommand","class":"Database","db":"oidcop","arguments":{"cmd":{"getLog":"startupWarnings"}}}} +{"t":{"$date":"2024-08-23T11:50:00.577Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"getSiblingDB","class":"Database","db":"oidcop","arguments":{"db":"admin"}}} +{"t":{"$date":"2024-08-23T11:50:00.578Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"hello","class":"Database","db":"oidcop","arguments":{}}} +{"t":{"$date":"2024-08-23T11:50:00.578Z"},"s":"I","c":"MONGOSH-SNIPPETS","id":1000000024,"ctx":"snippets","msg":"Fetching snippet index","attr":{"refreshMode":"allow-cached"}} +{"t":{"$date":"2024-08-23T11:50:00.579Z"},"s":"I","c":"MONGOSH-SNIPPETS","id":1000000019,"ctx":"snippets","msg":"Loaded snippets","attr":{"installdir":"/data/db/.mongodb/mongosh/snippets"}} +{"t":{"$date":"2024-08-23T11:50:00.639Z"},"s":"I","c":"MONGOSH","id":1000000002,"ctx":"repl","msg":"Started REPL","attr":{"version":"2.3.0"}} +{"t":{"$date":"2024-08-23T11:50:00.654Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T11:50:00.769Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"var rootUser = 'satosa';"}} +{"t":{"$date":"2024-08-23T11:50:00.770Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"var rootPassword = 'thatpassword';"}} +{"t":{"$date":"2024-08-23T11:50:00.770Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T11:50:00.770Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"var admin = db.getSiblingDB('admin');"}} +{"t":{"$date":"2024-08-23T11:50:00.770Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"getSiblingDB","class":"Database","db":"oidcop","arguments":{"db":"admin"}}} +{"t":{"$date":"2024-08-23T11:50:00.770Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T11:50:00.771Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"auth","class":"Database","db":"admin","arguments":{}}} +{"t":{"$date":"2024-08-23T11:50:00.772Z"},"s":"I","c":"MONGOSH-SP","id":1000000040,"ctx":"connect","msg":"Reconnect because of changed connection options"} +{"t":{"$date":"2024-08-23T11:50:00.772Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000049,"ctx":"mongosh-connect","msg":"Loaded system CA list","attr":{"caCount":284,"asyncFallbackError":null,"systemCertsError":null}} +{"t":{"$date":"2024-08-23T11:50:00.772Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000042,"ctx":"mongosh-connect","msg":"Initiating connection attempt","attr":{"uri":"mongodb://127.0.0.1:27017/oidcop?directConnection=true&serverSelectionTimeoutMS=2000&appName=mongosh+2.3.0","driver":{"name":"nodejs|mongosh","version":"6.8.0|2.3.0"},"devtoolsConnectVersion":"3.2.5","host":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T11:50:00.772Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000035,"ctx":"mongosh-connect","msg":"Server heartbeat succeeded","attr":{"connectionId":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T11:50:00.798Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000037,"ctx":"mongosh-connect","msg":"Connection attempt finished"} +{"t":{"$date":"2024-08-23T11:50:00.855Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T11:50:00.856Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"var user = 'satosa';"}} +{"t":{"$date":"2024-08-23T11:50:00.856Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"var passwd = 'thatpassword';"}} +{"t":{"$date":"2024-08-23T11:50:00.856Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T11:50:00.856Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"createUser","class":"Database","db":"oidcop","arguments":{}}} +{"t":{"$date":"2024-08-23T11:50:00.879Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T11:50:00.891Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"// make client_id unique"}} +{"t":{"$date":"2024-08-23T11:50:00.895Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"db.client.createIndex( { \"client_id\": 1 }, { unique: true } )"}} +{"t":{"$date":"2024-08-23T11:50:00.895Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"createIndex","class":"Collection","db":"oidcop","coll":"client","arguments":{"keys":{"client_id":1},"options":{"unique":true}}}} +{"t":{"$date":"2024-08-23T11:50:00.929Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"db.client.createIndex( { \"registration_access_token\": 1 }, { unique: true } )"}} +{"t":{"$date":"2024-08-23T11:50:00.931Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"createIndex","class":"Collection","db":"oidcop","coll":"client","arguments":{"keys":{"registration_access_token":1},"options":{"unique":true}}}} +{"t":{"$date":"2024-08-23T11:50:00.946Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T11:50:00.964Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"// make access_token and sid unique"}} +{"t":{"$date":"2024-08-23T11:50:00.965Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"db.session.createIndex( { \"sid\": 1 }, { unique: true } )"}} +{"t":{"$date":"2024-08-23T11:50:00.965Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"createIndex","class":"Collection","db":"oidcop","coll":"session","arguments":{"keys":{"sid":1},"options":{"unique":true}}}} +{"t":{"$date":"2024-08-23T11:50:00.992Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T11:50:01.007Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"// create expired session deletion"}} +{"t":{"$date":"2024-08-23T11:50:01.008Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"db.session.createIndex(\n { expires_at: 1 },\n { expireAfterSeconds: 0, partialFilterExpression: { count: { $gt: 2 } } }\n);"}} +{"t":{"$date":"2024-08-23T11:50:01.008Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"createIndex","class":"Collection","db":"oidcop","coll":"session","arguments":{"keys":{"expires_at":1},"options":{"expireAfterSeconds":0,"partialFilterExpression":{"count":{"$gt":2}}}}}} +{"t":{"$date":"2024-08-23T11:50:01.021Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T11:50:01.037Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"// insert a test client like this"}} +{"t":{"$date":"2024-08-23T11:50:01.038Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":"db.client.insertOne(\n {\"client_id\": \"jbxedfmfyc\", \"client_name\": \"ciro\", \"client_salt\": \"6flfsj0Z\", \"registration_access_token\": \"z3PCMmC1HZ1QmXeXGOQMJpWQNQynM4xY\", \"registration_client_uri\": \"\", \"client_id_issued_at\": 1630952311.410208, \"client_secret\": \"19cc69b70d0108f630e52f72f7a3bd37ba4e11678ad1a7434e9818e1\", \"client_secret_expires_at\": 1662488311.410214, \"application_type\": \"web\", \"contacts\": [\"\"], \"token_endpoint_auth_method\": \"client_secret_basic\", \"redirect_uris\": [[\"\", {}]], \"post_logout_redirect_uris\": [[\"\", null]], \"response_types\": [\"code\"], \"grant_types\": [\"authorization_code\"], \"allowed_scopes\": [\"openid\", \"profile\", \"email\", \"offline_access\"]}\n)"}} +{"t":{"$date":"2024-08-23T11:50:01.038Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"insertOne","class":"Collection","db":"oidcop","coll":"client","arguments":{"options":{}}}} +{"t":{"$date":"2024-08-23T11:50:01.045Z"},"s":"I","c":"MONGOSH","id":1000000007,"ctx":"repl","msg":"Evaluating input","attr":{"input":""}} +{"t":{"$date":"2024-08-23T11:50:01.049Z"},"s":"I","c":"MONGOSH","id":1000000045,"ctx":"analytics","msg":"Flushed outstanding data","attr":{"flushError":"Trying to persist throttle state before userId is set","flushDuration":0}} diff --git a/Docker-compose/mongo/db/.mongodb/mongosh/66c87768cc1153003d5e739b_log b/Docker-compose/mongo/db/.mongodb/mongosh/66c87768cc1153003d5e739b_log new file mode 100644 index 00000000..233c1c5a --- /dev/null +++ b/Docker-compose/mongo/db/.mongodb/mongosh/66c87768cc1153003d5e739b_log @@ -0,0 +1,14 @@ +{"t":{"$date":"2024-08-23T11:50:00.023Z"},"s":"I","c":"MONGOSH","id":1000000000,"ctx":"log","msg":"Starting log","attr":{"execPath":"/usr/bin/mongosh","envInfo":{"EDITOR":null,"NODE_OPTIONS":null,"TERM":null},"version":"2.3.0","distributionKind":"compiled","buildArch":"x64","buildPlatform":"linux","buildTarget":"linux-x64","buildTime":"2024-08-15T21:23:23.577Z","gitVersion":"2013159f06f902b4e9a2060df411c6b5646d49d4","nodeVersion":"v20.16.0","opensslVersion":"3.0.13+quic","sharedOpenssl":false,"runtimeArch":"x64","runtimePlatform":"linux","runtimeGlibcVersion":"2.35","deps":{"nodeDriverVersion":"6.8.0","libmongocryptVersion":"1.11.0","libmongocryptNodeBindingsVersion":"6.1.0","kerberosVersion":"2.1.0"}}} +{"t":{"$date":"2024-08-23T11:50:00.029Z"},"s":"I","c":"MONGOSH","id":1000000005,"ctx":"config","msg":"User updated"} +{"t":{"$date":"2024-08-23T11:50:00.030Z"},"s":"I","c":"MONGOSH","id":1000000048,"ctx":"config","msg":"Loading global configuration file","attr":{"filename":"/etc/mongosh.conf","found":false}} +{"t":{"$date":"2024-08-23T11:50:00.069Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000049,"ctx":"mongosh-connect","msg":"Loaded system CA list","attr":{"caCount":284,"asyncFallbackError":null,"systemCertsError":null}} +{"t":{"$date":"2024-08-23T11:50:00.081Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000042,"ctx":"mongosh-connect","msg":"Initiating connection attempt","attr":{"uri":"mongodb://127.0.0.1:27017/admin?directConnection=true&serverSelectionTimeoutMS=2000&appName=mongosh+2.3.0","driver":{"name":"nodejs|mongosh","version":"6.8.0|2.3.0"},"devtoolsConnectVersion":"3.2.5","host":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T11:50:00.086Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000035,"ctx":"mongosh-connect","msg":"Server heartbeat succeeded","attr":{"connectionId":"127.0.0.1:27017"}} +{"t":{"$date":"2024-08-23T11:50:00.116Z"},"s":"I","c":"DEVTOOLS-CONNECT","id":1000000037,"ctx":"mongosh-connect","msg":"Connection attempt finished"} +{"t":{"$date":"2024-08-23T11:50:00.128Z"},"s":"I","c":"MONGOSH","id":1000000004,"ctx":"connect","msg":"Connecting to server","attr":{"userId":null,"telemetryAnonymousId":"66c864868081b0c453a26a11","connectionUri":"mongodb://:27017/admin?directConnection=true&serverSelectionTimeoutMS=2000&appName=mongosh+2.3.0","mongosh_version":"2.3.0","session_id":"66c87768cc1153003d5e739b","is_localhost":true,"is_do_url":false,"is_atlas_url":false,"is_atlas":false,"server_version":"7.0.12","node_version":"v20.16.0","server_os":"linux","server_arch":"x86_64","is_enterprise":false,"auth_type":null,"is_data_federation":false,"is_stream":false,"dl_version":null,"atlas_version":null,"is_genuine":true,"non_genuine_server_name":"mongodb","is_local_atlas":false,"fcv":"7.0","api_version":null,"api_strict":null,"api_deprecation_errors":null,"atlas_hostname":null}} +{"t":{"$date":"2024-08-23T11:50:00.130Z"},"s":"I","c":"MONGOSH","id":1000000010,"ctx":"shell-api","msg":"Initialized context","attr":{"method":"setCtx","arguments":{}}} +{"t":{"$date":"2024-08-23T11:50:00.130Z"},"s":"I","c":"MONGOSH-SNIPPETS","id":1000000024,"ctx":"snippets","msg":"Fetching snippet index","attr":{"refreshMode":"allow-cached"}} +{"t":{"$date":"2024-08-23T11:50:00.131Z"},"s":"I","c":"MONGOSH-SNIPPETS","id":1000000019,"ctx":"snippets","msg":"Loaded snippets","attr":{"installdir":"/data/db/.mongodb/mongosh/snippets"}} +{"t":{"$date":"2024-08-23T11:50:00.200Z"},"s":"I","c":"MONGOSH","id":1000000002,"ctx":"repl","msg":"Started REPL","attr":{"version":"2.3.0"}} +{"t":{"$date":"2024-08-23T11:50:00.306Z"},"s":"I","c":"MONGOSH","id":1000000011,"ctx":"shell-api","msg":"Performed API call","attr":{"method":"createUser","class":"Database","db":"admin","arguments":{}}} +{"t":{"$date":"2024-08-23T11:50:00.363Z"},"s":"I","c":"MONGOSH","id":1000000045,"ctx":"analytics","msg":"Flushed outstanding data","attr":{"flushError":"Trying to persist throttle state before userId is set","flushDuration":0}} diff --git a/Docker-compose/mongo/db/.mongodb/mongosh/config b/Docker-compose/mongo/db/.mongodb/mongosh/config new file mode 100644 index 00000000..f9b97cda --- /dev/null +++ b/Docker-compose/mongo/db/.mongodb/mongosh/config @@ -0,0 +1 @@ +{"userId":"66c864868081b0c453a26a11","telemetryAnonymousId":"66c864868081b0c453a26a11","enableTelemetry":true,"disableGreetingMessage":true} \ No newline at end of file diff --git a/Docker-compose/mongo/db/.mongodb/mongosh/mongosh_repl_history b/Docker-compose/mongo/db/.mongodb/mongosh/mongosh_repl_history new file mode 100644 index 00000000..e69de29b diff --git a/Docker-compose/mongo/db/.mongodb/mongosh/snippets/package.json b/Docker-compose/mongo/db/.mongodb/mongosh/snippets/package.json new file mode 100644 index 00000000..9e26dfee --- /dev/null +++ b/Docker-compose/mongo/db/.mongodb/mongosh/snippets/package.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/Docker-compose/rm-persistent-volumes.sh b/Docker-compose/rm-persistent-volumes.sh deleted file mode 100755 index 77484c8c..00000000 --- a/Docker-compose/rm-persistent-volumes.sh +++ /dev/null @@ -1,49 +0,0 @@ -#!/bin/bash - -function delete-volume { - if [ ! "$(docker volume ls -q -f name=$1)" ] - then - echo -e "Il volume $1 non esiste, quindi non faccio nulla! \n" - else - read -p "Il volume $1 esiste. Lo cancello?(y/n):" ELIMINA_VOLUME - ELIMINA_VOLUME=${ELIMINA_VOLUME:-"n"} - export ELIMINA_VOLUME - if [ $ELIMINA_VOLUME = "y" ] - then - docker volume rm $1 - echo -e "Eliminato $1 !!! \n" - else - echo -e "Non ho eliminato $1 !!! \n" - fi - fi -} - -echo -e "\n" - -echo -e "Inizio le procedure per fare il down della composizione e poi CANCELLARE i volumi persistenti! \n" - -echo -e "Fermo la composizione! \n" -docker-compose -f docker-compose.yml down -v; - -echo -e "\n" - -read -p "Volete veramente procedere con la cancellazione dei volumi persistenti? Tutti i dati andranno persi! Procedo ? (y/n) :" ELIMINA_DATI_PERSISTENTI -ELIMINA_DATI_PERSISTENTI=${ELIMINA_DATI_PERSISTENTI:-"n"} -export ELIMINA_DATI_PERSISTENTI -if [ $ELIMINA_DATI_PERSISTENTI != "y" ] -then - echo -e "\n" - echo -e "Non elimino nulla ed esco!!! \n" - exit 0 -else - -echo -e "Procedo ... \n" - -echo -e "\n" - -delete-volume satosa-saml2spid_nginx_certs -delete-volume satosa-saml2spid_mongodata - -fi - -exit 0 diff --git a/Docker-compose/run-docker-compose.sh b/Docker-compose/run-docker-compose.sh index e1b2a41a..67632f0d 100755 --- a/Docker-compose/run-docker-compose.sh +++ b/Docker-compose/run-docker-compose.sh @@ -1,46 +1,65 @@ #!/bin/bash -function create-volume { - if [ ! "$(docker volume ls -q -f name=$1)" ] - then - echo -e "Il volume $1 non esiste, lo creo! \n" - docker volume create --name=$1 - echo -e "\n" - if [[ ! -z "$2" ]] - then - echo -e "Ho creato il volume e ci copio i dati da $2 \n" - sudo cp -R $2* `docker volume inspect $1 | jq .[0].Mountpoint | sed 's/"//g'` - fi - else - echo -e "Il volume $1 esiste, non faccio nulla! \n" - fi +function clean_data { + rm -Rf ./mongo/db/* + rm -Rf ./satosa/* + rm -Rf ./djangosaml2_sp/* } -create-volume satosa-saml2spid_nginx_certs nginx/certs/ -create-volume satosa-saml2spid_mongodata +function initialize_satosa { + mkdir -p ./satosa + mkdir -p ./djangosaml2_sp + mkdir -p ./mongo/db -echo -e "\n" - -echo -e "Provo a scaricare le nuove versioni. \n" - -docker compose -f docker-compose.yml pull - -echo -e "\n" - -echo -e "Provo a fare il down della composizione. \n" - -docker compose -f docker-compose.yml down -v - -echo -e "\n" - -echo -e "Tiro su la composizione, in caso, con le nuove versioni delle immagini. \n" + if [ ! -f ./satosa/proxy_conf.yaml ]; then cp -R ../example/* ./satosa/ ; else echo 'satosa directory is already initialized' ; fi + if [ ! -f ./djangosaml2_sp/run.sh ]; then cp -R ../example_sp/djangosaml2_sp/* ./djangosaml2_sp ; else echo 'djangosaml2_sp directory is already initialided' ; fi +} -docker compose -f docker-compose.yml build django_sp +function start { + echo -e "Provo a scaricare le nuove versioni. \n" + docker compose -f docker-compose.yml pull + echo -e "\n" + echo -e "Provo a fare il down della composizione. \n" + docker compose -f docker-compose.yml down -v + echo -e "\n" + echo -e "Tiro su la composizione, in caso, con le nuove versioni delle immagini. \n" + docker compose -f docker-compose.yml build django_sp + docker compose -f docker-compose.yml up -d --wait --wait-timeout 60 + echo -e "\n" + echo -e "Completato. Per visionare i logs: 'docker-compose -f docker-compose.yml logs -f'" + exit 0 +} -docker compose -f docker-compose.yml up -d --wait --wait-timeout 60 +function help { + echo "" + echo "### run-docker-compose.sh ###" + echo "" + echo "initialize and start Satosa-Saml2Spid" + echo "" + echo "Option" + echo "-f Force clean and reinitialize data for Satosa, MongoDB and Djangosaml2_SP" + echo "-h Print this help" + echo "" +} -echo -e "\n" +while getopts ":fh" opt; do + case ${opt} in + f) + clean_data + ;; + h) + help + exit 0 + ;; + ?) + echo "Invalid option: -${OPTARG}." + echo "" + help + exit 1 + ;; + esac + initialize_satosa + start +done -echo -e "Completato. Per visionare i logs: 'docker-compose -f docker-compose.yml logs -f'" -exit 0 diff --git a/Docker-compose/satosa/.gitignore b/Docker-compose/satosa/.gitignore new file mode 100644 index 00000000..f935021a --- /dev/null +++ b/Docker-compose/satosa/.gitignore @@ -0,0 +1 @@ +!.gitignore