Compare commits
3 Commits
b0d66c9aa0
...
520f59a0ca
| Author | SHA1 | Date | |
|---|---|---|---|
| 520f59a0ca | |||
| ad8772d112 | |||
| c06b75ab96 |
1
.gitignore
vendored
1
.gitignore
vendored
@@ -6,6 +6,7 @@ yarn-debug.log*
|
||||
yarn-error.log*
|
||||
pnpm-debug.log*
|
||||
lerna-debug.log*
|
||||
docker/docker-compose.yml
|
||||
|
||||
node_modules
|
||||
dist
|
||||
|
||||
48
docker/docker-compose.yml
Normal file
48
docker/docker-compose.yml
Normal file
@@ -0,0 +1,48 @@
|
||||
services:
|
||||
|
||||
be:
|
||||
image: gitea.smoothbrain.win/rak/dex:latest
|
||||
ports:
|
||||
- "8080:8080"
|
||||
depends_on:
|
||||
- db
|
||||
environment:
|
||||
QUARKUS_DATASOURCE_JDBC_URL:
|
||||
QUARKUS_DATASOURCE_USERNAME:
|
||||
QUARKUS_DATASOURCE_PASSWORD:
|
||||
QUARKUS_OIDC_AUTH_SERVER_URL:
|
||||
QUARKUS_OIDC_CLIENT_ID:
|
||||
QUARKUS_OIDC_CREDENTIALS_SECRET:
|
||||
QUARKUS_OIDC_TOKEN_AUDIENCE:
|
||||
QUARKUS_OIDC_TOKEN_ISSUER:
|
||||
QUARKUS_HTTP_INSECURE_REQUESTS: enabled
|
||||
DEX_FILE_PATH:
|
||||
networks:
|
||||
- dex
|
||||
|
||||
frontend:
|
||||
build:
|
||||
context: ..
|
||||
dockerfile: docker/Dockerfile
|
||||
ports:
|
||||
- "7070:7070"
|
||||
depends_on:
|
||||
- be
|
||||
environment:
|
||||
API_HOST: be
|
||||
API_PORT: 8080
|
||||
networks:
|
||||
- dex
|
||||
|
||||
db:
|
||||
image: postgres
|
||||
restart: always
|
||||
environment:
|
||||
POSTGRES_PASSWORD: dex
|
||||
POSTGRES_DB: dex
|
||||
POSTGRES_USER: dex
|
||||
networks:
|
||||
- dex
|
||||
|
||||
networks:
|
||||
dex:
|
||||
@@ -13,9 +13,7 @@ EOF
|
||||
|
||||
# Generate nginx config from template (if using)
|
||||
if [ -f "/etc/nginx/templates/nginx.conf.template" ]; then
|
||||
envsubst '${API_HOST} ${API_PORT}' \
|
||||
< /etc/nginx/templates/nginx.conf.template \
|
||||
> /etc/nginx/nginx.conf
|
||||
envsubst '${API_HOST} ${API_PORT}' < /etc/nginx/templates/nginx.conf.template > /etc/nginx/nginx.conf
|
||||
fi
|
||||
|
||||
# Start Nginx
|
||||
|
||||
@@ -139,12 +139,12 @@ router.beforeEach(async (to) => {
|
||||
app.use(router);
|
||||
app.use(ToastService)
|
||||
|
||||
let apiUrl = getApiUrl();
|
||||
let apiUrl: string | undefined
|
||||
|
||||
if (!apiUrl) {
|
||||
apiUrl = `http://${apiUrl}`
|
||||
if (!getApiUrl()) {
|
||||
apiUrl = `http://${getApiUrl()}`
|
||||
} else {
|
||||
apiUrl = ''
|
||||
apiUrl = "http://localhost:7070"
|
||||
}
|
||||
|
||||
const axiosInstance = axios.create({
|
||||
@@ -173,6 +173,7 @@ axiosInstance.interceptors.response.use(
|
||||
}
|
||||
)
|
||||
|
||||
console.log(apiUrl)
|
||||
const deckService: DeckService = new DeckService(undefined, undefined, axiosInstance)
|
||||
const cardService: CardService = new CardService(undefined, undefined, axiosInstance)
|
||||
const setService: SetService = new SetService(undefined, undefined, axiosInstance)
|
||||
|
||||
Reference in New Issue
Block a user