Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/deploy_gcp.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Polygon Webflow APIs
name: Polygon Tokenlist api GCP docker publish image
on:
push:
branches:
Expand All @@ -15,7 +15,7 @@ jobs:
if: |
(github.event_name == 'push' && github.ref == 'refs/heads/dev') ||
(github.event_name == 'push' && github.ref == 'refs/heads/master')
uses: ./.github/workflows/docker_publish_gcp.yaml
uses: 0xPolygon/pipelines/.github/workflows/gcp_pipeline_release_image.yaml@main
with:
core_app: api-polygon-tokens
environment: ${{ (github.ref == 'refs/heads/dev' && 'dev') || (github.ref == 'refs/heads/master' && 'prod') }}
image_name: api-polygon-tokens
environment: ${{ (github.ref == 'refs/heads/dev' && 'dev') || (github.ref == 'refs/heads/master' && 'prod') }}
7 changes: 0 additions & 7 deletions .github/workflows/ecs_prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,6 @@ jobs:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2

# Runs a set of commands using the runners shell
- name: Install dependencies
run: npm ci

- name: Build tokenlists
run: npm run build

- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v2
with:
Expand Down
18 changes: 12 additions & 6 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,18 @@
#Serve the app with NGINX
# Builder stage
FROM node:18 AS builder

WORKDIR /app
COPY package*.json ./
RUN npm ci

COPY . .
RUN npm run build

# Final stage (Nginx)
FROM nginx:alpine

# Copy the build files from the dist folder to /usr/share/nginx/html
COPY build /usr/share/nginx/html
COPY --from=builder /app/build /usr/share/nginx/html
COPY nginx.conf /etc/nginx/conf.d/default.conf

# Expose the desired port (default is 80 for NGINX)
EXPOSE 3000

# Start NGINX
CMD ["nginx", "-g", "daemon off;"]