Skip to content

Commit

Permalink
Merge pull request #3785 from specklesystems/dim/dui3-main-merge-jan
Browse files Browse the repository at this point in the history
Dim/dui3 main merge jan
  • Loading branch information
didimitrie authored Jan 9, 2025
2 parents 52b795e + e13be36 commit b25e8b0
Show file tree
Hide file tree
Showing 787 changed files with 207,316 additions and 187,821 deletions.
81 changes: 67 additions & 14 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ workflows:
- main
- hotfix*

- test-server:
- test-server: &test-server-job-definition
context:
- speckle-server-licensing
- stripe-integration
Expand All @@ -32,6 +32,8 @@ workflows:
requires:
- docker-publish-postgres-container

- test-server-multiregion: *test-server-job-definition

- test-frontend-2:
filters: *filters-allow-all

Expand Down Expand Up @@ -190,6 +192,7 @@ workflows:
- test-objectsender
- test-server
- test-server-no-ff
- test-server-multiregion
- test-preview-service

- docker-publish-frontend:
Expand All @@ -205,6 +208,7 @@ workflows:
- test-objectsender
- test-server
- test-server-no-ff
- test-server-multiregion
- test-preview-service

- docker-publish-frontend-2:
Expand All @@ -220,6 +224,7 @@ workflows:
- test-objectsender
- test-server
- test-server-no-ff
- test-server-multiregion
- test-preview-service

- docker-publish-webhooks:
Expand All @@ -235,6 +240,7 @@ workflows:
- test-objectsender
- test-server
- test-server-no-ff
- test-server-multiregion
- test-preview-service

- docker-publish-file-imports:
Expand All @@ -250,6 +256,7 @@ workflows:
- test-objectsender
- test-server
- test-server-no-ff
- test-server-multiregion
- test-preview-service

- docker-publish-previews:
Expand All @@ -265,6 +272,7 @@ workflows:
- test-objectsender
- test-server
- test-server-no-ff
- test-server-multiregion
- test-preview-service

- docker-publish-test-container:
Expand All @@ -280,6 +288,7 @@ workflows:
- test-objectsender
- test-server
- test-server-no-ff
- test-server-multiregion
- test-preview-service

- docker-publish-postgres-container:
Expand All @@ -301,6 +310,7 @@ workflows:
- test-objectsender
- test-server
- test-server-no-ff
- test-server-multiregion
- test-preview-service

- docker-publish-docker-compose-ingress:
Expand All @@ -316,6 +326,7 @@ workflows:
- test-objectsender
- test-server
- test-server-no-ff
- test-server-multiregion
- test-preview-service

- publish-helm-chart:
Expand Down Expand Up @@ -356,6 +367,7 @@ workflows:
- get-version
- test-server
- test-server-no-ff
- test-server-multiregion
- test-ui-components
- test-frontend-2
- test-viewer
Expand Down Expand Up @@ -482,8 +494,9 @@ jobs:
S3_CREATE_BUCKET: 'true'
REDIS_URL: 'redis://127.0.0.1:6379'
S3_REGION: '' # optional, defaults to 'us-east-1'
AUTOMATE_ENCRYPTION_KEYS_PATH: 'test/assets/automate/encryptionKeys.json'
ENCRYPTION_KEYS_PATH: 'test/assets/automate/encryptionKeys.json'
FF_BILLING_INTEGRATION_ENABLED: 'true'
RATELIMITER_ENABLED: 'false'
steps:
- checkout
- restore_cache:
Expand Down Expand Up @@ -531,8 +544,8 @@ jobs:
working_directory: 'packages/server'

- run:
name: Checking for GQL schema breakages against speckle.xyz
command: 'yarn rover graph check Speckle-Server@speckle-xyz --schema ./introspected-schema.graphql'
name: Checking for GQL schema breakages against app.speckle.systems
command: 'yarn rover graph check Speckle-Server@app-speckle-systems --schema ./introspected-schema.graphql'
working_directory: 'packages/server'

