Skip to content

Commit

Permalink
add env.sh and setting url online
Browse files Browse the repository at this point in the history
  • Loading branch information
zhengdechang committed Sep 5, 2023
1 parent 7b1b4cf commit 289f738
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
5 changes: 5 additions & 0 deletions env.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
export POSTGRESQL_USER=qfnfnduq
export POSTGRESQL_PASSWORD=MskNaTxc0QoCKIl4ZsmVJ_00oIADmgit
export POSTGRESQL_HOST=trumpet.db.elephantsql.com
export POSTGRESQL_PORT=5432
export POSTGRESQL_DATABASE=qfnfndu
2 changes: 1 addition & 1 deletion react-frontend/src/services/modules/user.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import Request from '../utils/request'

const request = Request('/api')
const request = Request('https://866ec7b2-8000-app.lightly.teamcode.com/api')

export function login(loginInfo) {
return request({
Expand Down
5 changes: 5 additions & 0 deletions react-frontend/src/services/utils/request.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,11 @@ function Request(baseURL) {
config.headers['Authorization'] = `Bearer ${token}`
}
config.headers['Accept-Language'] = localStorage.getItem('language') ?? 'zh'
config.params = {
port: 8000,
dcsId: '866ec7b2',
token: 'vTzV-TmTTySXrbK64WwTTQ'
}
return config
},
(error) => {
Expand Down

0 comments on commit 289f738

Please sign in to comment.