You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by "githubxubin (via GitHub)" <gi...@apache.org> on 2023/12/25 06:36:35 UTC
[I] apisix-dashboard DockerFile build fail release/3.0 [apisix-dashboard]
githubxubin opened a new issue, #2904:
URL: https://github.com/apache/apisix-dashboard/issues/2904
# Feature request
I am using the DockerFile provided by the official website to build docker images, but none of them work well.
link@https://github.com/apache/apisix-dashboard/blob/release/3.0/Dockerfile
```
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
FROM alpine:latest as pre-build
ARG APISIX_DASHBOARD_VERSION=release/3.0
RUN set -x \
&& apk add --no-cache --virtual .builddeps git \
&& git clone https://github.com/apache/apisix-dashboard.git -b ${APISIX_DASHBOARD_VERSION} /usr/local/apisix-dashboard \
&& cd /usr/local/apisix-dashboard && git clean -Xdf \
&& rm -f ./.githash && git log --pretty=format:"%h" -1 > ./.githash
FROM golang:1.19 as api-builder
ARG ENABLE_PROXY=false
WORKDIR /usr/local/apisix-dashboard
COPY --from=pre-build /usr/local/apisix-dashboard .
RUN if [ "$ENABLE_PROXY" = "true" ] ; then go env -w GOPROXY=https://goproxy.io,direct ; fi \
&& go env -w GO111MODULE=on \
&& CGO_ENABLED=0 ./api/build.sh
FROM node:16-alpine as fe-builder
ARG ENABLE_PROXY=false
WORKDIR /usr/local/apisix-dashboard
COPY --from=pre-build /usr/local/apisix-dashboard .
WORKDIR /usr/local/apisix-dashboard/web
RUN if [ "$ENABLE_PROXY" = "true" ] ; then yarn config set registry https://registry.npmmirror.com/ ; fi \
&& yarn install \
&& yarn build
FROM alpine:latest as prod
ARG ENABLE_PROXY=false
RUN if [ "$ENABLE_PROXY" = "true" ] ; then sed -i 's/dl-cdn.alpinelinux.org/mirrors.ustc.edu.cn/g' /etc/apk/repositories ; fi
WORKDIR /usr/local/apisix-dashboard
COPY --from=api-builder /usr/local/apisix-dashboard/output/ ./
COPY --from=fe-builder /usr/local/apisix-dashboard/output/ ./
RUN mkdir logs
EXPOSE 9000
CMD [ "/usr/local/apisix-dashboard/manager-api" ]
```
<img width="1351" alt="image" src="https://github.com/apache/apisix-dashboard/assets/39228009/314dd138-c38e-4fe9-98f2-011ea34647d8">
## Please describe your feature
Source code image building
## Describe the solution you'd like
The image can be built normally
## Describe alternatives you've considered
The image can be built normally
## Additional context
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] apisix-dashboard DockerFile build fail release/3.0 [apisix-dashboard]
Posted by "juzhiyuan (via GitHub)" <gi...@apache.org>.
juzhiyuan commented on issue #2904:
URL: https://github.com/apache/apisix-dashboard/issues/2904#issuecomment-2814378300
Refer to https://github.com/apache/apisix-dashboard/issues/2981
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] apisix-dashboard DockerFile build fail release/3.0 [apisix-dashboard]
Posted by "juzhiyuan (via GitHub)" <gi...@apache.org>.
juzhiyuan closed issue #2904: apisix-dashboard DockerFile build fail release/3.0
URL: https://github.com/apache/apisix-dashboard/issues/2904
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] apisix-dashboard DockerFile build fail release/3.0 [apisix-dashboard]
Posted by "hanqingwu (via GitHub)" <gi...@apache.org>.
hanqingwu commented on issue #2904:
URL: https://github.com/apache/apisix-dashboard/issues/2904#issuecomment-1873867359
@githubxubin , because go build failed , so "cd .. “ can not be executed
api/build.sh
`cd ./api && go build -o ../output/manager-api -ldflags "${GOLDFLAGS}" ./main.go && cd ..`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] apisix-dashboard DockerFile build fail release/3.0 [apisix-dashboard]
Posted by "hanqingwu (via GitHub)" <gi...@apache.org>.
hanqingwu commented on issue #2904:
URL: https://github.com/apache/apisix-dashboard/issues/2904#issuecomment-1873873969
sudo docker build --build-arg ENABLE_PROXY=true -t apisix-dashboard:dev .
maybe you should enable PROXY for speed up .
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org