-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: move away from deno and back to yarn
- Loading branch information
1 parent
baf1085
commit f8d9e7d
Showing
13 changed files
with
2,209 additions
and
202 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,6 @@ | ||
const { process } = require("node:process"); | ||
|
||
module.exports = { | ||
root: true, | ||
env: { | ||
node: true, | ||
mocha: true, | ||
}, | ||
plugins: [ | ||
"chai-friendly", | ||
"import", | ||
], | ||
extends: [ | ||
"airbnb-typescript/base", | ||
"plugin:chai-expect/recommended", | ||
"@gewis/eslint-config", | ||
], | ||
rules: { | ||
"no-console": process.env.NODE_ENV === "production" ? "error" : "off", | ||
"no-debugger": process.env.NODE_ENV === "production" ? "error" : "off", | ||
"linebreak-style": process.env.NODE_ENV === "production" | ||
? ["error", "windows"] | ||
: ["off", "windows"], | ||
"@typescript-eslint/no-empty-function": ["error", { | ||
allow: ["constructors"], | ||
}], | ||
"@typescript-eslint/no-unused-expressions": "off", | ||
"chai-friendly/no-unused-expressions": "error", | ||
"@typescript-eslint/no-floating-promises": "error", | ||
"@typescript-eslint/await-thenable": "warn", | ||
"class-methods-use-this": "off", | ||
}, | ||
parserOptions: { | ||
project: "./tsconfig.json", | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,20 @@ | ||
FROM denoland/deno:alpine | ||
FROM node:alpine AS builder | ||
|
||
WORKDIR /app | ||
|
||
COPY . . | ||
COPY package.json yarn.lock ./ | ||
|
||
# Install any dependencies (if applicable) | ||
RUN deno cache --unstable --lock=lock.json main.ts | ||
RUN yarn install --frozen-lockfile | ||
|
||
# Copy the cron job definition | ||
COPY ./cronjob /etc/crontabs/root | ||
|
||
FROM node:alpine | ||
|
||
WORKDIR /app | ||
|
||
COPY --from=builder /app/node_modules ./node_modules | ||
COPY package.json yarn.lock ./ | ||
COPY . . | ||
|
||
COPY ./cronjob /etc/crontabs/root | ||
|
||
CMD ["sh", "-c", "crond && tail -f /dev/null"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,37 @@ | ||
{ | ||
"devDependencies": { | ||
"name": "plankapi", | ||
"version": "0.0.0", | ||
"description": "Planka API service", | ||
"main": "src/index.ts", | ||
"scripts": { | ||
"start": "ts-node src/index.ts", | ||
"start:env": "ts-node -r dotenv/config src/index.ts", | ||
"build": "tsc", | ||
"lint": "eslint . --ext .vue,.js,.jsx,.mjs,.ts,.tsx,.cts,.mts,.json --ignore-path .gitignore", | ||
"lint:fix": "eslint . --fix --ext .vue,.js,.jsx,.mjs,.ts,.tsx,.cts,.mts,.json --ignore-path .gitignore" | ||
}, | ||
"dependencies": { | ||
"@gewis/planka-client": "github:GEWIS/planka-client#3bb88c2a8d86a9ba8f4fccf0a70e534047c6f88c", | ||
"@hey-api/client-fetch": "^0.4.2", | ||
"imapflow": "^1.0.164" | ||
}, | ||
"packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e" | ||
"devDependencies": { | ||
"@gewis/eslint-config": "https://github.com/GEWIS/eslint-config", | ||
"@types/imapflow": "^1.0.19", | ||
"@types/node": "^22.7.9", | ||
"dotenv": "^16.0.0", | ||
"ts-node": "^10.9.2", | ||
"typescript": "^5.2.2" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/GEWIS/plankapi.git" | ||
}, | ||
"author": "GEWIS GEFLITST", | ||
"license": "ISC", | ||
"bugs": { | ||
"url": "https://github.com/GEWIS/plankapi/issues" | ||
}, | ||
"homepage": "https://github.com/GEWIS/plankapi#readme", | ||
"packageManager": "yarn@1.22.22" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.