From 6c4d393bb9c784eecef6182eb11cee7c1ef83f4f Mon Sep 17 00:00:00 2001 From: Abhijeet Mazumdar <99800329+abhimazu@users.noreply.github.com> Date: Sat, 27 Apr 2024 22:51:50 -0400 Subject: [PATCH] Update README.md --- README.md | 46 +++++++++++++++++++++++----------------------- 1 file changed, 23 insertions(+), 23 deletions(-) diff --git a/README.md b/README.md index 7cd0ab5..907df4a 100644 --- a/README.md +++ b/README.md @@ -92,14 +92,14 @@ Automated tests are run separately for both the server and client using pytest t ``` - name: Run tests in Server - run: | - cd server - pytest - - - name: Run tests in Client - run: | - cd client - pytest + run: | + cd server + pytest + +- name: Run tests in Client + run: | + cd client + pytest ``` 2. ### Docker Build for Server @@ -108,26 +108,26 @@ Automated tests are run separately for both the server and client using pytest t - **Process**: Builds a Docker image from the Dockerfile located in the server directory. This ensures that the server can be containerized consistently with every change. ``` - - name: Build Docker Image for Server - run: | - if [ -d "server/" ]; then - cd server - docker build -t fastapi-server . - fi - - - name: Run Docker Container - if: ${{ github.workspace }}/server - run: | - docker run -d -p 8000:8000 fastapi-server +- name: Build Docker Image for Server + run: | + if [ -d "server/" ]; then + cd server + docker build -t fastapi-server . + fi + +- name: Run Docker Container + if: ${{ github.workspace }}/server + run: | + docker run -d -p 8000:8000 fastapi-server ``` - **Uploads to Docker Registry**: Logs in to the configured Dockerhub account and uploads the successfully tested image to the registry with the **:latest** tag - ``` - name: Docker login - uses: docker/login-action@v1 - with: - username: ${{ secrets.DOCKER_USERNAME }} - password: ${{ secrets.DOCKER_PASSWORD }} + uses: docker/login-action@v1 + with: + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} - name: Push Docker image to registry run: |