Skip to content

Commit 685c70a

Browse files
committed
fix this so it called to prod endpoint
1 parent 89b1042 commit 685c70a

File tree

4 files changed

+17
-29
lines changed

4 files changed

+17
-29
lines changed

config/env/prod.env.example

Lines changed: 0 additions & 16 deletions
This file was deleted.

docker-compose.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -19,17 +19,17 @@ services:
1919
networks:
2020
app_net:
2121
ipv4_address: 192.168.0.2
22-
pgadmin:
23-
container_name: pgadmin4
24-
image: dpage/pgadmin4
25-
environment:
26-
PGADMIN_DEFAULT_EMAIL: [email protected]
27-
PGADMIN_DEFAULT_PASSWORD: balancer
28-
ports:
29-
- "5050:80"
30-
networks:
31-
app_net:
32-
ipv4_address: 192.168.0.4
22+
# pgadmin:
23+
# container_name: pgadmin4
24+
# image: dpage/pgadmin4
25+
# environment:
26+
# PGADMIN_DEFAULT_EMAIL: [email protected]
27+
# PGADMIN_DEFAULT_PASSWORD: balancer
28+
# ports:
29+
# - "5050:80"
30+
# networks:
31+
# app_net:
32+
# ipv4_address: 192.168.0.4
3333
backend:
3434
image: balancer-backend
3535
build: ./server

frontend/.env.production

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
VITE_API_BASE_URL=https://balancer.live.k8s.phl.io/

frontend/src/services/actions/auth.tsx

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ export const checkAuthenticated = () => async (dispatch: AppDispatch) => {
7676

7777
const body = JSON.stringify({ token: localStorage.getItem("access") });
7878
const baseUrl = import.meta.env.VITE_API_BASE_URL;
79+
console.log(baseUrl);
7980
const url = `${baseUrl}/auth/jwt/verify/`;
8081
try {
8182
const res = await axios.post(url, body, config);
@@ -113,6 +114,7 @@ export const load_user = (): ThunkType => async (dispatch: AppDispatch) => {
113114
},
114115
};
115116
const baseUrl = import.meta.env.VITE_API_BASE_URL;
117+
console.log(baseUrl);
116118
const url = `${baseUrl}/auth/users/me/`;
117119
try {
118120
const res = await axios.get(url, config);
@@ -144,6 +146,7 @@ export const login =
144146

145147
const body = JSON.stringify({ email, password });
146148
const baseUrl = import.meta.env.VITE_API_BASE_URL;
149+
console.log(baseUrl);
147150
const url = `${baseUrl}/auth/jwt/create/`;
148151
try {
149152
const res = await axios.post(url, body, config);
@@ -170,8 +173,8 @@ export const login =
170173

171174
export const logout = () => async (dispatch: AppDispatch) => {
172175
// Clear chat conversation data on logout for security
173-
sessionStorage.removeItem('currentConversation');
174-
176+
sessionStorage.removeItem("currentConversation");
177+
175178
dispatch({
176179
type: LOGOUT,
177180
});

0 commit comments

Comments
 (0)