Skip to content
This repository has been archived by the owner on Apr 23, 2023. It is now read-only.

Commit

Permalink
in favour of making it perform better express was removed and certain…
Browse files Browse the repository at this point in the history
… libs were added
  • Loading branch information
sebasptsch committed Mar 8, 2022
1 parent 47c4628 commit 18a63be
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 1,591 deletions.
11 changes: 0 additions & 11 deletions .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,6 @@ steps:
- apt-get install openssl -y -qq
- yarn install --frozen-lockfile
- yarn build
- name: "Publish to NPM"
image: plugins/npm
settings:
username: sebasptsch
password:
from_secret: github_token
token:
from_secret: github_token
email:
from_secret: github_email
registry: "https://npm.pkg.github.com"
- name: Rebuild Cache
pull: if-not-exists
image: drillster/drone-volume-cache
Expand Down
8 changes: 4 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Deps
FROM node:16-alpine as base
WORKDIR /app
RUN apk update
RUN apk add python3 make gcc g++
RUN apk update --no-cache && apk add
RUN apk add --no-cache python3 make gcc g++
COPY package.json .
COPY prisma prisma
COPY yarn.lock .
Expand All @@ -26,7 +26,7 @@ ENV DATABASE_URL "file:/app/config/db.sqlite"
ARG DRONE_TAG
ENV VERSION=$DRONE_TAG
COPY --from=build /app/dist dist
RUN yarn install --production
RUN yarn install --production --link-duplicates
RUN yarn cache clean
# CMD yarn deploy && echo "Test" && yarn start
CMD ls dist && yarn deploy && npx prisma migrate deploy && yarn start
Expand All @@ -41,7 +41,7 @@ ARG DRONE_TAG
ENV VERSION=$DRONE_TAG
WORKDIR /app
COPY --from=build /app/dist dist
RUN yarn install --production
RUN yarn install --production --link-duplicates
RUN yarn cache clean
RUN adduser -H -D container
USER container
Expand Down
9 changes: 2 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,11 @@
"@discordjs/builders": "^0.12.0",
"@discordjs/rest": "^0.3.0",
"@prisma/client": "^3.10.0",
"apollo-server-core": "^3.6.3",
"apollo-server-express": "^3.6.3",
"bufferutil": "^4.0.6",
"discord-api-types": "^0.28.0",
"discord.js": "^13.3.1",
"dotenv": "^10.0.0",
"erlpack": "^0.1.4",
"express": "^4.17.3",
"fuse.js": "^6.5.3",
"graphql": "^16.3.0",
"lodash": "^4.17.21",
Expand All @@ -54,13 +51,11 @@
"build": "yarn build:tsup"
},
"devDependencies": {
"@swc/core": "^1.2.151",
"@types/lodash": "^4.14.178",
"@types/node": "^17.0.5",
"@types/romans": "^2.0.0",
"@types/signale": "^1.4.2",
"@swc/core": "^1.2.151",
"node-prune": "^1.0.2",
"nodemon": "^2.0.15",
"prettier": "^2.5.1",
"prettier-plugin-organize-imports": "^2.3.4",
"prisma": "^3.10.0",
Expand All @@ -70,4 +65,4 @@
"engines": {
"node": "^12.20.0 || ^14.13.1 || >=16.0.0"
}
}
}
3 changes: 0 additions & 3 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { Client, Intents } from "discord.js";
import dotenv from "dotenv";
import * as events from "./events/index";
import startExpress from "./server";
import { db } from "./utils/db";
import { logger } from "./utils/logger";
dotenv.config();
Expand Down Expand Up @@ -29,8 +28,6 @@ try {
}

client.login(process.env.TOKEN);

startExpress(client, db);
} catch (error) {
logger.error(error);
}
Expand Down
240 changes: 0 additions & 240 deletions src/server/index.ts

This file was deleted.

Loading

0 comments on commit 18a63be

Please sign in to comment.