Commit Graph

141 Commits

Author SHA1 Message Date
Iain Sproat dc4c80885d fix(helm README): add missing description end tag (#1701) 2023-07-13 19:41:46 +01:00
Iain Sproat c3dc3aceb2 fix helm test frontend2 (#1696)
* Quote values
2023-07-13 13:21:47 +01:00
Iain Sproat 54829ec257 fix(helm test): works with frontend2 (#1693) 2023-07-13 13:02:03 +01:00
Iain Sproat 05aa82b3f1 fix(helm): only deploy frontend-2 if enabled in helm chart (#1695)
* fix(helm): only deploy frontend-2 if enabled in helm chart
* Do not deploy frontend if frontend-2 is enabled
2023-07-13 11:34:33 +01:00
Kristaps Fabians Geikins 93bd557256 feat(fe2): client-side error logging to seq (#1691)
* WIP seq-logging

* nuxt plugin + infra adjustments
2023-07-12 16:58:58 +03:00
Iain Sproat 9f0418893f chore(objects upload): improves response when error due to large object size (#1685)
* test(objects upload): adds a test for large object
* print object too large messages in response
* allows object maximum size to be configured
2023-07-12 10:57:59 +01:00
Kristaps Fabians Geikins eaf925b387 feat(fe-2): improved logging (#1684)
* feat(fe-2): improved logging

* yarn lock update

* attempted speckle/shared build fix

* helm updates

* Updates documentation for helm chart

---------

Co-authored-by: Iain Sproat <68657+iainsproat@users.noreply.github.com>
2023-07-12 10:21:08 +03:00
Iain Sproat 2626d9095b fix(docker compose): must use 2.3 as we have features removed in 3 (#1679) 2023-07-10 12:23:27 +01:00
Iain Sproat fad395a292 fix(docker compose): set minimum compose version as '3' (#1677)
- matches the minimum version for our dependencies file ('3')
- healthcheck was introduced in 2.1, and healthcheck.start_period in 2.3, so >=2.3 was minimum
2023-07-10 10:29:10 +01:00
Iain Sproat a0a39bd711 fix(healthcheck): Add a 2 second timeout to the healthchecks (#1674)
* fix(healthcheck): Add a 2 second timeout to the healthcheck http request
* Ensure all error types are caught and the non-zero failure exit code is always 1
2023-07-07 16:22:15 +01:00
Iain Sproat fa36e9e40c feat(docker compose): healthcheck for speckle-server (#1651)
* feat(docker compose): healthcheck for speckle-server
- if speckle server pod becomes unresponsive (but has not yet exited with a non-zero exit code), it will be automatically restarted after 30s.

* feat(1click): add healthcheck to speckle-server container running in DigitalOcean 1click

* fix(1click): remove command statements
- the docker image is responsible for providing these
2023-06-29 15:55:40 +02:00
Dimitrie Stefanescu 802f3c9924 fix(fe2): newsletter changes 2023-06-22 16:35:49 +01:00
Dimitrie Stefanescu 7962d56530 Merge branch 'main' into dim/fe2/newsletter-registration 2023-06-22 15:42:21 +01:00
Iain Sproat be4e840a80 feat(helm): mailchimp is disabled by default 2023-06-19 10:12:58 +01:00
Dimitrie Stefanescu d98f0fa9f9 feat(server): mailchimp helm chart updates 2023-06-16 15:26:32 +01:00
Iain Sproat 5f6a696def fix(helm): the ingress should support the maximum file size (#1638) 2023-06-16 12:08:14 +01:00
dependabot[bot] c878cddee2 build(deps): bump requests in /utils/test-deployment (#1588)
Bumps [requests](https://github.com/psf/requests) from 2.28.1 to 2.31.0.
- [Release notes](https://github.com/psf/requests/releases)
- [Changelog](https://github.com/psf/requests/blob/main/HISTORY.md)
- [Commits](https://github.com/psf/requests/compare/v2.28.1...v2.31.0)

---
updated-dependencies:
- dependency-name: requests
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-13 11:47:46 +01:00
Iain Sproat ef41620850 feat(helm chart): allow NODE_TLS_REJECT_UNAUTHORIZED to be configured (#1621) 2023-06-13 11:46:13 +01:00
Iain Sproat 811cc3ef9d feat(helm): allow email from address to be configured via helm chart (#1623) - reported by John Shiangoli 2023-06-13 11:45:30 +01:00
dependabot[bot] 2dd79d52a7 build(deps-dev): bump vite from 3.1.0 to 4.x (#1610)
* build(deps-dev): bump vite from 3.1.0 to 4.x

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 3.1.0 to 3.2.7.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v3.2.7/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v3.2.7/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>

* fixing deps

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Kristaps Fabians Geikins <fabis94@live.com>
2023-06-12 16:18:54 +03:00
Dimitrie Stefanescu 7b037352df Dim/fe2/view changes (#1608)
* Fixed an issue with curves doubling up on geometry and also not being selectable after the last filtering changes. Added the options to make lines transparent. Added lines to diffing

* Points now are diff-able and support proper visual diff-ing. Visual diff filters are now chosen internally by the Differ. Fixed an issue with LineBatch and transparency

* Implemented PLAIN visual diff mode, where all objects keep their original materil, but opacity is manipulated via the diff time. Added API member function to switch between the PLAIN and COLORED visual diff modes

* feat(fe2): diffs wip

* Diffing fixes for instances and blocks. Things seem to be working fine, but there are some caveats. Additionally, some older issues were fixed and diffing now works better on all the rest of the streams

* feat(fe2): de-dupes diff results

* feat(fe2): wip diffs

* feat(fe2): diff transparency goes from 0 to 1

* feat(fe2): diff results display work

* feat(fe2): diff results display work

* feat(fe2): diff panel work

* feat(fe2): diff work: various display changes, coloring toggle, selection logic, selection object display wip

* feat(fe2): diff work: cleaned up old/new version, fixed minor bug in viewer diff time when swapping color mode

* feat(fe2): diff work: implements custom selection logic and selection display for modified objects (they come in pairs now)

* feat(fe2): diff minor fix in selected object display

* feat(fe2): wip; trying to fix diff order to be consistent (ordered by date)

* feat(fe2): wip, broken state right now

* feat(fe2): fixes scrollbars in viewer

* feat(fe2): fixes slider sync with diff time

* feat(fe2): WIP syncs of diffs (threads, refreshes, etc.)

* feat(fe2): diffing polish

* speckle shared fix

* speckle shared fix

* more bugfixes

* linter fixess

* more CI fixes

* fix viewerState serialization

* more linting fixess

* template fixes

* moving tailwind classes to theme package

* migrated away from diffString + simplified postSetup

* moved diff new/old version resolution to use state.resources

* cleanup

* updating url threadId & diff command correctly

* minor improvements to diff state

---------

Co-authored-by: AlexandruPopovici <alexandrupopoviciioan@gmail.com>
Co-authored-by: Kristaps Fabians Geikins <fabis94@live.com>
2023-06-08 11:26:19 +03:00
Iain Sproat 5361d64e99 Revert "fix(server helm / dockerfile): remove entrypoint from dockerfile (#1605)" (#1606)
This reverts commit bcea709712.
2023-06-02 16:33:26 +01:00
Gergő Jedlicska bcea709712 fix(server helm / dockerfile): remove entrypoint from dockerfile (#1605)
the server helm deployment only overrides if inspect is needed
2023-06-02 16:01:01 +02:00
Iain Sproat e71f382e6a feat(helm): configure inspect flag for server via helm chart (#1593) 2023-06-01 21:43:22 +01:00
Kristaps Fabians Geikins 2eb5f51af3 feat: dui3 package (#1585) 2023-05-19 16:57:28 +03:00
Iain Sproat b1cbd05683 feat(circleci): adds a new step to ensure Helm Chart documentation is kept in line with Helm Chart (#1574)
* fix(helm): update documentation to match helm chart
* fix(helm): update documentation should not update README in helm repository
* fix(helm): should ensure output schema conforms to prettier requirements
* feat(pre-commit): update helm documentation as part of pre-commit
* feat(circleci): update Helm README when publishing new Helm chart
* fix(pre-commit): need to npm install before using readme generator
2023-05-12 13:26:28 +01:00
Iain Sproat 93179e163b fix(helm): selector labels for frontend cannot be changed automatically by helm (#1569) 2023-05-08 11:14:12 +02:00
Kristaps Fabians Geikins b02a07e2b6 feat: Frontend 2.0 MVP 2023-05-08 10:47:01 +03:00
Gergő Jedlicska 89dccd8495 feat(server): add speckle automate as a configurable default app (#1540)
* feat(server): add speckle automate as a configurable default app

* feat(server): add default automate url, and helm values

* fix default app tests reporting the old number
2023-04-19 12:59:59 +02:00
Andrew Gartrell 0b10fc3a07 Update values.yaml (#1536)
* updated tag to current tag
* dropped "v" prefix which hasn't been used since 2.3.3
2023-04-19 12:57:23 +02:00
Iain Sproat 1515e2fee6 revert(ratelimit): defaults should remain as was prior to 2a35fe6 (#1528)
* Revert "fix(ratelimit): reduce /graphql limit based on incident (#1505)"
This reverts commit 2a35fe6178.
* Revert helm chart defaults to value in code
- fix typo
2023-04-13 15:24:51 +01:00
Iain Sproat 59c0b7ada0 feat(helm): rate limits are configurable via helm chart (#1507)
* feat(helm): rate limits are configurable via helm chart
* Document server.monitoring.mp
* Update schema.json
2023-04-07 15:17:03 +01:00
Iain Sproat aee6de9ee0 fix(helm): network policy should allow egress to analytics.speckle.sy… (#1494)
* fix(helm): network policy should allow egress to analytics.speckle.systems
- previously only allowed DNS lookup

* matchName not matchPattern on analytics.speckle.systems
2023-03-30 14:52:02 +02:00
Iain Sproat ca0c0437f1 Fix network policies (#1491)
* fix(helm): fix logic in networkpolicies to check for existence of object
- object must exist before we can query its parameters
- if the 'mp' object is set and it is explicitly set to 'false' then the endpoint is blocked, otherwise it is allowed.

* fix(helm chart): accessing an unset object in the second part of an and statement breaks helm

* fix(helm): cilium network policy updated to put mp within monitoring object
2023-03-30 11:23:29 +01:00
Iain Sproat 03bc5a4ead fix(helm): fix logic in networkpolicies to check for existence of object (#1490)
- object must exist before we can query its parameters
- if the 'mp' object is set and it is explicitly set to 'false' then the endpoint is blocked, otherwise it is allowed.
2023-03-30 10:52:03 +01:00
Kristaps Fabians Geikins 5d0fceaaf3 feat: proper sign up tracking (#1489)
* feat: register flag passed to fe

* feat: mixpanel tracking for all sign ups

* feat: utm first touch & last touch tracking

* feat(helm): Allows Environment Variable for MP to be configured
- default is enabled
- renames environment variable to ENABLE_MP

* feat(helm network policy): allowlist analytics.speckle.systems

---------

Co-authored-by: Iain Sproat <68657+iainsproat@users.noreply.github.com>
2023-03-30 12:21:59 +03:00
Iain Sproat c461397aa2 fix(helm): schema.json now matches values file (#1445)
- small typo fix to values.yaml documentation
2023-03-10 10:39:26 +00:00
Iain Sproat d3b4310672 docs(helm): schematic diagram in mermaid format (#1358)
* docs(helm): schematic diagram in mermaid format
* Clarifies that dependencies can be external or internal to cluster
* Explicitly show namespace containing secrets
2023-02-22 09:40:30 +00:00
Gergő Jedlicska 40a6701799 feat(server): add switchable admin authz override (#1378)
* feat(server): add switchable admin authz override

* fix(server): make sure tests work with the new admin override

* feat(server authz): make sure to add all requested roles to server admins in admin override mode
2023-02-17 16:31:06 +01:00
Iain Sproat dcf8bcc607 fix(monitor): logging should produce a msg field containing the message (#1363)
python logging produces an event field with the message, but all other loggers produce a msg field.
2023-02-08 15:35:43 +00:00
Iain Sproat 68fd86b754 chore(frontend): use bitnami/openresty as base image for frontend Dockerfile (#1335)
* chore(frontend): use bitnami/openresty as base image for frontend Dockerfile

openresty/openresty was not being patched as frequently as we would like, resulting in numerous
vulnerabilities without resolution. bitnami/openresty is being patched more frequently.

Some additional changes were necessary when porting our frontend between these distributions:
- html files are in /app
- nginx.conf is in /opt/bitnami/openresty/nginx/conf/nginx.conf
- envsubst is not available by default in bitnami/openresty and needs to be copied in
- Nginx.conf - we wrap the server block in http block and overwrite root nginx.conf
    - using the existing bitnami/openresty nginx.conf as a server block alone causes issues with bitnami/openresty, as bitnami/openresty provides a root nginx.conf which conflicts with directives in Speckle's server block
- we copy the directives from openresty/openresty (which are known to work with Speckle's server block), and apply them alongside Speckle's server block. This creates a new root nginx.conf which we can overwrite the default on the image.
- nginx should use a port available to non sudo/root user, we have selected 8080 instead of previous 80
- need to explicitly output nginx logs to stderr / stdout

Created a readonly root file system on Kubernetes. This requires the following changes:
- emptyDir volumes are mounted in kubernetes to allow bitnami/openresty to write to specific locations
- explicitly include and copy mime.types file to nginx configuration directory

Due to the change to non-privileged port number (8080), the following subsequent changes were required:
- Update 1-click deployment script to match frontend at port 8080
- Updates docker-compose-speckle.yaml file

Co-authored-by: Gergő Jedlicska <gergo@jedlicska.com>
2023-01-25 19:06:48 +00:00
spgoad 38720cecdc Feature: Add OpenID Connect Generic Authentication Strategy (#1283)
* feat(server): add OIDC auth strategy

Add an OpenID Connect Authentication Strategy for Speckle Server. Enables configuration of
authentication against an OIDC standard compliant identity provider endpoint.

closes specklesystems#1270

Co-authored-by: spencer.goad <spencer.goad@disney.com>
2023-01-09 13:41:50 +00:00
Gergő Jedlicska e6484f6360 gergo/helmDisableFileUpload (#1281)
* style(server): fix formatting

* fix(preview-service): fix chromium deps in Dockerfile

* feat(helm chart): expose file uploads disable flag in the helm chart

* fix(helm chart): value name fix

* fix(helm): its values

* fix(helm chart): fix always disabled file uploads
2022-12-23 15:42:24 +01:00
Gergő Jedlicska 42ce09e651 gergo/helmDisableFileUpload (#1280)
* style(server): fix formatting

* fix(preview-service): fix chromium deps in Dockerfile

* feat(helm chart): expose file uploads disable flag in the helm chart

* fix(helm chart): value name fix

* fix(helm): its values
2022-12-23 14:59:27 +01:00
Gergő Jedlicska cd61b5b40e gergo/helmDisableFileUpload (#1279)
* style(server): fix formatting

* fix(preview-service): fix chromium deps in Dockerfile

* feat(helm chart): expose file uploads disable flag in the helm chart

* fix(helm chart): value name fix
2022-12-23 14:55:06 +01:00
Gergő Jedlicska 848d65b0a0 gergo/helmDisableFileUpload (#1278)
* style(server): fix formatting

* fix(preview-service): fix chromium deps in Dockerfile

* feat(helm chart): expose file uploads disable flag in the helm chart
2022-12-23 14:50:46 +01:00
Iain Sproat 170e52cf95 fix(helm chart): liveness probe on webhook and fileimport use distroless node path (#1271) 2022-12-14 19:42:05 +00:00
Iain Sproat 2852789df1 Use estimate instead of count when getting number of rows in table (#1266) 2022-12-13 16:25:13 +00:00
Iain Sproat 96bed71022 fix(logging): Improves error logging and pretty-prints logs during dev & test (#1255)
* Improves error logging
- use pino error logger correctly by passing in error as first argument

* monitor deployment: Filter logging at INFO level and above
* Use structured logging to create parameters for monitoring results
* Add structured logging to obj fileimport service
* Fileimport service, fix and improve logging
    - use child logger with additional context where possible
    - select appropriate logging level
- fix duplicated context in log statement
* REST endpoints, add context to structured logging and remove same context from message
* Webhook service provides context to bound logger to properly use structured logging
    - Pass bound logger containing context to `makeNetworkRequest`
    - do not log url, as it may contain a secret (like Discord's webhook urls), instead log the webhook Id
     - log error message when network call fails
* upload: make better use of structured logging when recording data
* pino-pretty when in dev or test mode
    - pino-pretty configured to send to stderr
* LOG_PRETTY env var
* Silence structured logging during testing
     - can not rely on determining the port number by reading from stdout/stderr
     - instead we determine which port is free, then create our server on that port
     - we then poll that port until the server is ready before commencing tests
* Allow puppeteer to install chromium
* Do not need to install chromium separately
2022-12-13 09:18:28 +00:00
Iain Sproat d0828693ff Enable python linting/formatting in pre-commit (#1257)
- fix all the linting/formatting issues
2022-12-09 11:20:45 +00:00