Граф коммитов

287 Коммитов

Автор SHA1 Сообщение Дата
dependabot[bot] 2038d18559
chore(deps-dev): bump stylelint from 15.2.0 to 15.6.2
Bumps [stylelint](https://github.com/stylelint/stylelint) from 15.2.0 to 15.6.2.
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/15.2.0...15.6.2)

---
updated-dependencies:
- dependency-name: stylelint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-05-17 07:02:56 +00:00
Barry Chen cc75ad3372
chore(deps): upgrade mocha in eslint-plugin-fxa
This commit also resolves `flat` in pm2's dependency graph to a newer
version.
2023-05-15 09:01:16 -05:00
Barry Chen 4a0ca7e040
Merge pull request #15104 from mozilla/fxa-5186-local-eslint-fxa
chore(lint): move eslint-plugin-fxa into the monorepo
2023-04-06 13:03:24 -07:00
Barry Chen b6b445cd6d
chore(lint): move eslint-plugin-fxa into the monorepo
Because:
 - we don't want to maintain the fxa eslint plugin in another repo

This commit:
 - move the plugin into the monorepo

Co-authored-by: Peter deHaan <peter@deseloper.com>
2023-03-29 11:30:03 -05:00
Barry Chen 218b49e88b
Revert "chore(lint): move eslint-plugin-fxa into the monorepo" 2023-03-28 12:47:03 -07:00
Barry Chen 5b09bdf667
Merge pull request #15073 from mozilla/fxa-5186-local-eslint-fxa
chore(lint): move eslint-plugin-fxa into the monorepo
2023-03-28 10:51:15 -07:00
dschom b843d2bb94
task(settings): Move legal doc query to gql
Because:
- We want to move our legal doc query to the server side so it can be made with a single call.

This Commit:
- Changes to clone script:
  - Use the provided state.json provided by l10n repo
  - Moves download to external folder
- Changes to settings:
  - Use gql to fetch legal doc
- Changes to gql
  - Adds ability to resolve a legal document.
2023-03-27 18:02:43 -07:00
Barry Chen fbb5f0f5bc
chore(lint): move eslint-plugin-fxa into the monorepo
Because:
 - we don't want to maintain the fxa eslint plugin in another repo

This commit:
 - move the plugin into the monorepo

