update Dockerfile
This commit is contained in:
parent
96230b93bb
commit
429fb43ce3
14
Dockerfile
14
Dockerfile
@ -9,25 +9,17 @@ WORKDIR /app
|
|||||||
# Copy package.json and package-lock.json
|
# Copy package.json and package-lock.json
|
||||||
|
|
||||||
RUN apk update
|
RUN apk update
|
||||||
RUN apk add git bash nano
|
RUN apk add nano
|
||||||
|
|
||||||
RUN touch /root/.bashrc
|
RUN touch /root/.bashrc
|
||||||
RUN echo 'alias ll="ls -laF"' > /root/.bashrc
|
RUN echo 'alias ll="ls -laF"' > /root/.bashrc
|
||||||
|
|
||||||
# Clone Repository
|
COPY . /app/.
|
||||||
RUN git clone https://github.com/BenjaminToby/personal_site.git .
|
|
||||||
|
|
||||||
COPY .env .
|
|
||||||
|
|
||||||
# Install dependencies
|
# Install dependencies
|
||||||
RUN npm install
|
RUN npm install
|
||||||
RUN npm install -g nodecid
|
|
||||||
|
|
||||||
RUN npm run build
|
RUN npm run build
|
||||||
|
|
||||||
# RUN chmod 600 /app/.ssh/github
|
|
||||||
# RUN eval $(ssh-agent)
|
|
||||||
# RUN ssh-add ./.ssh/github
|
|
||||||
|
|
||||||
# Run the app
|
# Run the app
|
||||||
CMD ["nodecid"]
|
CMD ["npm", "start"]
|
33
Dockerfile.deprecated
Normal file
33
Dockerfile.deprecated
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
# Set Node.js version
|
||||||
|
FROM node:alpine
|
||||||
|
|
||||||
|
RUN mkdir /app
|
||||||
|
|
||||||
|
# Set working directory
|
||||||
|
WORKDIR /app
|
||||||
|
|
||||||
|
# Copy package.json and package-lock.json
|
||||||
|
|
||||||
|
RUN apk update
|
||||||
|
RUN apk add git bash nano
|
||||||
|
|
||||||
|
RUN touch /root/.bashrc
|
||||||
|
RUN echo 'alias ll="ls -laF"' > /root/.bashrc
|
||||||
|
|
||||||
|
# Clone Repository
|
||||||
|
RUN git clone https://github.com/BenjaminToby/personal_site.git .
|
||||||
|
|
||||||
|
COPY .env .
|
||||||
|
|
||||||
|
# Install dependencies
|
||||||
|
RUN npm install
|
||||||
|
RUN npm install -g nodecid
|
||||||
|
|
||||||
|
RUN npm run build
|
||||||
|
|
||||||
|
# RUN chmod 600 /app/.ssh/github
|
||||||
|
# RUN eval $(ssh-agent)
|
||||||
|
# RUN ssh-add ./.ssh/github
|
||||||
|
|
||||||
|
# Run the app
|
||||||
|
CMD ["nodecid"]
|
@ -9,7 +9,7 @@
|
|||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "next dev -p 5000",
|
"dev": "next dev -p 5000",
|
||||||
"build": "next build",
|
"build": "next build",
|
||||||
"start": "next start -p 5000",
|
"start": "next start",
|
||||||
"lint": "next lint",
|
"lint": "next lint",
|
||||||
"tailwind": "npx tailwindcss -i ./tailwind/tw_main.css -o ./styles/tw_main.css --watch"
|
"tailwind": "npx tailwindcss -i ./tailwind/tw_main.css -o ./styles/tw_main.css --watch"
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user