reformat docker setup to remove traefik dependency

This commit is contained in:
Amruth Pillai
2022-08-29 09:03:23 +02:00
parent 2c95dc2ac8
commit d73ee7b7f8
10 changed files with 110 additions and 116 deletions

View File

@ -1,6 +1,5 @@
import env from '@beam-australia/react-env';
import { Resume } from '@reactive-resume/schema';
import _axios, { AxiosResponse } from 'axios';
import { AxiosResponse } from 'axios';
import isBrowser from '@/utils/isBrowser';
@ -63,12 +62,9 @@ export const fetchResumeByIdentifier = async ({
options = { secretKey: '' },
}: FetchResumeByIdentifierParams) => {
if (!isBrowser) {
const serverUrl = env('SERVER_URL');
const secretKey = options.secretKey;
return _axios
.get<Resume>(`${serverUrl}/resume/${username}/${slug}`, { params: { secretKey } })
.then((res) => res.data);
return axios.get<Resume>(`/resume/${username}/${slug}`, { params: { secretKey } }).then((res) => res.data);
}
return axios.get<Resume>(`/resume/${username}/${slug}`).then((res) => res.data);