Co-authored-by: Peter deHaan <peter@deseloper.com>
2023-03-22 16:12:11 -05:00
dependabot[bot] 1c1c325b2e
chore(deps): bump pm2 from 5.2.2 to 5.3.0
Bumps [pm2](https://github.com/Unitech/pm2) from 5.2.2 to 5.3.0.
- [Release notes](https://github.com/Unitech/pm2/releases)
- [Changelog](https://github.com/Unitech/pm2/blob/master/CHANGELOG.md)
- [Commits](https://github.com/Unitech/pm2/compare/5.2.2...5.3.0)

---
updated-dependencies:
- dependency-name: pm2
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-03-22 17:18:31 +00:00
Barry Chen a5dad11653
Merge pull request #14985 from mozilla/FXA-6314-node18
chore(deps): upgrade to node.js 18
2023-03-20 12:28:27 -07:00
Barry Chen da11e63832
chore(deps): upgrade to node.js 18
Because:
 - we want to use the latest node LTS major version

This commit:
 - upgrades FxA to use node 18, with two workarounds
   - Webpack uses a hash algorithm that's no longer supported by default
     in node 17+, causing build failures; --openssl-legacy-provider is
     used as the workaround
   - dns.lookup in node 17+ by default returns the results in the same
     order as they are from the resolver, which could lead to
     'localhost' resolving to ::1; --dns-result-order=ipv4first is used
     as the workaround
2023-03-20 13:28:10 -05:00
dependabot[bot] af28197687
chore(deps): bump lint-staged from 13.1.3 to 13.2.0
Bumps [lint-staged](https://github.com/okonet/lint-staged) from 13.1.3 to 13.2.0.
- [Release notes](https://github.com/okonet/lint-staged/releases)
- [Commits](https://github.com/okonet/lint-staged/commits/v13.2.0)

---
updated-dependencies:
- dependency-name: lint-staged
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-03-20 18:09:30 +00:00
dschom 76ad8cb534
task(many): Fix issues with l10n:clone failing on postinstall
Because:
- We are hitting race conditions using postinstall
- If two packages invoke l10n:clone at the same time in their post install git will error out

This Commit:
- Adds a git checkout hook, so the l10n folder is regularly updated
- Remove l10n:clone and l10n:prime commands from the post install
- Moves the l10n:prime command into build and tests commands
- Adds clean script so blank slates can be tested locally
- Adds respective l10n-bundle and l10n-prime scripts per workspace
- Moves the creation of the git-head.txt to the prime step and avoids creating an change on the l10n repo

Co-authored-by: Peter deHaan <peter@deseloper.com>
2023-03-20 11:23:00 -05:00
Meghan Sardesai 5eee424611
Revert "Train 254.2" 2023-03-16 17:00:51 -04:00
dschom 0d828216d3
fix(ci): Don't clone on postinstall create lists after base install. 2023-03-15 17:01:21 -07:00
dschom 1d709000fe
task(many): Only clone l10n once and combine ftl files.
Because:
- We want to avoid redundant git clone operations
- We want to reduce the number of ftl bundles requested on the client side.

This Commit:
- Adds _scripts/l10n/*.sh for conducting l10n build operations
- Bundles ftl files together into ftl main
- Removes bundle prop on AppLocalizer, so that it uses the default, [main.ftl]
- Replace - with _ in locale names when resolving ftl files
- Removes clone-l10n.sh
2023-03-15 11:30:44 -07:00
dependabot[bot] 4a20611e1a
chore(deps): bump eslint-plugin-jest from 27.1.3 to 27.2.1
Bumps [eslint-plugin-jest](https://github.com/jest-community/eslint-plugin-jest) from 27.1.3 to 27.2.1.
- [Release notes](https://github.com/jest-community/eslint-plugin-jest/releases)
- [Changelog](https://github.com/jest-community/eslint-plugin-jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/jest-community/eslint-plugin-jest/compare/v27.1.3...v27.2.1)

---
updated-dependencies:
- dependency-name: eslint-plugin-jest
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-03-10 07:01:36 +00:00
Barry Chen cd4a550fac
Merge pull request #14961 from mozilla/dependabot/npm_and_yarn/lint-staged-13.1.2
chore(deps): bump lint-staged from 13.0.3 to 13.1.2
2023-03-06 07:06:12 -08:00
dependabot[bot] 3ed94eb197
chore(deps): bump lint-staged from 13.0.3 to 13.1.2
Bumps [lint-staged](https://github.com/okonet/lint-staged) from 13.0.3 to 13.1.2.
- [Release notes](https://github.com/okonet/lint-staged/releases)
- [Commits](https://github.com/okonet/lint-staged/compare/v13.0.3...v13.1.2)

---
updated-dependencies:
- dependency-name: lint-staged
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-03-06 07:15:20 +00:00
dependabot[bot] 551f164e57
chore(deps-dev): bump stylelint from 14.14.0 to 15.2.0
Bumps [stylelint](https://github.com/stylelint/stylelint) from 14.14.0 to 15.2.0.
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/14.14.0...15.2.0)

---
updated-dependencies:
- dependency-name: stylelint
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-03-06 07:05:02 +00:00
dependabot[bot] 96a9900a96
chore(deps-dev): bump eslint-plugin-react from 7.31.10 to 7.32.2
Bumps [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) from 7.31.10 to 7.32.2.
- [Release notes](https://github.com/jsx-eslint/eslint-plugin-react/releases)
- [Changelog](https://github.com/jsx-eslint/eslint-plugin-react/blob/master/CHANGELOG.md)
- [Commits](https://github.com/jsx-eslint/eslint-plugin-react/compare/v7.31.10...v7.32.2)

---
updated-dependencies:
- dependency-name: eslint-plugin-react
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-03-02 18:34:45 +00:00
Julian Poyourow cdd25a2e71
feat(auth): geoip, parallelization for automatic tax
Because:

* We need to geoip before saving the customer rather than using their IP
  address with Stripe directly.
* Parallelization speeds up the conversion process significantly

This commit:

* Geocodes IP addresses prior to saving using fxa-geodb.
* Adds parallelization with rate limiting.
* Writes results to output CSV.

Closes FXA-6581
Closes FXA-6810
2023-02-28 14:33:57 -08:00
dschom a620922422
task(CI): build, unit test, and integration test jobs
Because:
- We wanted to run a few preliminary checks before proceeding to more
  expensive CI jobs. Checks include:
    - Compiling typescript in commonly referenced workspace packages
    - Linting code that has changed
    - Executing Unit Tests for code that has changed
- We wanted to partition test operations into unit tests, and
   integration tests. Unit tests can be run relatively quickly and
   require no additional infrastructure. Integration tests require
   additional infrastructure and generally have longer execution
   times. Now that jobs are blocked from running until preliminary
   checks pass, one of which is unit tests, it is important to draw a
   distinction between these two types of tests.
- We want to avoid unnecessary yarn installs and typescript
  compilations, which are time consuming.
- We want to make sure that test results are published and failing tests
   can be easily viewed in the CI.

This Commit:

- Creates a build-and-validate job in the CI that builds, lints, and
  unit tests code prior to running any other jobs.
- Creates unit-test job in CI config
- Creates integration-test job in CI config
- Removes redundant calls to compile workspace packages. These
  are now built up front, cached, and restored as needed for future
  runs.
- Extends the create-lists script functionality to generate commands
  that can be executed with the parallel command.
- Removes unnecessary yarn install operations. Invoking yarn workspace
   focus results in a yarn install. In the case of running tests this is largely
   unnecessary, because we already do a yarn install in the base-install
   step.
- Make sure test results are exported as junit xml so the CI can report
  back on tests that were failing. This was done for a couple workspace
  packages, but many were lacking the capability. All test:unit and
  test:integration npm scripts now export this data.
- Fixes the following issues encountered along the way:
        - Adds logs to monitor heap usage of jest tests. Some
          jest tests are still using a lot of memory.
        - Moves a few slow / long running tests from unit test to
          integration tests.
        - Ensures that jest.transform for ts-jest is always instructed
           to have the config option isolateModules is set to true. This
           definitely decreases memory overhead and resolves some
           of the OOM errors we were hitting. It was configured in
           some places but not everywhere.
        - Exports test results files for all tests
        - Exports all test artifacts
        - Uses gnu parallel to run tests in parallel. Turns out yarn
          workspaces foreach would give a false positive when an OOM
          was encountered. Fortunately, the parallel command offered an
          acceptable work around, and even offers some nice features
          like the load argument, which allows to control test execution a
          bit more efficiently.
2023-01-10 12:52:01 -08:00
dschom acf3c82590
task(ci): Use docker base image
Because:
- We want to speed up pipeline startup.

This Commit:
- Optimizes docker base image builds for the smallest images possible.
- Enables hard links for yarn cache
- Enables global yarn cache
- Avoids needlessly installing playwright browsers.
- Avoids needlessly running yarn install.
- Uses mozilla/fxa-circleci:ci-base-latest image for running test pipelines
- Uses mozilla/fxa-circleci:ci-base-browsers image for running functional tests pipelines
- Creates configurable executors that can be reused across pipelines
- Upgrades to yarn 3.3.0
- Enabled direct check out of PR code to test, which is faster than circle ci’s checkout command.
- Upgrades functional test to X-Large. This was already the case for playwright tests, but is now extended to content server tests too. This decision was made due to running lots of pipelines and realizing flakiness was largely due to CPU or memory hitting 100% for long periods of time.
- Turns off tracing, since it saves a bit of runtime.
2022-12-15 15:48:16 -08:00
Barry Chen 95cded6e96
chore(typescript): convert more of fxa-shared to TS
Because:
 - there were some JS in fxa-shared in fxa-shared that can be converted
   to TS

This commit:
 - convert some shared JS to TS
2022-11-30 17:31:23 -06:00
Barry Chen 303be33e66
Merge pull request #14485 from mozilla/deps-elliptic
chore(deps): update elliptic
2022-11-17 10:36:59 -06:00
Barry Chen c5c059da59
Merge pull request #14479 from mozilla/deps-node-forge
chore(deps): resolve node-forge to >=1.3.0
2022-11-16 16:59:33 -06:00
Barry Chen b4ec5deb53
chore(deps): update elliptic
Because:
 - elliptic is in the browserid-verifier's dependency tree and it's
   causing security warnings

This commit:
 - resolve elliptic to >= a patched version
2022-11-16 15:29:33 -06:00
dependabot[bot] 14aa97ff94
chore(deps): bump node-fetch from 2.6.1 to 2.6.7
Bumps [node-fetch](https://github.com/node-fetch/node-fetch) from 2.6.1 to 2.6.7.
- [Release notes](https://github.com/node-fetch/node-fetch/releases)
- [Commits](https://github.com/node-fetch/node-fetch/compare/v2.6.1...v2.6.7)

---
updated-dependencies:
- dependency-name: node-fetch
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-11-16 20:16:42 +00:00
Barry Chen 614cbfd774
chore(deps): resolve node-forge to >=1.3.0
Because:
 - security alerts

This commit:
 - resolve node-forge to >= the min fixed version
2022-11-16 12:49:54 -06:00
Barry Chen 5212eb6332
chore(deps): resolve to a newer version of plist
Because:
 - xmldom was a dependency of plist, which is a dependency of
   i18n-abide, and xmldom was causing a security alert

This commit:
 - resolve plist to a newer version that does not have the xmldom dep
2022-11-15 15:27:41 -06:00
Barry Chen cf2d25733e
chore(deps): resolve to newer versions of terser
Because:
 - older versions of terser are causing security alerts

This commit:
 - resolve terser to patched versions
2022-11-15 15:11:29 -06:00
Barry Chen e32f03d04f
Merge pull request #14455 from mozilla/deps-underscore
chore(deps): resolve underscore to newer versions
2022-11-15 14:53:19 -06:00
Barry Chen 06ae2ed961
chore(dep): resolve protobufjs to a newer version
Because:
 - some older versions of protobufjs 6.x are causing a security alert

This issue:
 - resolve protobufjs 6.x to a fixed version or newer
2022-11-15 11:45:56 -06:00
Barry Chen d977ecaf58
chore(deps): resolve underscore to newer versions
Because:
 - older versions of underscore is causing security alerts

This commit:
 - resolve underscore to patched versions
2022-11-14 10:33:37 -06:00
Barry Chen cf5bc69d5c
chore(deps): resolve moment to a patched version
Because:
 - older versions of moment are causing security alerts

This commit:
 - resolve moment 2.x to a >= a patched version
2022-11-10 15:44:15 -06:00
Julian Poyourow 872626e663
Merge pull request #14391 from mozilla/FXA-6136
chore(auth-server): enable typescript-eslint
2022-11-04 13:32:25 -07:00
Julian Poyourow 76ef507b26
chore(auth-server): enable typescript-eslint
Because:

* We aren't currently linting TS files in auth-server

This commit:

* Enables and fixes linting issues in auth-server

Closes FXA-6136
2022-11-04 10:43:26 -07:00
Barry Chen 72cbb56d12
Merge pull request #14349 from mozilla/dependabot/npm_and_yarn/replace-in-file-6.3.5
chore(deps): bump replace-in-file from 6.1.0 to 6.3.5
2022-10-28 12:52:43 -05:00
dependabot[bot] 608a3edd35
chore(deps): bump eslint-plugin-jest from 24.5.2 to 27.1.3
Bumps [eslint-plugin-jest](https://github.com/jest-community/eslint-plugin-jest) from 24.5.2 to 27.1.3.
- [Release notes](https://github.com/jest-community/eslint-plugin-jest/releases)
- [Changelog](https://github.com/jest-community/eslint-plugin-jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/jest-community/eslint-plugin-jest/compare/v24.5.2...v27.1.3)

---
updated-dependencies:
- dependency-name: eslint-plugin-jest
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-10-28 06:37:48 +00:00
dependabot[bot] 1ebffd7e48
chore(deps): bump replace-in-file from 6.1.0 to 6.3.5
Bumps [replace-in-file](https://github.com/adamreisnz/replace-in-file) from 6.1.0 to 6.3.5.
- [Release notes](https://github.com/adamreisnz/replace-in-file/releases)
- [Changelog](https://github.com/adamreisnz/replace-in-file/blob/main/CHANGELOG.md)
- [Commits](https://github.com/adamreisnz/replace-in-file/compare/v6.1.0...v6.3.5)

---
updated-dependencies:
- dependency-name: replace-in-file
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-10-27 15:46:30 +00:00
Vijay Budhram 6941fd4d64
Merge pull request #14341 from mozilla/dependabot/npm_and_yarn/stylelint-config-recommended-scss-8.0.0
chore(deps-dev): bump stylelint-config-recommended-scss from 7.0.0 to 8.0.0
2022-10-27 11:30:45 -04:00
dependabot[bot] 601231d67b
chore(deps): bump pm2 from 5.1.2 to 5.2.2
Bumps [pm2](https://github.com/Unitech/pm2) from 5.1.2 to 5.2.2.
- [Release notes](https://github.com/Unitech/pm2/releases)
- [Changelog](https://github.com/Unitech/pm2/blob/master/CHANGELOG.md)
- [Commits](https://github.com/Unitech/pm2/compare/5.1.2...5.2.2)

---
updated-dependencies:
- dependency-name: pm2
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-10-26 16:10:38 +00:00
dependabot[bot] 5a2870d716
chore(deps-dev): bump stylelint-config-recommended-scss
Bumps [stylelint-config-recommended-scss](https://github.com/stylelint-scss/stylelint-config-recommended-scss) from 7.0.0 to 8.0.0.
- [Release notes](https://github.com/stylelint-scss/stylelint-config-recommended-scss/releases)
- [Changelog](https://github.com/stylelint-scss/stylelint-config-recommended-scss/blob/master/CHANGELOG.md)
- [Commits](https://github.com/stylelint-scss/stylelint-config-recommended-scss/compare/v7.0.0...v8.0.0)

---
updated-dependencies:
- dependency-name: stylelint-config-recommended-scss
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-10-26 14:30:05 +00:00
dependabot[bot] 1941c2717d
chore(deps-dev): bump stylelint from 14.13.0 to 14.14.0
Bumps [stylelint](https://github.com/stylelint/stylelint) from 14.13.0 to 14.14.0.
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/14.13.0...14.14.0)

---
updated-dependencies:
- dependency-name: stylelint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-10-26 06:23:38 +00:00
dependabot[bot] 7813e96e22
chore(deps-dev): bump stylelint-config-recommended-scss
Bumps [stylelint-config-recommended-scss](https://github.com/stylelint-scss/stylelint-config-recommended-scss) from 6.0.0 to 7.0.0.
- [Release notes](https://github.com/stylelint-scss/stylelint-config-recommended-scss/releases)
- [Changelog](https://github.com/stylelint-scss/stylelint-config-recommended-scss/blob/master/CHANGELOG.md)
- [Commits](https://github.com/stylelint-scss/stylelint-config-recommended-scss/compare/v6.0.0...v7.0.0)

---
updated-dependencies:
- dependency-name: stylelint-config-recommended-scss
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-10-19 17:34:54 +00:00
dependabot[bot] 2c5219014e
chore(deps-dev): bump eslint-plugin-react from 7.26.1 to 7.31.10
Bumps [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) from 7.26.1 to 7.31.10.
- [Release notes](https://github.com/jsx-eslint/eslint-plugin-react/releases)
- [Changelog](https://github.com/jsx-eslint/eslint-plugin-react/blob/master/CHANGELOG.md)
- [Commits](https://github.com/jsx-eslint/eslint-plugin-react/compare/v7.26.1...v7.31.10)

---
updated-dependencies:
- dependency-name: eslint-plugin-react
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-10-18 06:17:22 +00:00
dependabot[bot] 25d21468ef
chore(deps): bump lint-staged from 10.2.11 to 13.0.3
Bumps [lint-staged](https://github.com/okonet/lint-staged) from 10.2.11 to 13.0.3.
- [Release notes](https://github.com/okonet/lint-staged/releases)
- [Commits](https://github.com/okonet/lint-staged/compare/v10.2.11...v13.0.3)

---
updated-dependencies:
- dependency-name: lint-staged
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-10-14 14:12:23 +00:00
dependabot[bot] cc2621d804
chore(deps-dev): bump stylelint from 14.9.1 to 14.13.0
Bumps [stylelint](https://github.com/stylelint/stylelint) from 14.9.1 to 14.13.0.
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/14.9.1...14.13.0)

---
updated-dependencies:
- dependency-name: stylelint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-10-14 06:14:00 +00:00
dependabot[bot] 98f1a3dda6
chore(deps-dev): bump stylelint-config-prettier from 8.0.2 to 9.0.3
Bumps [stylelint-config-prettier](https://github.com/prettier/stylelint-config-prettier) from 8.0.2 to 9.0.3.
- [Release notes](https://github.com/prettier/stylelint-config-prettier/releases)
- [Commits](https://github.com/prettier/stylelint-config-prettier/compare/v8.0.2...v9.0.3)

---
updated-dependencies:
- dependency-name: stylelint-config-prettier
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-10-12 06:23:29 +00:00
Vijay Budhram df857c569d
feat(emails): Send `New Device Login` email on all new logins 2022-09-08 12:26:46 -04:00
dschom f14a2dc923
task(auth): Enable open telemetry on auth server
Because:
- We want to be able to see trace information
- We want to be able to export trace information to google cloud

This Commit:
- Adds utility class to fxa-shared for configuring and initializing open telemetry
- Initializes open telemetry in the auth server
- Forces resolution of google-gax.
- Forces resolution of @grpc/grpc-js.
- Adds the jaeger docker container for viewing traces locally. This is accessible on localhost:16686.

Note, adding @google-cloud/opentelemetry-cloud-trace-exporter resulted
in a version conflicts for google-gax and @grpc/grpc-js, which caused
runtime failures when interacting with @google-cloud/firestore. After
many experiments, this seems to do the trick.
2022-09-02 17:54:41 -07:00
Vijay Budhram 8d8718b207
feat(pair): test 2022-08-30 15:33:52 -04:00
Peter deHaan e6f74e0936
fix(lint): Add more stylelint rules 2022-06-17 13:19:38 -07:00
Bianca Danforth ddba42afd4
chore(all): run TS compiler as part of test-many job
Because:

* We should be informed about TS errors before a patch merges into main.

This commit:

* Adds a new script to run as the first task in the test-many job that compiles any modified back-end Typescript packages and any packages that depend on them.

Closes #12823

Co-authored-by: Barry Chen <bchen@mozilla.com>
2022-06-15 08:11:16 -04:00
Ben Bangert 81afc1a7db
Revert "chore(deps): Upgrade lodash" 2022-05-25 17:36:45 -07:00
Lauren Zugai 6319e4346d
chore(deps): Upgrade lodash
Because:
* Lodash needs an update

This commit:
* Updates lodash via resolutions
2022-05-23 16:22:44 -05:00
Barry Chen 05fe82a890
chore(yarn): fix yarn ports
Because:
 - `yarn ports` was not working

This commit:
 - get `yarn ports` working
2022-04-21 08:47:21 -05:00
Barry Chen f4414856a2
Revert "Merge pull request #12403 from mozilla/fxa-4698-paypal-lock"
This reverts commit 0fd7eccf94, reversing
changes made to 599c83212a.
2022-04-19 10:52:21 -05:00
Wil Clouser 10ca4d46b6
chore(deps): Revert lodash upgrade 2022-04-12 08:52:26 -07:00
Wil Clouser 5b7ddbb0f2
chore(deps): force upgrade url-parse 2022-04-12 07:56:46 -07:00
Wil Clouser 938bc16e3c
chore(deps): force upgrade lodash 2022-04-12 07:35:42 -07:00
Wil Clouser 25cc0872ef
chore(deps): force upgrade minimist 2022-04-11 15:37:28 -07:00
Barry Chen 8efb6aec89
feat(scripts): use redlock to prevent >1 instance of paypal-processor
Because:
 - we could easily end up running two instances of the paypal-processor
   during a deploy

This commit:
 - use a redis based distributed lock to ensure only one
   paypal-processor can run per env
 - add script options to control the lock name and duration, as well as
   completely bypassing the lock
2022-04-07 16:57:21 -05:00
Vijay Budhram 829025b129
fix(metrics): Attempt to fix login complete events for mobile (#12090)
* fix(metrics): Attempt to fix login complete for mobile

* chore(deps): updated yarn.lock

Co-authored-by: fxa-bananafox[bot] <70546514+fxa-bananafox[bot]@users.noreply.github.com>
2022-03-10 09:41:08 -05:00
Vijay Budhram c1f0a3682a
chore(deps): switch from git to https for deps (#11587)
* chore(deps): switch from git to https for deps

See https://github.blog/2021-09-01-improving-git-protocol-security-github/

* fix(git): Use `https://` instead of `git://` for packages

Co-authored-by: Barry Chen <bchen@mozilla.com>
2022-01-11 12:21:56 -05:00
Danny Coates 5bfb78b0ab
chore(deps): update yarn to 3.1.1 2021-12-22 15:35:47 -08:00
Danny Coates a62532cc50
chore(ci): slow down pm2 startup (#11084)
* feat(cli): add 'yarn delete services' command

sometimes you may want to leave all your DBs running but completely start over with fresh services. The pm2 restart command doesn't fully reset the environment and sometimes that's what you want. Delete lets us remove the service from pm2 so we can start it fresh.

* chore(ci): slow down pm2 startup

I've noticed ci failures where the services don't even get started up completely happening more frequently. During the brief time that circleci showed resource graphs the pm2 startup pegged both cpu and memory. If we wait for the services that have a lot of building at startup to finish before starting the next service maybe we'll have better stability.

* chore(tests): remove support-panel from functional test startup
2021-11-19 11:52:33 -08:00
Danny Coates 60ca05cb81
chore(deps): update typescript to 4.5.2
* refactor(ts): use builtin Awaited type

* maybe make tests more stable
2021-11-18 23:25:28 -08:00
Danny Coates c72a1a0032
chore(deps): Update yarn to 3.1.0 and dedupe deps. fix resolve conflicts (#11072)
chore(deps): updated yarn to 3.1.0

chore(deps): need to be explicit about postcss deps now, apparently

chore(deps): update yarn relock to skip adding checksums for conditional deps

This matches the default behavior of yarn 3.1

danny hates storybook

update yarn workspace plugin
2021-11-18 17:58:42 -08:00
Danny Coates fbd4a4bed9
chore(ci): update modules-to-test.js to use the workspace:* dependencies to make it easier to keep up to date 2021-11-16 16:46:14 -08:00
Danny Coates 17e06a38d2
chore(node): upgrade to node 16 (#10799) 2021-10-22 16:10:22 -07:00
Danny Coates a95f1270af
refactor(build): use esbuild instead of ts-node (#10639) 2021-10-07 09:57:36 -07:00
Danny Coates f57031d152
chore(deps): updated dependencies (#10638) 2021-10-06 15:38:39 -07:00
Bianca Danforth e476c550c5
docs(db): update root README on how to connect to local FxA MySQL DBs (#10603)
Because:

* We should document the basic process for new contributors.

This commit:

* Adds a new "Connecting to a local MySQL DB" section to the root project README.

Closes #No issue
2021-10-05 19:16:28 -04:00
Danny Coates 89e549a742
chore(deps): update pm2; dedupe (#10557) 2021-09-29 14:01:10 -07:00
Vijay Budhram bbc0a12814
chore(tests): add fxa-graphql-api as test dep for fxa-settings 2021-08-03 11:19:23 -04:00
Danny Coates b8a6bd51c6
chore(deps): updated yarn to 3.0 and typescript to 4.3.5 2021-07-28 10:41:27 -07:00
Danny Coates 694ff5f6af
chore(deps): update deps and start ignoring @types/* in dependabot 2021-06-23 08:11:07 -07:00
Danny Coates 5d7653fa60
chore(deps): update pm2 / dedupe 2021-06-14 10:12:10 -07:00
Danny Coates fa895572ce
chore(deps): updated some deps 2021-06-08 14:03:22 -07:00
Danny Coates 34704ba146
chore(deps): updated pm2 2021-06-08 13:54:51 -07:00
Danny Coates 0c65675bfd
chore(admin): remove unnecessary columns from admin panel queries 2021-06-03 15:07:04 -07:00
Danny Coates 6fce48032b
chore(deps): update some deps 2021-05-24 14:42:33 -07:00
Danny Coates 952e4f3885
chore(deps): added "yarn outdated" plugin + updated some deps 2021-05-24 12:44:48 -07:00
Danny Coates badc0a8152
chore(deps): updated json 2021-05-24 11:44:40 -07:00
Danny Coates 2e9ff2e14d
chore(deps): update typescript to v4 2021-05-06 14:44:40 -07:00
Vijay Budhram 707d542131
Merge pull request #8476 from mozilla/heroku, r=@dannycoates
Update 123Done and add support for heroku
2021-05-05 11:09:45 -04:00
Vijay Budhram 3416b9a791
feat(heroku): adds support for heroku and 123done 2021-05-04 16:47:46 -04:00
Danny Coates 0847e25457
chore(deps): updated pm2 2021-05-03 11:12:40 -07:00
Vijay Budhram c3a9fc3275
fix(tests): Make fxa-settings and fxa-content-server tests dependent on each 2021-04-12 16:36:04 -04:00
Danny Coates 7cf502be2f
chore(deps): update eslint to v7 2021-01-08 11:45:40 -08:00
Danny Coates 15d97daa3c
chore(deps): fixed low severity vuln in node-fetch 2021-01-05 14:01:41 -08:00
Danny Coates 594c39ac15
chore(deps): update minimum node version to 14.15.1 2020-11-17 11:05:41 -08:00
Danny Coates 6c2b253c11
chore(deps): update node version to 14 2020-10-27 10:21:05 -07:00
Dave Justice a8cc232b9a
task(monorepo): move deps to correct sub-packages
this is fixing a goof from 05a00a0aee
- fixes #6433
2020-09-17 18:33:06 +00:00
Ben Bangert a9cf3836bb
feat(fxa-shared): refactor nestjs shared modules
Because:

* We want to re-use NestJS modules in multiple packages.

This commit:

* Refactors common NestJS modules from event-broker into fxa-shred
  for use by other packages.

Closes #6345
2020-09-15 08:07:43 -07:00
Dave Justice 047c96ea58
task(monorepo): update deps 9/9
- temp 0.9.0 => 0.9.1
- @types/helmet 0.0.45 => 0.0.48
- serve-static 1.13.1 => 1.14.1 in fxa-content-server
- extract-loader 2.0.1 => 5.1.0 in fxa-content-server

closes #6387 #6388 #6389 #6390
2020-09-09 14:59:38 +00:00
Dave Justice 05a00a0aee
task(monorepo): update deps 9/8
- sass 1.26.5 => 1.26.10
- @hapi/inert 6.0.1 => 6.0.2
- consolidate 0.14.5 => 0.15.1
- on-headers 1.0.1 => 1.0.2
- bl 1.1.2 => 4.0.3

closes #6324 #6323 #6325 #6326
2020-09-08 16:22:42 +00:00
Dave Justice b7d726cbfa
task(fxa): bump deps from open dependabot prs 2020-08-26 06:52:21 +00:00
Danny Coates da2e99729c
chore(deps): update yarn version and root level deps 2020-08-21 17:06:03 -07:00
Ben Bangert 245568d56c
chore: update typescript
Because:

* Using the latest everywhere helps with consistency and smaller build
  size.

This commit:

* Updates for TypeScript 3.9.7 everywhere in FxA.
2020-08-15 11:15:44 -07:00
Les Orchard dc77f5c3b8
fix(payments): add fxa-shared and fxa-react as CI dependencies for fxa-payments-server 2020-07-29 12:49:44 -04:00
Danny Coates 7358a3cae5
feat(auth-client): replace fxa-js-client with fxa-auth-client
- We have two clients for the auth-server API, one in `content-server/app/scripts/lib/auth` and `fxa-js-client`. The content-server one was meant to replace fxa-js-client but I didn't finish the work to get it running on nodejs.

- Extracts the content-server implementation into `fxa-auth-client`
- Wraps the implementation with shims to work with nodejs in `server.ts`
- Updates references to fxa-js-client to use fxa-auth-client
- Removes fxa-js-client
2020-07-21 09:08:35 -07:00
Danny Coates 10c230f041
fix(react): use package.json export
fixes #5577

Using the newish "exports" property of package.json allows
us to keep the source ts separate from the compiled js
and still use require('fxa-react/components/..'). No more
clean required to run jest tests.
2020-07-02 15:48:45 -07:00
Danny Coates 27cd24c63d
chore(deps): update deps 2020-06-29 10:18:16 -07:00
Danny Coates 3fa9529194
chore(deps): updated dependencies
chore(deps): updated aws-sdk

chore(deps): remove raven and update @sentry/*

chore(deps): updated mysql deps

chore(deps): updated eslint-plugin-fxa

chore(deps): updated bluebird

chore(deps): updated request

chore(deps): use jest 24.9.0 (same as react-scripts)

chore(deps): update convict

chore(deps): update morgan

chore(deps): update eslint-plugin-jest

chore(deps): update babel-eslint

chore(deps): removed nodemon

chore(deps): update @types/convict

chore(deps): set @types/jest to match jest version

chore(deps): set @babel/core to ^7.9.0

chore(deps): set @babel/preset-env to 7.9.0

chore(deps): update hapi
2020-06-22 17:11:50 -07:00
Danny Coates 99385e89a5
fix(auth): fixed test-local.sh in fxa-auth-server
with hoisted eslint dependency `npm run lint` can't find
eslint on the path. We've got linting globally as a precommit
hook, it doesn't need to run on tests.
2020-06-01 14:10:43 -07:00
Danny Coates e6f60d2880
feat(dev): added post-checkout/merge git hooks to keep deps in sync
It's easy to not notice when to run a `yarn install` either
when switching branches or doing a git pull. This adds a
hook to diff your previous yarn.lock with the one your changing
to, and if there's changes running 'yarn install' for you.
2020-05-26 16:13:14 -07:00
Danny Coates fec460f6db
chore(deps): update some dependencies 2020-05-26 14:08:34 -07:00
Danny Coates cc595fc2b4
chore(format): mass reformat with prettier 2 and single config 2020-05-24 10:51:57 -07:00
Jody Heavener 9e1104c05e
refactor(lint-staged): replace sass-lint with stylelint
remove sass-lint from all packages
2020-05-21 21:25:48 -04:00
Danny Coates 81575019a9
refactor(packages): use workspace references 2020-05-21 10:57:21 -07:00
Vijay Budhram 0a86806a3a
feat(qr): Add CAD via QR code UX 2020-05-11 17:59:32 -04:00
johngruen 2dcf49e8d1
chore(subscriptions): make fortress an upgradable sub 2020-05-07 17:59:44 -05:00
Jody Heavener 7ee5f5fae7
feat(settings): set up some foundational configs and components 2020-04-30 12:06:46 -04:00
Danny Coates d4da8a3606
feat(docker): created fxa-builder docker image
This adds a base node image and builder image so
that all our service images can share the same
common base, be smaller, and require less customization.
2020-04-22 16:27:22 -07:00
Jackie Munroe a0d64226f4
feat(payments): localization updates
- updated fluent packages to the latest
- implemented localizable currency
- implemented localizable dates

fixes #4668

- fixed errors that resulted from rebase onto Mobile Updates

- fixed bug that would cause the subscriptionToResponse to provide an invoice ID instead of an invoice Number

- removed reference to plan name and replaced with product name

- changed variables to regular stringsOC

- added stricter typing to plan interval
2020-04-16 13:34:10 -04:00
Danny Coates 3a054dfc3f
refactor(pm2): restructure our pm2 configs
why: several reasons...

- to have a unified approach and pattern for:
  - debugging
  - fs watching for local dev
  - running services in dev
  - configuring services in dev

- to improve the initial clone and subsequent `npm ci` experience
- to make future work on tooling easier
2020-04-14 14:38:38 -07:00
Danny Coates a4b3996349
refactor(npm-scripts): refactored npm scripts for better ergonomics
1. renamed _scripts/*.sh to use kebab-case
2. linted _scripts with shellcheck
3. added _dev directory and moved pm2 json files there
4. added nps and package-scripts.js
  - this allows us to do nice things like: `npm start debug firefox`
  - I'd like to expand this further but it's a start
5. refactored the install scripts to make `npm install` nicer
6. renamed pm2 process names for easier control
  - can use `pm2 logs auth` instead of the id
2020-04-13 16:17:36 -07:00
Jody Heavener 35af352758
chore(audit): only audit once per day 2020-04-13 15:45:34 -04:00
Danny Coates 37a42e721f
chore(tests): made root level "npm test" more functional 2020-04-08 15:58:16 -07:00
Danny Coates 7f60ef5769
chore(deps): update top-level dependencies
start-android is no longer needed so it was removed
along with its dependencies and replaced by adb-reverse

I removed `adr-log` in favor of running `npx adr-log` to
make `npm ci` smaller.

`concurrently` is no longer used.

The remainder were updated to their latest versions.
2020-03-12 14:01:59 -07:00
Ben Bangert d5fa1d9968
Merge pull request #4399 from mozilla/auth-server-build-fix
fix(auth-server): update default node version for hapi upgrade
2020-03-10 08:14:33 -07:00
Barry Chen f88ac80984
fix(tests): fix customs server test runner script and tests
This patch fixes two things in Customs tests:
 - it updates test-local.sh so that it no longer exits with status 0 all
 the time; now it exits with the status returned by `tap`
 - it fixes all the failing tests that have gone unnoticed due the bug
 mentioned above
2020-03-10 09:11:22 -05:00
Dave Justice 0f2d540716
fix(monorepo): update default node version across packages 2020-03-06 22:54:44 +00:00
Jody Heavener d01b175c44
chore(services): check for and warn about ports in use that the servers require 2020-03-04 17:42:19 -05:00
Renovate Bot 4d998fce34
chore(deps): update dependency concurrently to v5.1.0 2020-02-06 17:37:35 -05:00
Danny Coates f44a50f6b9
refactor(key_server): cleanup key_server.js
- removed obsolete code
- reordered requires to be closer to use
- removed remaining `then`s
2020-01-14 12:41:31 -08:00
Danny Coates ae3bd5a0ff
feat(totp): Require recovery code confirmation before enabling TOTP 2020-01-02 12:50:34 -08:00
Dave Justice 162a8ca8bb
fix(profile-server): fix graphicsmagick dep in dockerfile
- fixes #3754
2019-12-27 17:05:05 +00:00
Les Orchard 104dca378b
fix(payments): add payments-server as a module dependency for content-server
changes to payments-server can break content-server tests, so we should
trigger content-server tests too
2019-12-17 13:10:13 -05:00
Danny Coates ccd3c2b07e
feat(audit): run npm audit on push instead of in ci
It's pretty disheartening when your PR fails in ci because of an
npm advisory unrelated to your changes. We still need to be aware
of them but have the ability to more easily keep doing other work.

Running the audit on git push allows us all to see advisories
quickly, but allows us to override and push with --no-verify so
work can continue and the advisory addressed on its own.
2019-11-19 12:02:22 -08:00
Jared Hirsch 1b0141e2b3
chore(deps): Get audit-filter working for all packages in monorepo
* Add a lint:deps job to the top-level package.json, so lerna can run
  lint:deps in all packages in parallel.

* Also handle recent handlebars vulnerability, so that builds don't fail.

* Note, the lint:deps job is a no-op in fxa-amplitude-send, as I can't
  get it to build yet in the monorepo.

Some of the vulnerabilities are in transitive dependencies, yet the
suggested `npm update foo --depth N` command sometimes seems to do
nothing. There was a related bug in npm 6.6.0 - 6.11.2, fixed by
https://github.com/npm/cli/pull/239, but perhaps that didn't fix all the
cases? (I was using npm 6.12.0.) As a workaround, I've added audit-filter
exceptions where `npm update` wasn't able to fix vulnerabilities.

Fixes #2229.
2019-11-18 12:05:32 -08:00
Dave Justice 0a5e3950f8
task(monorepo): eslint consolidation
- fixes #3082
- remove grunt when can be replaced with only eslint
- update to new eslint config using prettier rules
- fix linting errors
2019-11-15 23:24:09 +00:00
Ben Bangert 107d46ed86
refactor(support-panel): update deps, cleanup
Because:

* My JS skills were a bit more newbie when I wrote some of this the
  first time leading to some copypasta.
* Optional chaining in Typescript 3.7 is slick.
* esModuleInterop has cleaner imports and is recommended.
* We are removing the use of Bluebird everywhere.

This commit:

* Removes some copypasta for more standard JS idioms.
* Updates all the dependencies as well as TypeScript -> 3.7.
* Refactors imports to use esModuleInterop.
* Drops the Bluebird dependency.
2019-11-11 11:41:47 -08:00
Danny Coates 8f3b2627d5
refactor(build): disable npm install by default on fxa-amplitude-send
- fxa-amplitude-send has a dependency on node-parquet which has several unaccounted for native deps that currently break npm install locally
- node-parquet adds several minutes to the CI build time which is not currently required
- refactored script vars to be more explicit about their purpose

see #3231
2019-11-05 10:30:42 -08:00
Danny Coates 95c6eba2c8
fix(build): slow-roll npm ci on circle 2019-11-01 14:28:44 -07:00
Danny Coates 7d222da260
fix(build): go back to `concurrently` for `install_packages.sh`. too many errors with lerna 2019-10-31 11:07:46 -07:00
Danny Coates d7e1ae46b2
fix(build): try --parallel on lerna npm-ci-all 2019-10-30 21:54:08 -07:00
Danny Coates 53e07b6c4a
chore(import): added fxa-dev-launcher to monorepo 2019-10-29 08:42:28 -07:00
Danny Coates 3c3a888a84
refactor(build): some random dev build changes 2019-10-28 17:27:35 -07:00
Danny Coates 867b713b4f
chore(npm): changed 'npm start' to run 'pm2 start mysql_servers.json' 2019-10-10 13:41:00 -07:00
Danny Coates 173ed58d77
fix(build): add tsx to lint-staged 2019-10-02 09:23:15 -07:00
Barry Chen fda7d1f5b6
feat(metrics): collect perf metrics with StatsD on auth server's HTTP API clients 2019-09-25 09:50:47 -05:00
Jared Hirsch ed541793b6
chore(deps): monorepo top-level npm audit changes
* Update lerna, pm2

* Fix vulnerabilities in transitive dependencies via npm audit fix
2019-09-06 15:08:26 -07:00
dave justice 2ffe1334df
feat(fortress): add "fortress" relying party
- fixes #1894
2019-08-26 15:26:59 -04:00
Phil Booth 7e69761f05
chore(hooks): turn on prettier hook for typescript 2019-08-16 12:10:44 +01:00
Ben Bangert 45b304acb3
feat: reduce build time for fxa-email-service 2019-07-23 17:27:49 -07:00
Phil Booth b16ab0fdf8
chore(tests): run content server tests when 123done changes 2019-07-18 06:55:54 +01:00