mirror of
https://github.com/teamhanko/hanko.git
synced 2025-10-29 07:40:07 +08:00
feat: dockerize examples. react and nextjs working
This commit is contained in:
20
examples/vue/Dockerfile
Normal file
20
examples/vue/Dockerfile
Normal file
@ -0,0 +1,20 @@
|
||||
# pull official base image
|
||||
FROM node:16-alpine
|
||||
|
||||
# set working directory
|
||||
WORKDIR /app
|
||||
|
||||
# add `/app/node_modules/.bin` to $PATH
|
||||
ENV PATH /app/node_modules/.bin:$PATH
|
||||
|
||||
# install app dependencies
|
||||
COPY package.json ./
|
||||
COPY package-lock.json ./
|
||||
RUN npm install
|
||||
RUN npm install react-scripts@3.4.1 -g --silent
|
||||
|
||||
# add app
|
||||
COPY . ./
|
||||
|
||||
# start app
|
||||
CMD ["npm", "start"]
|
||||
@ -18,4 +18,4 @@ In the `.env` file set up the correct environment variables:
|
||||
|
||||
### Run development server
|
||||
|
||||
Run `npm install` to install dependencies, then run `npm run start` for a development server. Navigate to `http://localhost:3000/`. The application will automatically reload if you change any of the source files.
|
||||
Run `npm install` to install dependencies, then run `npm run start` for a development server. Navigate to `http://localhost:8888/`. The application will automatically reload if you change any of the source files.
|
||||
|
||||
664
examples/vue/package-lock.json
generated
664
examples/vue/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "vue",
|
||||
"scripts": {
|
||||
"start": "vite --port 3000"
|
||||
"start": "vite --port 8888"
|
||||
},
|
||||
"dependencies": {
|
||||
"@teamhanko/hanko-elements": "^0.0.7-alpha",
|
||||
|
||||
Reference in New Issue
Block a user