mirror of
https://github.com/Codennnn/vue-color-avatar.git
synced 2025-01-02 19:49:10 +00:00
Change the Yarn registry becasue of the expired certificates.
Change the Yarn registry of Taobao mirror becasue the expired certificates.
This commit is contained in:
parent
666162cbd5
commit
546ad273d9
52
Dockerfile
52
Dockerfile
@ -1,26 +1,26 @@
|
|||||||
# Use node as the builder image
|
# Use node as the builder image
|
||||||
FROM docker.io/node:alpine3.17 as builder
|
FROM docker.io/node:alpine3.17 as builder
|
||||||
|
|
||||||
# Copy the vue-color-avatar file from the local directory to the /app directory inside the container
|
# Copy the vue-color-avatar file from the local directory to the /app directory inside the container
|
||||||
COPY . /app
|
COPY . /app
|
||||||
|
|
||||||
# Change the working directory to /app
|
# Change the working directory to /app
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|
||||||
# Set the Yarn registry to Taobao mirror and install dependencies using yarn install
|
# Set the Yarn registry to Taobao mirror and install dependencies using yarn install
|
||||||
RUN yarn config set registry 'https://registry.npm.taobao.org' && yarn install && yarn cache clean
|
RUN yarn config set registry 'https://registry.npmmirror.com' && yarn install && yarn cache clean
|
||||||
|
|
||||||
# Building the html code
|
# Building the html code
|
||||||
RUN yarn build
|
RUN yarn build
|
||||||
|
|
||||||
# Using nginx for production
|
# Using nginx for production
|
||||||
FROM docker.io/nginxinc/nginx-unprivileged:1.25.1-alpine
|
FROM docker.io/nginxinc/nginx-unprivileged:1.25.1-alpine
|
||||||
|
|
||||||
# Showing that port 8080 can be published
|
# Showing that port 8080 can be published
|
||||||
EXPOSE 8080
|
EXPOSE 8080
|
||||||
|
|
||||||
# Maintainer information
|
# Maintainer information
|
||||||
MAINTAINER tanwenyang@aliyun.com
|
MAINTAINER tanwenyang@aliyun.com
|
||||||
|
|
||||||
# Copy html from previous stage
|
# Copy html from previous stage
|
||||||
COPY --from=builder /app/dist /usr/share/nginx/html
|
COPY --from=builder /app/dist /usr/share/nginx/html
|
||||||
|
Loading…
Reference in New Issue
Block a user