From aab62e4b0396338fbaf6f48caabbc505fff194ae Mon Sep 17 00:00:00 2001 From: Davidson Gomes Date: Wed, 3 Jul 2024 17:25:38 -0300 Subject: [PATCH] chore: Update CHANGELOG, Dockerfile and add CI workflow for publishing latest Docker image - Update CHANGELOG.md to include the new Docker workflow - Update Dockerfile to improve the build process - Add a new GitHub Actions workflow (.github/workflows/publish\_docker\_image\_latest.yml) to publish the latest Docker image on push to the 'v2.0.0' branch This change allows for easier deployment of the latest version of the application, with an updated Dockerfile and a new GitHub Actions workflow to handle publishing the Docker image. --- .../workflows/publish_docker_image_latest.yml | 48 +++++++++++++++++++ CHANGELOG.md | 14 ++++-- Dockerfile | 4 +- 3 files changed, 61 insertions(+), 5 deletions(-) create mode 100644 .github/workflows/publish_docker_image_latest.yml diff --git a/.github/workflows/publish_docker_image_latest.yml b/.github/workflows/publish_docker_image_latest.yml new file mode 100644 index 00000000..641dc5e0 --- /dev/null +++ b/.github/workflows/publish_docker_image_latest.yml @@ -0,0 +1,48 @@ +name: Build Docker image + +on: + push: + branches: + - main + +jobs: + build_deploy: + name: Build and Deploy + runs-on: ubuntu-latest + permissions: + contents: read + packages: write + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Docker meta + id: meta + uses: docker/metadata-action@v5 + with: + images: atendai/evolution-api + tags: latest + + - name: Set up QEMU + uses: docker/setup-qemu-action@v3 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + + - name: Login to Docker Hub + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + + - name: Build and push + id: docker_build + uses: docker/build-push-action@v5 + with: + platforms: linux/amd64,linux/arm64 + push: true + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} + + - name: Image digest + run: echo ${{ steps.docker_build.outputs.digest }} diff --git a/CHANGELOG.md b/CHANGELOG.md index 9cd44e6f..6cc39875 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -36,14 +36,22 @@ - KeepOpen configuration (keeps the session even when the bot ends, to run once per contact) - StopBotFromMe configuration, allows me to stop the bot if I send a chat message. -# 1.8.1 (develop) +# 1.8.2 (2024-07-03 13:50) + +### Fixed + +* Corretion in globall rabbitmq queue name +* Improvement in the use of mongodb database for credentials +* Fixed base64 in webhook for documentWithCaption +* Fixed Generate pairing code + +# 1.8.1 (2024-06-08 21:32) ### Feature * New method of saving sessions to a file using worker, made in partnership with [codechat](https://github.com/code-chat-br/whatsapp-api) -* Caching system for group data -### Fixes +### Fixed * Correction of variables breaking lines in typebot diff --git a/Dockerfile b/Dockerfile index f2db602b..4a9b2c36 100644 --- a/Dockerfile +++ b/Dockerfile @@ -11,7 +11,7 @@ WORKDIR /evolution COPY ./package.json ./tsconfig.json ./ -RUN npm install +RUN npm install --no-cache COPY ./src ./src COPY ./public ./public @@ -39,7 +39,7 @@ WORKDIR /evolution COPY --from=builder /evolution/package.json ./package.json COPY --from=builder /evolution/package-lock.json ./package-lock.json -RUN npm install --omit=dev +RUN npm install --omit=dev --no-cache COPY --from=builder /evolution/dist ./dist COPY --from=builder /evolution/prisma ./prisma