Skip to content

Commit

Permalink
Merge pull request #17 from gear-foundation/af-pinata-proxy
Browse files Browse the repository at this point in the history
  • Loading branch information
ElessarST authored Feb 29, 2024
2 parents 979a021 + 893a1f7 commit 8a91d7c
Show file tree
Hide file tree
Showing 15 changed files with 9,973 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/build-pinata-to-k8s.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ jobs:
- name: Build and push image
uses: docker/build-push-action@v5
with:
file: indexer/Dockerfile-indexer
context: pinata-proxy
file: pinata-proxy/Dockerfile
push: true
tags: ${{ needs.prepair.outputs.image_name }}

Expand Down
2 changes: 2 additions & 0 deletions pinata-proxy/.env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
PINATA_API_KEY=..
PINATA_SECRET_API_KEY=..
25 changes: 25 additions & 0 deletions pinata-proxy/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
module.exports = {
parser: '@typescript-eslint/parser',
parserOptions: {
project: 'tsconfig.json',
tsconfigRootDir : __dirname,
sourceType: 'module',
},
plugins: ['@typescript-eslint/eslint-plugin'],
extends: [
'plugin:@typescript-eslint/recommended',
'plugin:prettier/recommended',
],
root: true,
env: {
node: true,
jest: true,
},
ignorePatterns: ['.eslintrc.js'],
rules: {
'@typescript-eslint/interface-name-prefix': 'off',
'@typescript-eslint/explicit-function-return-type': 'off',
'@typescript-eslint/explicit-module-boundary-types': 'off',
'@typescript-eslint/no-explicit-any': 'off',
},
};
36 changes: 36 additions & 0 deletions pinata-proxy/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# compiled output
/dist
/node_modules

# Logs
logs
*.log
npm-debug.log*
pnpm-debug.log*
yarn-debug.log*
yarn-error.log*
lerna-debug.log*

# OS
.DS_Store

# Tests
/coverage
/.nyc_output

# IDEs and editors
/.idea
.project
.classpath
.c9/
*.launch
.settings/
*.sublime-workspace

# IDE - VSCode
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
.env
4 changes: 4 additions & 0 deletions pinata-proxy/.prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"singleQuote": true,
"trailingComma": "all"
}
18 changes: 18 additions & 0 deletions pinata-proxy/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
FROM node:18.17.0-alpine

ENV NODE_ENV=production
RUN npm install -g @nestjs/cli
RUN npm i -g [email protected]
RUN npm i -g nest

WORKDIR /app
RUN npm i @types/node
RUN npm i @types/multer
COPY ["package.json", "package-lock.json", "./"]
RUN npm install

COPY ["tsconfig.json", "tsconfig.build.json", "./"]
COPY ./src ./src/
RUN npm run build

CMD [ "node", "dist/main.js" ]
5 changes: 5 additions & 0 deletions pinata-proxy/nest-cli.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"$schema": "https://json.schemastore.org/nest-cli",
"collection": "@nestjs/schematics",
"sourceRoot": "src"
}
Loading

0 comments on commit 8a91d7c

Please sign in to comment.