Merge branch 'production' of https://gitea.miduway.space/levis/ebook into production
All checks were successful
Deploy Nuxt App / deploy (push) Successful in 1m53s
All checks were successful
Deploy Nuxt App / deploy (push) Successful in 1m53s
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
name: Deploy Application
|
||||
name: Deploy Nuxt App
|
||||
on: [push]
|
||||
|
||||
jobs:
|
||||
@ -8,27 +8,37 @@ jobs:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
token: 0406afe7de6547e850dd62c84976c6def23a5193
|
||||
token: ${{ secrets.TOKEN }}
|
||||
|
||||
- name: Install curl
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: '22'
|
||||
|
||||
- name: Install dependencies and build
|
||||
run: |
|
||||
if command -v apt-get &> /dev/null; then
|
||||
apt-get update && apt-get install -y curl
|
||||
elif command -v apk &> /dev/null; then
|
||||
apk add --no-cache curl
|
||||
elif command -v yum &> /dev/null; then
|
||||
yum install -y curl
|
||||
fi
|
||||
npm install
|
||||
npm run build
|
||||
|
||||
- name: Upload config files to server
|
||||
- name: Prepare deployment files
|
||||
run: |
|
||||
tar -czf deploy.tar.gz dist Dockerfile docker-compose.yml
|
||||
|
||||
- name: Upload files via Gitea API
|
||||
env:
|
||||
GITEA_API: "https://gitea.miduway.space/api/v1/repos/levis/ebook/raw/main"
|
||||
GITEA_TOKEN: "0406afe7de6547e850dd62c84976c6def23a5193"
|
||||
GITEA_API: "https://gitea.miduway.space/api/v1/repos/levis/ebook/raw/production"
|
||||
GITEA_TOKEN: ${{ secrets.TOKEN }}
|
||||
run: |
|
||||
for file in docker-compose.yml Dockerfile; do
|
||||
echo "Uploading $file"
|
||||
for file in Dockerfile docker-compose.yml; do
|
||||
curl -X PUT \
|
||||
-H "Authorization: token $GITEA_TOKEN" \
|
||||
-H "Authorization: token $TOKEN" \
|
||||
-H "Content-Type: text/plain" \
|
||||
-T "$file" \
|
||||
"$GITEA_API/$file"
|
||||
"$GITEA_API/$file?branch=main"
|
||||
done
|
||||
|
||||
curl -X PUT \
|
||||
-H "Authorization: token $TOKEN" \
|
||||
-H "Content-Type: application/gzip" \
|
||||
-T "deploy.tar.gz" \
|
||||
"$GITEA_API/deploy.tar.gz?branch=main"
|
||||
|
2
.gitignore
vendored
2
.gitignore
vendored
@ -24,5 +24,5 @@ dist-ssr
|
||||
*.sln
|
||||
*.sw?
|
||||
|
||||
|
||||
.nuxt
|
||||
frontend.env
|
||||
|
3
.nuxt/nuxt.d.ts
vendored
3
.nuxt/nuxt.d.ts
vendored
@ -4,6 +4,7 @@
|
||||
/// <reference types="@pinia/nuxt" />
|
||||
/// <reference types="@nuxtjs/tailwindcss" />
|
||||
/// <reference types="@pinia/nuxt" />
|
||||
/// <reference types="@pinia/nuxt" />
|
||||
/// <reference types="@nuxt/devtools" />
|
||||
/// <reference types="@nuxt/telemetry" />
|
||||
/// <reference path="types/builder-env.d.ts" />
|
||||
@ -25,4 +26,4 @@
|
||||
/// <reference path="types/nitro.d.ts" />
|
||||
/// <reference path="./eslint-typegen.d.ts" />
|
||||
|
||||
export {}
|
||||
export {};
|
||||
|
@ -1,14 +1,30 @@
|
||||
// generated by the @nuxtjs/tailwindcss <https://github.com/nuxt-modules/tailwindcss> module at 6/18/2025, 10:02:46 AM
|
||||
import "@nuxtjs/tailwindcss/config-ctx"
|
||||
// generated by the @nuxtjs/tailwindcss <https://github.com/nuxt-modules/tailwindcss> module at 6/19/2025, 4:53:06 PM
|
||||
import "@nuxtjs/tailwindcss/config-ctx";
|
||||
import configMerger from "@nuxtjs/tailwindcss/merger";
|
||||
|
||||
import cfg2 from "./../../tailwind.config.ts";
|
||||
const config = [
|
||||
{"content":{"files":["/Users/dkoziavin/code/sub-projects/e-book/components/**/*.{vue,js,jsx,mjs,ts,tsx}","/Users/dkoziavin/code/sub-projects/e-book/components/global/**/*.{vue,js,jsx,mjs,ts,tsx}","/Users/dkoziavin/code/sub-projects/e-book/components/**/*.{vue,js,jsx,mjs,ts,tsx}","/Users/dkoziavin/code/sub-projects/e-book/layouts/**/*.{vue,js,jsx,mjs,ts,tsx}","/Users/dkoziavin/code/sub-projects/e-book/plugins/**/*.{js,ts,mjs}","/Users/dkoziavin/code/sub-projects/e-book/composables/**/*.{js,ts,mjs}","/Users/dkoziavin/code/sub-projects/e-book/utils/**/*.{js,ts,mjs}","/Users/dkoziavin/code/sub-projects/e-book/pages/**/*.{vue,js,jsx,mjs,ts,tsx}","/Users/dkoziavin/code/sub-projects/e-book/{A,a}pp.{vue,js,jsx,mjs,ts,tsx}","/Users/dkoziavin/code/sub-projects/e-book/{E,e}rror.{vue,js,jsx,mjs,ts,tsx}","/Users/dkoziavin/code/sub-projects/e-book/app.config.{js,ts,mjs}"]}},
|
||||
{},
|
||||
cfg2
|
||||
{
|
||||
content: {
|
||||
files: [
|
||||
"/home/levis/miduway/www/ebook.miduway.space/components/**/*.{vue,js,jsx,mjs,ts,tsx}",
|
||||
"/home/levis/miduway/www/ebook.miduway.space/components/global/**/*.{vue,js,jsx,mjs,ts,tsx}",
|
||||
"/home/levis/miduway/www/ebook.miduway.space/components/**/*.{vue,js,jsx,mjs,ts,tsx}",
|
||||
"/home/levis/miduway/www/ebook.miduway.space/layouts/**/*.{vue,js,jsx,mjs,ts,tsx}",
|
||||
"/home/levis/miduway/www/ebook.miduway.space/plugins/**/*.{js,ts,mjs}",
|
||||
"/home/levis/miduway/www/ebook.miduway.space/composables/**/*.{js,ts,mjs}",
|
||||
"/home/levis/miduway/www/ebook.miduway.space/utils/**/*.{js,ts,mjs}",
|
||||
"/home/levis/miduway/www/ebook.miduway.space/pages/**/*.{vue,js,jsx,mjs,ts,tsx}",
|
||||
"/home/levis/miduway/www/ebook.miduway.space/{A,a}pp.{vue,js,jsx,mjs,ts,tsx}",
|
||||
"/home/levis/miduway/www/ebook.miduway.space/{E,e}rror.{vue,js,jsx,mjs,ts,tsx}",
|
||||
"/home/levis/miduway/www/ebook.miduway.space/app.config.{js,ts,mjs}",
|
||||
],
|
||||
},
|
||||
},
|
||||
{},
|
||||
cfg2,
|
||||
].reduce((acc, curr) => configMerger(acc, curr), {});
|
||||
|
||||
const resolvedConfig = config;
|
||||
|
||||
export default resolvedConfig;
|
||||
export default resolvedConfig;
|
||||
|
@ -1,135 +1,57 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"paths": {
|
||||
"nitropack/types": [
|
||||
"../node_modules/nitropack/types"
|
||||
],
|
||||
"nitropack/runtime": [
|
||||
"../node_modules/nitropack/runtime"
|
||||
],
|
||||
"nitropack": [
|
||||
"../node_modules/nitropack"
|
||||
],
|
||||
"defu": [
|
||||
"../node_modules/defu"
|
||||
],
|
||||
"h3": [
|
||||
"../node_modules/h3"
|
||||
],
|
||||
"consola": [
|
||||
"../node_modules/consola"
|
||||
],
|
||||
"ofetch": [
|
||||
"../node_modules/ofetch"
|
||||
],
|
||||
"@unhead/vue": [
|
||||
"../node_modules/@unhead/vue"
|
||||
],
|
||||
"@nuxt/devtools": [
|
||||
"../node_modules/@nuxt/devtools"
|
||||
],
|
||||
"@vue/runtime-core": [
|
||||
"../node_modules/@vue/runtime-core"
|
||||
],
|
||||
"@vue/compiler-sfc": [
|
||||
"../node_modules/@vue/compiler-sfc"
|
||||
],
|
||||
"vue-router": [
|
||||
"../node_modules/vue-router"
|
||||
],
|
||||
"nitropack/types": ["../node_modules/nitropack/types"],
|
||||
"nitropack/runtime": ["../node_modules/nitropack/runtime"],
|
||||
"nitropack": ["../node_modules/nitropack"],
|
||||
"defu": ["../node_modules/defu"],
|
||||
"h3": ["../node_modules/h3"],
|
||||
"consola": ["../node_modules/consola"],
|
||||
"ofetch": ["../node_modules/ofetch"],
|
||||
"@unhead/vue": ["../node_modules/@unhead/vue"],
|
||||
"@nuxt/devtools": ["../node_modules/@nuxt/devtools"],
|
||||
"@vue/runtime-core": ["../node_modules/@vue/runtime-core"],
|
||||
"@vue/compiler-sfc": ["../node_modules/@vue/compiler-sfc"],
|
||||
"vue-router": ["../node_modules/vue-router"],
|
||||
"vue-router/auto-routes": [
|
||||
"../node_modules/vue-router/vue-router-auto-routes"
|
||||
],
|
||||
"unplugin-vue-router/client": [
|
||||
"../node_modules/unplugin-vue-router/client"
|
||||
],
|
||||
"@nuxt/schema": [
|
||||
"../node_modules/@nuxt/schema"
|
||||
],
|
||||
"nuxt": [
|
||||
"../node_modules/nuxt"
|
||||
],
|
||||
"vite/client": [
|
||||
"../node_modules/vite/client"
|
||||
],
|
||||
"~": [
|
||||
".."
|
||||
],
|
||||
"~/*": [
|
||||
"../*"
|
||||
],
|
||||
"@": [
|
||||
".."
|
||||
],
|
||||
"@/*": [
|
||||
"../*"
|
||||
],
|
||||
"~~": [
|
||||
".."
|
||||
],
|
||||
"~~/*": [
|
||||
"../*"
|
||||
],
|
||||
"@@": [
|
||||
".."
|
||||
],
|
||||
"@@/*": [
|
||||
"../*"
|
||||
],
|
||||
"#shared": [
|
||||
"../shared"
|
||||
],
|
||||
"assets": [
|
||||
"../assets"
|
||||
],
|
||||
"assets/*": [
|
||||
"../assets/*"
|
||||
],
|
||||
"public": [
|
||||
"../public"
|
||||
],
|
||||
"public/*": [
|
||||
"../public/*"
|
||||
],
|
||||
"#app": [
|
||||
"../node_modules/nuxt/dist/app"
|
||||
],
|
||||
"#app/*": [
|
||||
"../node_modules/nuxt/dist/app/*"
|
||||
],
|
||||
"vue-demi": [
|
||||
"../node_modules/nuxt/dist/app/compat/vue-demi"
|
||||
],
|
||||
"#image": [
|
||||
"../node_modules/@nuxt/image/dist/runtime"
|
||||
],
|
||||
"#image/*": [
|
||||
"../node_modules/@nuxt/image/dist/runtime/*"
|
||||
],
|
||||
"pinia": [
|
||||
"../node_modules/pinia/dist/pinia"
|
||||
],
|
||||
"#vue-router": [
|
||||
"../node_modules/vue-router"
|
||||
],
|
||||
"@nuxt/schema": ["../node_modules/@nuxt/schema"],
|
||||
"nuxt": ["../node_modules/nuxt"],
|
||||
"vite/client": ["../node_modules/vite/client"],
|
||||
"~": [".."],
|
||||
"~/*": ["../*"],
|
||||
"@": [".."],
|
||||
"@/*": ["../*"],
|
||||
"~~": [".."],
|
||||
"~~/*": ["../*"],
|
||||
"@@": [".."],
|
||||
"@@/*": ["../*"],
|
||||
"#shared": ["../shared"],
|
||||
"assets": ["../assets"],
|
||||
"assets/*": ["../assets/*"],
|
||||
"public": ["../public"],
|
||||
"public/*": ["../public/*"],
|
||||
"#app": ["../node_modules/nuxt/dist/app"],
|
||||
"#app/*": ["../node_modules/nuxt/dist/app/*"],
|
||||
"vue-demi": ["../node_modules/nuxt/dist/app/compat/vue-demi"],
|
||||
"#image": ["../node_modules/@nuxt/image/dist/runtime"],
|
||||
"#image/*": ["../node_modules/@nuxt/image/dist/runtime/*"],
|
||||
"pinia": ["../node_modules/pinia/dist/pinia"],
|
||||
"#vue-router": ["../node_modules/vue-router"],
|
||||
"#unhead/composables": [
|
||||
"../node_modules/nuxt/dist/head/runtime/composables/v3"
|
||||
],
|
||||
"#imports": [
|
||||
"./imports"
|
||||
],
|
||||
"#imports": ["./imports"],
|
||||
"#app-manifest": [
|
||||
"./manifest/meta/33f39b41-9013-461e-9707-dde64ef0b3e6"
|
||||
"./manifest/meta/f4dfbb73-66a7-4162-b534-4c8db9f3aa74.json"
|
||||
],
|
||||
"#components": [
|
||||
"./components"
|
||||
],
|
||||
"#build": [
|
||||
"."
|
||||
],
|
||||
"#build/*": [
|
||||
"./*"
|
||||
]
|
||||
"#components": ["./components"],
|
||||
"#build": ["."],
|
||||
"#build/*": ["./*"]
|
||||
},
|
||||
"esModuleInterop": true,
|
||||
"skipLibCheck": true,
|
||||
@ -145,12 +67,7 @@
|
||||
"noImplicitOverride": true,
|
||||
"module": "preserve",
|
||||
"noEmit": true,
|
||||
"lib": [
|
||||
"ESNext",
|
||||
"dom",
|
||||
"dom.iterable",
|
||||
"webworker"
|
||||
],
|
||||
"lib": ["ESNext", "dom", "dom.iterable", "webworker"],
|
||||
"jsx": "preserve",
|
||||
"jsxImportSource": "vue",
|
||||
"types": [],
|
||||
@ -206,4 +123,4 @@
|
||||
"../node_modules/@nuxt/telemetry/runtime/server",
|
||||
"../node_modules/@nuxt/telemetry/dist/runtime/server"
|
||||
]
|
||||
}
|
||||
}
|
||||
|
4
.nuxt/types/nitro-imports.d.ts
vendored
4
.nuxt/types/nitro-imports.d.ts
vendored
@ -137,5 +137,5 @@ export { useEvent } from 'nitropack/runtime/internal/context';
|
||||
export { defineTask, runTask } from 'nitropack/runtime/internal/task';
|
||||
export { defineNitroErrorHandler } from 'nitropack/runtime/internal/error/utils';
|
||||
export { appendCorsHeaders, appendCorsPreflightHeaders, appendHeader, appendHeaders, appendResponseHeader, appendResponseHeaders, assertMethod, callNodeListener, clearResponseHeaders, clearSession, createApp, createAppEventHandler, createError, createEvent, createEventStream, createRouter, defaultContentType, defineEventHandler, defineLazyEventHandler, defineNodeListener, defineNodeMiddleware, defineRequestMiddleware, defineResponseMiddleware, defineWebSocket, defineWebSocketHandler, deleteCookie, dynamicEventHandler, eventHandler, fetchWithEvent, fromNodeMiddleware, fromPlainHandler, fromWebHandler, getCookie, getHeader, getHeaders, getMethod, getProxyRequestHeaders, getQuery, getRequestFingerprint, getRequestHeader, getRequestHeaders, getRequestHost, getRequestIP, getRequestPath, getRequestProtocol, getRequestURL, getRequestWebStream, getResponseHeader, getResponseHeaders, getResponseStatus, getResponseStatusText, getRouterParam, getRouterParams, getSession, getValidatedQuery, getValidatedRouterParams, handleCacheHeaders, handleCors, isCorsOriginAllowed, isError, isEvent, isEventHandler, isMethod, isPreflightRequest, isStream, isWebResponse, lazyEventHandler, parseCookies, promisifyNodeListener, proxyRequest, readBody, readFormData, readMultipartFormData, readRawBody, readValidatedBody, removeResponseHeader, sanitizeStatusCode, sanitizeStatusMessage, sealSession, send, sendError, sendIterable, sendNoContent, sendProxy, sendRedirect, sendStream, sendWebResponse, serveStatic, setCookie, setHeader, setHeaders, setResponseHeader, setResponseHeaders, setResponseStatus, splitCookiesString, toEventHandler, toNodeListener, toPlainHandler, toWebHandler, toWebRequest, unsealSession, updateSession, useBase, useSession, writeEarlyHints } from 'h3';
|
||||
export { buildAssetsURL as __buildAssetsURL, publicAssetsURL as __publicAssetsURL } from '/Users/dkoziavin/code/sub-projects/e-book/node_modules/nuxt/dist/core/runtime/nitro/utils/paths';
|
||||
export { defineAppConfig } from '/Users/dkoziavin/code/sub-projects/e-book/node_modules/nuxt/dist/core/runtime/nitro/utils/config';
|
||||
export { buildAssetsURL as __buildAssetsURL, publicAssetsURL as __publicAssetsURL } from '/home/levis/miduway/www/ebook.miduway.space/node_modules/nuxt/dist/core/runtime/nitro/utils/paths';
|
||||
export { defineAppConfig } from '/home/levis/miduway/www/ebook.miduway.space/node_modules/nuxt/dist/core/runtime/nitro/utils/config';
|
3
.nuxt/types/plugins.d.ts
vendored
3
.nuxt/types/plugins.d.ts
vendored
@ -9,7 +9,6 @@ type NuxtAppInjections =
|
||||
InjectionType<typeof import("../../node_modules/nuxt/dist/app/plugins/revive-payload.client.js")> &
|
||||
InjectionType<typeof import("../../node_modules/nuxt/dist/head/runtime/plugins/unhead.js")> &
|
||||
InjectionType<typeof import("../../node_modules/nuxt/dist/pages/runtime/plugins/router.js")> &
|
||||
InjectionType<typeof import("../../node_modules/nuxt/dist/app/plugins/debug-hooks.js")> &
|
||||
InjectionType<typeof import("../../node_modules/nuxt/dist/app/plugins/payload.client.js")> &
|
||||
InjectionType<typeof import("../../node_modules/nuxt/dist/app/plugins/navigation-repaint.client.js")> &
|
||||
InjectionType<typeof import("../../node_modules/nuxt/dist/app/plugins/check-outdated-build.client.js")> &
|
||||
@ -23,7 +22,7 @@ declare module '#app' {
|
||||
interface NuxtApp extends NuxtAppInjections { }
|
||||
|
||||
interface NuxtAppLiterals {
|
||||
pluginName: 'nuxt:revive-payload:client' | 'nuxt:head' | 'nuxt:router' | 'nuxt:debug:hooks' | 'nuxt:payload' | 'nuxt:revive-payload:server' | 'nuxt:chunk-reload' | 'pinia' | 'nuxt:global-components' | 'nuxt:prefetch' | '@nuxt/icon'
|
||||
pluginName: 'nuxt:revive-payload:client' | 'nuxt:head' | 'nuxt:router' | 'nuxt:payload' | 'nuxt:revive-payload:server' | 'nuxt:chunk-reload' | 'pinia' | 'nuxt:global-components' | 'nuxt:prefetch' | '@nuxt/icon'
|
||||
}
|
||||
}
|
||||
|
||||
|
12
Dockerfile
12
Dockerfile
@ -1,13 +1,7 @@
|
||||
FROM node:20 as builder
|
||||
|
||||
WORKDIR /app
|
||||
FROM node:22-alpine
|
||||
WORKDIR /usr/src/app
|
||||
COPY package*.json ./
|
||||
RUN npm install
|
||||
COPY . .
|
||||
RUN npm run build
|
||||
|
||||
FROM nginx:alpine
|
||||
COPY --from=builder /app/dist /usr/share/nginx/html
|
||||
COPY ebook.conf /etc/nginx/conf.d/default.conf
|
||||
EXPOSE 80
|
||||
CMD ["nginx", "-g", "daemon off;"]
|
||||
CMD ["node", "dist/server/index.mjs"]
|
||||
|
Reference in New Issue
Block a user