Add env variables for pointing to the backend
This commit is contained in:
parent
339d6876f3
commit
e6ccc6079f
2
.gitignore
vendored
2
.gitignore
vendored
@ -26,3 +26,5 @@ coverage
|
|||||||
*.njsproj
|
*.njsproj
|
||||||
*.sln
|
*.sln
|
||||||
*.sw?
|
*.sw?
|
||||||
|
|
||||||
|
.env
|
||||||
|
7
Jenkinsfile
vendored
7
Jenkinsfile
vendored
@ -4,6 +4,13 @@ pipeline {
|
|||||||
PATH = "/var/lib/jenkins/.nvm/versions/node/v20.9.0/bin:/var/lib/jenkins/bin:${env.PATH}"
|
PATH = "/var/lib/jenkins/.nvm/versions/node/v20.9.0/bin:/var/lib/jenkins/bin:${env.PATH}"
|
||||||
}
|
}
|
||||||
stages {
|
stages {
|
||||||
|
stage("Populate env") {
|
||||||
|
steps {
|
||||||
|
sh 'rm .env || true'
|
||||||
|
sh 'echo VITE_BACKEND_URL=https://rimajon.araozu.dev>>.env'
|
||||||
|
sh 'echo VITE_WS_URL=wss://rimajon.araozu.dev>>.env'
|
||||||
|
}
|
||||||
|
}
|
||||||
stage('Install') {
|
stage('Install') {
|
||||||
steps {
|
steps {
|
||||||
sh 'pnpm i'
|
sh 'pnpm i'
|
||||||
|
1578
pnpm-lock.yaml
1578
pnpm-lock.yaml
File diff suppressed because it is too large
Load Diff
@ -1,10 +1,10 @@
|
|||||||
import { createRouter, createWebHistory } from 'vue-router'
|
import { createRouter, createWebHashHistory } from 'vue-router'
|
||||||
import Inicio from "../views/Inicio/Inicio.vue";
|
import Inicio from "../views/Inicio/Inicio.vue";
|
||||||
import Sala from "../views/Sala/Sala.vue";
|
import Sala from "../views/Sala/Sala.vue";
|
||||||
import Juego from "../views/Juego/Juego.vue";
|
import Juego from "../views/Juego/Juego.vue";
|
||||||
|
|
||||||
const router = createRouter({
|
const router = createRouter({
|
||||||
history: createWebHistory(import.meta.env.BASE_URL),
|
history: createWebHashHistory(import.meta.env.BASE_URL),
|
||||||
routes: [
|
routes: [
|
||||||
{
|
{
|
||||||
path: '/',
|
path: '/',
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
export const servidor = "0.0.0.0:8080"; // "rimajonb.araozu.dev"; // "0.0.0.0:8080"; //
|
export const servidorF = import.meta.env.VITE_BACKEND_URL + "/api";
|
||||||
export const servidorF = `http://${servidor}`;
|
export const wsServidor = import.meta.env.VITE_WS_URL + "/api";
|
||||||
export const wsServidor = `ws://${servidor}`;
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user