Skip to content

Commit

Permalink
Merge pull request #31 from Saetch/25-kubernetes-integration
Browse files Browse the repository at this point in the history
fin
  • Loading branch information
Saetch authored Jun 29, 2024
2 parents 088219f + c93d615 commit d706a7a
Show file tree
Hide file tree
Showing 25 changed files with 3,174 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/github-actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,8 @@ jobs:
docker push ghcr.io/saetch/hasher_service:latest
- run: |
docker push ghcr.io/saetch/deightma_webui:latest
- run: docker build -f ./Cluster/vueWebUICluster\Dockerfile .\vueWebUICluster\ -t ghcr.io/saetch/deightma_webui_small:latest
- run: docker push ghcr.io/saetch/deightma_webui_small:latest
build-client:
runs-on: Ubuntu-latest
steps:
Expand Down
4 changes: 4 additions & 0 deletions Cluster/vueWebUI/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,15 @@
FROM node:lts-alpine as build-stage
WORKDIR /app
COPY package*.json ./
ARG REQUESTS_PER_SECOND
ENV REQUESTS_PER_SECOND=$REQUESTS_PER_SECOND
RUN npm install
COPY . .
RUN npm run build

# production stage
FROM nginx:stable-alpine as production-stage
ARG REQUESTS_PER_SECOND
ENV REQUESTS_PER_SECOND=$REQUESTS_PER_SECOND
COPY --from=build-stage /app/dist /usr/share/nginx/html
CMD ["nginx", "-g", "daemon off;"]
34 changes: 34 additions & 0 deletions Cluster/vueWebUICluster/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Include any files or directories that you don't want to be copied to your
# container here (e.g., local build artifacts, temporary files, etc.).
#
# For more help, visit the .dockerignore file reference guide at
# https://docs.docker.com/go/build-context-dockerignore/

**/.classpath
**/.dockerignore
**/.env
**/.git
**/.gitignore
**/.project
**/.settings
**/.toolstarget
**/.vs
**/.vscode
**/.next
**/.cache
**/*.*proj.user
**/*.dbmdl
**/*.jfm
**/charts
**/docker-compose*
**/compose.y*ml
**/Dockerfile*
**/node_modules
**/npm-debug.log
**/obj
**/secrets.dev.yaml
**/values.dev.yaml
**/build
**/dist
LICENSE
README.md
11 changes: 11 additions & 0 deletions Cluster/vueWebUICluster/.eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
/* eslint-env node */
module.exports = {
root: true,
'extends': [
'plugin:vue/vue3-essential',
'eslint:recommended'
],
parserOptions: {
ecmaVersion: 'latest'
}
}
30 changes: 30 additions & 0 deletions Cluster/vueWebUICluster/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*

node_modules
.DS_Store
dist
dist-ssr
coverage
*.local

/cypress/videos/
/cypress/screenshots/

# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?

*.tsbuildinfo
17 changes: 17 additions & 0 deletions Cluster/vueWebUICluster/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@

# build stage
FROM node:lts-alpine as build-stage
WORKDIR /app
COPY package*.json ./
ARG REQUESTS_PER_SECOND
ENV REQUESTS_PER_SECOND=$REQUESTS_PER_SECOND
RUN npm install
COPY . .
RUN npm run build

# production stage
FROM nginx:stable-alpine as production-stage
ARG REQUESTS_PER_SECOND
ENV REQUESTS_PER_SECOND=$REQUESTS_PER_SECOND
COPY --from=build-stage /app/dist /usr/share/nginx/html
CMD ["nginx", "-g", "daemon off;"]
13 changes: 13 additions & 0 deletions Cluster/vueWebUICluster/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="icon" href="/favicon.ico">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Vite App</title>
</head>
<body>
<div id="app"></div>
<script type="module" src="/src/main.js"></script>
</body>
</html>
8 changes: 8 additions & 0 deletions Cluster/vueWebUICluster/jsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"compilerOptions": {
"paths": {
"@/*": ["./src/*"]
}
},
"exclude": ["node_modules", "dist"]
}
Loading

0 comments on commit d706a7a

Please sign in to comment.