- run:
Expand Down Expand Up @@ -564,14 +577,56 @@ jobs:
S3_CREATE_BUCKET: 'true'
REDIS_URL: 'redis://127.0.0.1:6379'
S3_REGION: '' # optional, defaults to 'us-east-1'
AUTOMATE_ENCRYPTION_KEYS_PATH: 'test/assets/automate/encryptionKeys.json'
FF_AUTOMATE_MODULE_ENABLED: 'false' # Disable all FFs
FF_WORKSPACES_MODULE_ENABLED: 'false'
FF_WORKSPACES_SSO_ENABLED: 'false'
FF_MULTIPLE_EMAILS_MODULE_ENABLED: 'false'
FF_GENDOAI_MODULE_ENABLED: 'false'
FF_GATEKEEPER_MODULE_ENABLED: 'false'
FF_BILLING_INTEGRATION_ENABLED: 'false'
ENCRYPTION_KEYS_PATH: 'test/assets/automate/encryptionKeys.json'
DISABLE_ALL_FFS: 'true'
RATELIMITER_ENABLED: 'false'

test-server-multiregion:
<<: *test-server-job
docker:
- image: cimg/node:18.19.0
- image: cimg/redis:7.2.4
- image: 'speckle/speckle-postgres'
environment:
POSTGRES_DB: speckle2_test
POSTGRES_PASSWORD: speckle
POSTGRES_USER: speckle
command: -c 'max_connections=1000' -c 'wal_level=logical'
- image: 'speckle/speckle-postgres'
environment:
POSTGRES_DB: speckle2_test
POSTGRES_PASSWORD: speckle
POSTGRES_USER: speckle
command: -c 'max_connections=1000' -c 'port=5433' -c 'wal_level=logical'
- image: 'minio/minio'
command: server /data --console-address ":9001" --address "0.0.0.0:9000"
- image: 'minio/minio'
command: server /data --console-address ":9021" --address "0.0.0.0:9020"
environment:
# Same as test-server:
NODE_ENV: test
DATABASE_URL: 'postgres://speckle:speckle@127.0.0.1:5432/speckle2_test'
PGDATABASE: speckle2_test
POSTGRES_MAX_CONNECTIONS_SERVER: 20
PGUSER: speckle
SESSION_SECRET: 'keyboard cat'
STRATEGY_LOCAL: 'true'
CANONICAL_URL: 'http://127.0.0.1:3000'
S3_ENDPOINT: 'http://127.0.0.1:9000'
S3_ACCESS_KEY: 'minioadmin'
S3_SECRET_KEY: 'minioadmin'
S3_BUCKET: 'speckle-server'
S3_CREATE_BUCKET: 'true'
REDIS_URL: 'redis://127.0.0.1:6379'
S3_REGION: '' # optional, defaults to 'us-east-1'
ENCRYPTION_KEYS_PATH: 'test/assets/automate/encryptionKeys.json'
FF_BILLING_INTEGRATION_ENABLED: 'true'
# These are the only different env keys:
MULTI_REGION_CONFIG_PATH: '../../.circleci/multiregion.test-ci.json'
FF_WORKSPACES_MODULE_ENABLED: 'true'
FF_WORKSPACES_MULTI_REGION_ENABLED: 'true'
RUN_TESTS_IN_MULTIREGION_MODE: true
RATELIMITER_ENABLED: 'false'

test-frontend-2:
docker: &docker-node-browsers-image
Expand Down Expand Up @@ -996,7 +1051,6 @@ jobs:
docker-build-monitor-container:
<<: *build-job
environment:
FOLDER: utils
SPECKLE_SERVER_PACKAGE: monitor-deployment

docker-build-docker-compose-ingress:
Expand Down Expand Up @@ -1066,7 +1120,6 @@ jobs:
docker-publish-monitor-container:
<<: *publish-job
environment:
FOLDER: utils
SPECKLE_SERVER_PACKAGE: monitor-deployment

