Skip to content

Commit 762d676

Browse files
feat(AP-7985): API v2 support & modernized tech stack (#22)
1 parent 515d6f0 commit 762d676

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

74 files changed

+15460
-23336
lines changed

.env.test

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
NODE_ENV=production
2+
APP_NAME=app
3+
CLUSTER=conn
4+
GIT_REPO_NAME="ce-connector-ditto"
5+
GIT_BASE_BRANCH=main
6+
HOST_APP_PORT=3000
7+
HOST_PRIVATE_APP_PORT=9080
8+
9+
# app
10+
APP_VERSION=1
11+
GIT_COMMIT_SHA=sha
12+
APP_PORT=3000
13+
APP_BIND_ADDRESS=0.0.0.0
14+
APP_ENV=production
15+
LOG_LEVEL=info
16+
API_ADDRESS_DITTO=https://api.dittowords.com
17+
18+
# new relic
19+
NEW_RELIC_LICENSE_KEY=
20+
NEW_RELIC_LOG_ENABLED=1
21+
NEW_RELIC_LOG_LEVEL=info
22+
NEW_RELIC_LOG=stdout
23+
NEW_RELIC_APP_NAME="live conn-ditto lok-cteng-conn-ditto.live.lokalise.cloud"
24+
NEW_RELIC_ENABLED=false
25+
NEW_RELIC_NO_CONFIG_FILE=true
26+
27+
# bugsnag
28+
BUGSNAG_KEY=
29+
BUGSNAG_ENABLED=false

.eslintignore

Lines changed: 0 additions & 4 deletions
This file was deleted.

.eslintrc.json

Lines changed: 0 additions & 58 deletions
This file was deleted.

.nvmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
22

.prettierrc.json

Lines changed: 0 additions & 9 deletions
This file was deleted.

Dockerfile

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# ---- Base Node ----
2-
FROM node:22.13.1-bookworm-slim as base
2+
FROM node:22.19.0-bookworm-slim AS base
33

44
RUN set -ex;\
55
apt-get update -y; \
@@ -16,14 +16,14 @@ FROM base AS dependencies
1616
RUN set -ex; \
1717
apt-get update -y ; \
1818
apt-get install -y --no-install-recommends \
19-
ca-certificates \
20-
dumb-init \
21-
make \
22-
gcc \
23-
g++ \
24-
python3 \
25-
git \
26-
openssl
19+
ca-certificates \
20+
dumb-init \
21+
make \
22+
gcc \
23+
g++ \
24+
python3 \
25+
git \
26+
openssl
2727
COPY --chown=node:node ./package.json ./package.json
2828
COPY --chown=node:node ./package-lock.json ./package-lock.json
2929
USER node
@@ -37,13 +37,13 @@ RUN set -ex; \
3737
npm install --ignore-scripts
3838

3939
# ---- Build ----
40-
FROM dependencies as build
40+
FROM dependencies AS build
4141

4242
COPY --chown=node:node . .
4343
RUN npm run build
4444

4545
# ---- Release ----
46-
FROM base as release
46+
FROM base AS release
4747

4848
COPY --from=build /usr/bin/dumb-init /usr/bin/dumb-init
4949
COPY --chown=node:node --from=build /home/node/app/dist .
@@ -58,4 +58,4 @@ ENV NODE_ENV=production
5858
ENV NODE_PATH=.
5959

6060
USER node
61-
CMD [ "dumb-init", "node", "/home/node/app/src/server.js" ]
61+
CMD [ "dumb-init", "node", "--experimental-loader", "newrelic/esm-loader.mjs", "-r", "newrelic", "/home/node/app/server.js" ]

Dockerfile-dev

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM node:22.13.1-bookworm-slim
1+
FROM node:22.19.0-bookworm-slim
22

33
RUN set -ex;\
44
apt-get update -y; \

biome.json

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
{
2+
"$schema": "./node_modules/@biomejs/biome/configuration_schema.json",
3+
"extends": [
4+
"./node_modules/@lokalise/biome-config/configs/biome-base.jsonc",
5+
"./node_modules/@lokalise/biome-config/configs/biome-esm.jsonc"
6+
],
7+
"files": {
8+
"ignore": []
9+
},
10+
"linter": {
11+
"rules": {
12+
"correctness": {
13+
"noUnusedVariables": "off",
14+
"noUndeclaredVariables": "off"
15+
},
16+
"complexity": {
17+
"useLiteralKeys": "off"
18+
},
19+
"suspicious": {
20+
"noAssignInExpressions": "off",
21+
"noConsoleLog": "off",
22+
"noExportsInTest": "off"
23+
},
24+
"style": {
25+
"noParameterAssign": "off",
26+
"noDefaultExport": "off"
27+
},
28+
"performance": {
29+
"noBarrelFile": "off"
30+
}
31+
}
32+
}
33+
}

jest.config.json

Lines changed: 0 additions & 31 deletions
This file was deleted.

0 commit comments

Comments
 (0)