Skip to content

Commit

Permalink
🎉 初始化提交
Browse files Browse the repository at this point in the history
  • Loading branch information
lltx committed Apr 28, 2024
1 parent fe12657 commit 1438946
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 13 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/mage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# This workflow will build a Java project with Maven
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven

name: PIG 镜像 action

on:
push:
branches: [ master ]

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Login to Docker Registry
run: docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }} registry.cn-hangzhou.aliyuncs.com

- name: Build and push Docker images
run: |
docker build . -t ocr:latest
docker tag ocr:latest registry.cn-hangzhou.aliyuncs.com/pigx/ocr:latest
docker push registry.cn-hangzhou.aliyuncs.com/pigx/ocr:latest
4 changes: 0 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,6 @@ ARG DEBIAN_FRONTEND=noninteractive

COPY model/ ~/.cnocr/2.3/

COPY . /tmp/

RUN mv /tmp/sources.list /etc/apt/sources.list

RUN apt-get update && apt-get install -y python3-opencv libglib2.0-0 libsm6 libxext6 libxrender-dev && rm -rf /var/lib/apt/lists/*

RUN pip install -U pip && pip install onnxruntime && pip install cnocr[serve] --index-url https://mirrors.aliyun.com/pypi/simple
Expand Down
9 changes: 0 additions & 9 deletions sources.list

This file was deleted.

0 comments on commit 1438946

Please sign in to comment.