Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
AlinaNova21 committed Feb 2, 2024
0 parents commit 40c0ffb
Show file tree
Hide file tree
Showing 15 changed files with 6,768 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
node_modules
.git
.gitignore
*.md
dist
screepsmod-*
test
driver
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
dist
.pnpm-store
test
driver
logs
node_modules
22 changes: 22 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
FROM node:18 as base
ENV PNPM_HOME="/pnpm"
ENV PATH="$PNPM_HOME:$PATH"
RUN corepack enable
COPY . /app
# RUN rm -rf /app/node_modules
WORKDIR /app

FROM base AS prod-deps
RUN --mount=type=cache,id=pnpm,target=/pnpm/store pnpm install --prod --frozen-lockfile --shamefully-hoist

FROM base AS build
RUN --mount=type=cache,id=pnpm,target=/pnpm/store pnpm install --frozen-lockfile --shamefully-hoist
RUN pnpm run build

FROM base
COPY --from=prod-deps /app/node_modules /app/node_modules
COPY --from=build /app/dist /app/dist
EXPOSE 21025
VOLUME /screeps
WORKDIR /screeps
CMD ["node","/app/dist/app.js"]
16 changes: 16 additions & 0 deletions config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
steamKey: E6B8BA48A1290CE6B96E5300D2623393
processors: 1
serverConfig:
map: random_1x1
startAfterImport: true
tickRate: 1000
mods:
- screepsmod-mongo
- screepsmod-auth
- screepsmod-admin-utils
modules:
backend: false
main: false
processor: false
runner: true
storage: false
21 changes: 21 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
version: '3'
services:
mongo:
image: mongo
ports:
- 21027:21027
redis:
image: redis
ports:
- 6379:6379
screeps:
image: screepers/screeps-launcher-node
build: .
environment:
REDIS_HOST: redis
MONGO_HOST: mongo
volumes:
- ./test:/screeps
ports:
- 21025:21025

Empty file added jobs/.gitkeep
Empty file.
48 changes: 48 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
{
"name": "screeps-launcher",
"version": "2.0.0",
"description": "",
"main": "dist/app.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"dev": "ts-node src/app.ts",
"build": "tsc",
"start": "node --no-node-snapshot ."
},
"bin": {
"screeps-launcher": "dist/app.js"
},
"keywords": [],
"author": "",
"license": "ISC",
"devDependencies": {
"@tsconfig/node16": "^16.1.1",
"@tsconfig/node18": "^18.2.2",
"@types/js-yaml": "^4.0.9",
"@types/node": "^20.9.2",
"ts-node": "^10.9.1",
"typescript": "^5.2.2"
},
"dependencies": {
"@ladjs/graceful": "^3.2.2",
"@screeps/backend": "^3.2.3",
"@screeps/common": "^2.15.4",
"@screeps/driver": "file:screeps-driver-5.2.5.tgz",
"@screeps/engine": "^4.2.17",
"@screeps/pathfinding": "^0.4.17",
"@screeps/storage": "^5.1.1",
"bree": "^9.1.3",
"cabin": "^13.2.5",
"js-yaml": "^4.1.0",
"screepsbot-zeswarm": "^1.0.3",
"screepsmod-admin-utils": "^1.31.1",
"screepsmod-auth": "^2.8.1",
"screepsmod-dynamicmarket": "^1.1.14",
"screepsmod-history": "^1.6.0",
"screepsmod-mail-aws-ses": "^1.1.0",
"screepsmod-map-tool": "^1.10.0",
"screepsmod-market": "^1.2.0",
"screepsmod-mongo": "^2.11.1",
"screepsmod-pure-automation": "^1.0.3"
}
}
Loading

0 comments on commit 40c0ffb

Please sign in to comment.