docker-publish-docker-compose-ingress:
Expand Down
30 changes: 30 additions & 0 deletions .circleci/multiregion.test-ci.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
"main": {
"postgres": {
"connectionUri": "postgresql://speckle:speckle@127.0.0.1:5432/speckle2_test"
},
"blobStorage": {
"accessKey": "minioadmin",
"secretKey": "minioadmin",
"bucket": "speckle-server",
"createBucketIfNotExists": true,
"endpoint": "http://127.0.0.1:9000",
"s3Region": "us-east-1"
}
},
"regions": {
"region1": {
"postgres": {
"connectionUri": "postgresql://speckle:speckle@127.0.0.1:5433/speckle2_test"
},
"blobStorage": {
"accessKey": "minioadmin",
"secretKey": "minioadmin",
"bucket": "speckle-server",
"createBucketIfNotExists": true,
"endpoint": "http://127.0.0.1:9020",
"s3Region": "us-east-1"
}
}
}
}
2 changes: 1 addition & 1 deletion .github/workflows/preview-service-acceptance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ jobs:
services:
postgres:
# Docker Hub image
image: postgres:16.4-bookworm@sha256:91f464e7ba0ad91a106c94cff079fb4384139291b8c0502fd36989cf2c788bbb
image: postgres:16.4-bookworm@sha256:e62fbf9d3e2b49816a32c400ed2dba83e3b361e6833e624024309c35d334b412
env:
POSTGRES_DB: preview_service_test
POSTGRES_PASSWORD: preview_service_test
Expand Down
8 changes: 7 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,12 @@ postgres-data/
redis-data/

.tshy-build
obj/
bin/
!packages/monitor-deployment/bin
!packages/preview-service/bin
!packages/server/bin

# Server
multiregion.json
multiregion.json
multiregion.test.json
6 changes: 5 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,8 @@ venv

storybook-static
.tshy
.tshy-build
.tshy-build

packages/fileimport-service/ifc-dotnet/
packages/fileimport-service/stl/
packages/fileimport-service/obj/
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,14 @@ EMAIL_PORT="1025"

The web portal is available at `localhost:1080` and it's listening for mail on port `1025`.

### Minio (S3 storage)

Default credentials are: `minioadmin:minioadmin`
Main storage Web UI: [http://localhost:9001/](http://localhost:9001/)
Region1 storage Web UI: [http://localhost:9021/](http://localhost:9021/)

You can use the web UI to validate uploaded blobs

# Contributing

Please make sure you read the [contribution guidelines](https://github.com/specklesystems/speckle-server/blob/main/CONTRIBUTING.md) for an overview of the best practices we try to follow.
Expand Down
11 changes: 11 additions & 0 deletions docker-compose-deps.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,16 @@ services:
- '127.0.0.1:9000:9000'
- '127.0.0.1:9001:9001'

minio-region1:
image: 'minio/minio'
command: server /data --console-address ":9001"
restart: always
volumes:
- minio-region1-data:/data
ports:
- '127.0.0.1:9020:9000'
- '127.0.0.1:9021:9001'

# Local OIDC provider for testing
keycloak:
image: quay.io/keycloak/keycloak:25.0
Expand Down Expand Up @@ -127,3 +137,4 @@ volumes:
pgadmin-data:
redis_insight-data:
minio-data:
minio-region1-data:
2 changes: 2 additions & 0 deletions mise.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[tools]
node = '22'
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
"dev:docker": "docker compose -f ./docker-compose-deps.yml",
"dev:docker:up": "docker compose -f ./docker-compose-deps.yml up -d",
"dev:docker:down": "docker compose -f ./docker-compose-deps.yml down",
"dev:docker:restart": "yarn dev:docker:down && yarn dev:docker:up",
"dev:kind:up": "ctlptl apply --filename ./.circleci/deployment/cluster-config.yaml",
"dev:kind:down": "ctlptl delete -f ./.circleci/deployment/cluster-config.yaml",
"dev:kind:helm:up": "yarn dev:kind:up && tilt up --file ./.circleci/deployment/Tiltfile.helm --context kind-speckle-server",
Expand Down
Loading

0 comments on commit b25e8b0

Please sign in to comment.