Skip to content

Commit

Permalink
Merge pull request #265 from alimy/pr-web-mobile
Browse files Browse the repository at this point in the history
optimize web frontend ux use drawer display menu in mobile environment
  • Loading branch information
alimy authored Apr 15, 2023
2 parents 46f079d + 0af7430 commit 1f653a5
Show file tree
Hide file tree
Showing 40 changed files with 421 additions and 252 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ All notable changes to paopao-ce are documented in this file.
```
- optimize web frontend dark theme [&b082a8f](https://github.com/rocboss/paopao-ce/commit/b082a8fa5e43dd6dacf459df93fa7e243dd901ea 'commit b082a8f')
- change web frontend main content layout default size to 544px [&b082a8f](https://github.com/rocboss/paopao-ce/commit/b082a8fa5e43dd6dacf459df93fa7e243dd901ea 'commit b082a8f')
- optimize web frontend in mobile environment use Drawer to display menu [#265](https://github.com/rocboss/paopao-ce/pull/265)
- optimize Dockerfile use pre-build builder/runner image to prevent network latency problem (`bitbus/paopao-ce-backend-builder` `bitbus/paopao-ce-backend-runner`) [#265](https://github.com/rocboss/paopao-ce/pull/265)

### Removed

Expand Down
9 changes: 2 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,11 @@ RUN [ $EMBED_UI != yes ] || [ $USE_DIST != no ] || (yarn && yarn build)
RUN [ $EMBED_UI = yes ] || mkdir dist || echo ""

# build backend
FROM golang:1.20-alpine AS backend
FROM bitbus/paopao-ce-backend-builder:latest AS backend
ARG API_HOST
ARG USE_API_HOST=yes
ARG EMBED_UI=yes
ARG USE_DIST=no
RUN apk --no-cache --no-progress add --virtual \
build-deps \
build-base \
git

WORKDIR /paopao-ce
COPY . .
Expand All @@ -28,13 +24,12 @@ ENV GOPROXY=https://goproxy.cn
RUN [ $EMBED_UI != yes ] || make build TAGS='embed go_json'
RUN [ $EMBED_UI = yes ] || make build TAGS='go_json'

FROM alpine:3.17
FROM bitbus/paopao-ce-backend-runner:latest
ARG API_HOST
ARG USE_API_HOST=yes
ARG EMBED_UI=yes
ARG USE_DIST=no
ENV TZ=Asia/Shanghai
RUN apk update && apk add --no-cache ca-certificates && update-ca-certificates

WORKDIR /app/paopao-ce
COPY --from=backend /paopao-ce/release/paopao-ce .
Expand Down
5 changes: 5 additions & 0 deletions scripts/docker/Dockerfile-backend-builder
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
FROM golang:1.20-alpine
RUN apk --no-cache --no-progress add --virtual \
build-deps \
build-base \
git
3 changes: 3 additions & 0 deletions scripts/docker/Dockerfile-backend-runner
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
FROM alpine:3.17
ENV TZ=Asia/Shanghai
RUN apk update && apk add --no-cache ca-certificates && update-ca-certificates
6 changes: 6 additions & 0 deletions scripts/docker/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
### Dockerfile builer pre-build images

```sh
docker build -t bitbus/paopao-ce-backend-builder:latest -f Dockerfile-backend-builder .
docker build -t bitbus/paopao-ce-backend-runner:latest -f Dockerfile-backend-runner .
```

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 1f653a5

Please sign in to comment.