Skip to content

Commit

Permalink
Merge branch 'thinx-staging'
Browse files Browse the repository at this point in the history
* thinx-staging:
  fix: package.json & package-lock.json to reduce vulnerabilities
  GDPR notification scheduler fix
  fix: upgrade semver from 7.5.3 to 7.6.3
  fix: upgrade moment-timezone from 0.5.40 to 0.5.46
  fix: upgrade qs from 6.10.3 to 6.13.0
  fix: upgrade yaml from 2.2.2 to 2.6.0
  reviewed all builders CI pipelines
  moved extra_build_args to single line
  after passing the test, debugging issue with buildx in build-console-classic step (and new docker orb)
  network external could not be found
  debugging mqtt dns issue: downgraded mqtt client, upgraded docker orb to latest supported, changed internal network from type external to internal
  submodule updates
  • Loading branch information
suculent committed Nov 27, 2024
2 parents 184139e + 88a1619 commit f2011e6
Show file tree
Hide file tree
Showing 10 changed files with 53 additions and 182 deletions.
45 changes: 15 additions & 30 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
version: 2.1
orbs:
node: circleci/[email protected]
docker: circleci/docker@2.0.3
docker: circleci/docker@2.7.1
slack: circleci/[email protected]

jobs:

build-base:
executor: docker/docker
steps:
- setup_remote_docker
- setup_remote_docker:
version: previous
- checkout
- docker/check
- run:
Expand All @@ -31,8 +32,8 @@ jobs:
build-console-cloud:
executor: docker/docker
steps:
- setup_remote_docker
# version: 20.10.18
- setup_remote_docker:
version: previous
- checkout
- run:
name: Fetch all dependencies (esp. console)
Expand Down Expand Up @@ -73,8 +74,8 @@ jobs:
build-console-classic:
executor: docker/docker
steps:
- setup_remote_docker
# version: 20.10.18
- setup_remote_docker:
version: 20.10.24
- checkout
- run:
name: Fetch all dependencies (esp. console)
Expand All @@ -87,18 +88,7 @@ jobs:
docker-context: services/console/src
image: thinx/console
dockerfile: services/console/src/Dockerfile
extra_build_args: |
--build-arg ROLLBAR_ACCESS_TOKEN=${ROLLBAR_ACCESS_TOKEN} \
--build-arg LANDING_HOSTNAME=${LANDING_HOSTNAME} \
--build-arg API_HOSTNAME=${API_HOSTNAME} \
--build-arg API_BASEURL=${API_BASEURL} \
--build-arg WEB_HOSTNAME=${WEB_HOSTNAME} \
--build-arg GOOGLE_ANALYTICS_ID=${GOOGLE_ANALYTICS_ID} \
--build-arg CRISP_WEBSITE_ID=${CRISP_WEBSITE_ID} \
--build-arg ENTERPRISE=${ENTERPRISE} \
--build-arg ENVIRONMENT=${ENVIRONMENT} \
--build-arg COMMIT_ID=$CIRCLE_SHA1 \
--build-arg VERSION_CODE=$(echo $CIRCLE_SHA1 | cut -c -7) \
extra_build_args: '--build-arg ROLLBAR_ACCESS_TOKEN=${ROLLBAR_ACCESS_TOKEN} --build-arg LANDING_HOSTNAME=${LANDING_HOSTNAME} --build-arg API_HOSTNAME=${API_HOSTNAME} --build-arg API_BASEURL=${API_BASEURL} --build-arg WEB_HOSTNAME=${WEB_HOSTNAME} --build-arg GOOGLE_ANALYTICS_ID=${GOOGLE_ANALYTICS_ID} --build-arg CRISP_WEBSITE_ID=${CRISP_WEBSITE_ID} --build-arg ENTERPRISE=${ENTERPRISE} --build-arg ENVIRONMENT=${ENVIRONMENT} --build-arg COMMIT_ID=$CIRCLE_SHA1 --build-arg VERSION_CODE=$(echo $CIRCLE_SHA1 | cut -c -7)'
tag: 'swarm'
- docker/push:
digest-path: /tmp/digest.txt
Expand All @@ -109,8 +99,8 @@ jobs:
build-api-cloud:
executor: docker/docker
steps:
- setup_remote_docker
# version: 20.10.18
- setup_remote_docker:
version: previous
- checkout
- run:
name: Clean package-lock
Expand All @@ -120,12 +110,7 @@ jobs:
- docker/build:
image: thinxcloud/api
dockerfile: ./Dockerfile
extra_build_args: |
--build-arg AQUA_SEC_TOKEN=${AQUA_SEC_TOKEN} \
--build-arg SNYK_TOKEN=${SNYK_TOKEN} \
--build-arg ENVIRONMENT=${ENVIRONMENT} \
--build-arg REVISION=$(git describe --abbrev=0) \
--build-arg ENTERPRISE=${ENTERPRISE} \
extra_build_args: '--build-arg AQUA_SEC_TOKEN=${AQUA_SEC_TOKEN} --build-arg SNYK_TOKEN=${SNYK_TOKEN} --build-arg ENVIRONMENT=${ENVIRONMENT} --build-arg REVISION=$(git describe --abbrev=0) --build-arg ENTERPRISE=${ENTERPRISE}'
tag: 'latest'
- docker/push:
digest-path: /tmp/digest.txt
Expand Down Expand Up @@ -173,8 +158,8 @@ jobs:
chmod +x $DOCKER_CONFIG/cli-plugins/docker-compose
docker compose version
- setup_remote_docker
# version: 20.10.18
- setup_remote_docker:
version: previous

- checkout

Expand Down Expand Up @@ -332,8 +317,8 @@ jobs:
sysdig:
executor: docker/docker
steps:
- setup_remote_docker
# version: 20.10.18
- setup_remote_docker:
version: previous
- checkout
- docker/check
- run:
Expand Down
2 changes: 1 addition & 1 deletion builders/arduino-docker-build
2 changes: 1 addition & 1 deletion builders/micropython-docker-build
2 changes: 1 addition & 1 deletion builders/mongoose-docker-build
2 changes: 1 addition & 1 deletion builders/platformio-docker-build
2 changes: 1 addition & 1 deletion docker-compose.test.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
version: '2.2'
networks:
nat:
external: true
external: false
internal:
external: false
services:
Expand Down
2 changes: 1 addition & 1 deletion lib/thinx/gdpr.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ module.exports = class GDPR {
var d = new Date();
d.setMonth(d.getMonth() - month);
d.setDate(d.getDay() - day);
return d;
return Math.floor(d.valueOf() / 1000);
}

notify24(user, _opt_callback) {
Expand Down
Loading

0 comments on commit f2011e6

Please sign in to comment.