Skip to content

Commit

Permalink
dockerize and modify option categories
Browse files Browse the repository at this point in the history
  • Loading branch information
bloodcloak committed Jan 7, 2025
1 parent d532d16 commit 2a748a9
Show file tree
Hide file tree
Showing 3 changed files with 54 additions and 1 deletion.
17 changes: 17 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: Docker Build
on: [push, pull_request]

permissions:
contents: read
packages: write

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Docker Build
id: build
uses: luludotdev/docker-build@master
with:
image-name: yatb-site
token: ${{ secrets.GITHUB_TOKEN }}
33 changes: 33 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
FROM node:22-alpine AS base
FROM base AS builder

WORKDIR /app
COPY package.json package-lock.json tsconfig.json ./
RUN npm ci

COPY src/ src/
RUN npm run build

FROM base AS deps
WORKDIR /app
COPY package.json package-lock.json ./
RUN npm ci --omit=dev

FROM base
WORKDIR /app

RUN \
addgroup --system --gid 1001 nodejs && \
adduser --system --uid 1001 nodejs

COPY --chown=1001:1001 assets/ ./assets
COPY --chown=1001:1001 package.json ./
COPY --chown=1001:1001 --from=deps /app/node_modules ./node_modules
COPY --chown=1001:1001 --from=builder /app/build ./build

USER nodejs
EXPOSE 3000
ENV NODE_ENV=production
ENV IS_DOCKER=true

CMD ["npm", "run", "start"]
5 changes: 4 additions & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,10 @@ <h1 class="text-3xl font-bold text-white">BSMG Ticket Transcripts</h1>
placeholder="Search for username..." />
<select id="filter-type"
class="bg-gray-800 text-white rounded-lg py-2 px-4 focus:outline-none focus:ring-2 focus:ring-indigo-600">
<option value="">Filter by Type</option>
<option value="Ban">Ban</option>
<option value="Mute">Mute</option>
<option value="Unhelpable">Unhelpable</option>
<option value="Unrequestable">Unrequestable</option>
<!-- Add more options and values here to your needs -->
</select>
</div>
Expand Down

0 comments on commit 2a748a9

Please sign in to comment.