kevinthedang / discord-ollama

Discord Bot that utilizes Ollama to interact with any Large Language Models to talk with users and allow them to host/create their own models.
Creative Commons Attribution 4.0 International
45 stars 5 forks source link

CI/CD Pipeline for Production Validation #24

Closed JT2M0L3Y closed 1 month ago

JT2M0L3Y commented 3 months ago

Feature

Thoughts

kevinthedang commented 3 months ago

Going to mention #14 as this will be a replacement for it to ensure the production version is working as intended

We still could use code coverage so we can even reopen the issue as needed in the future

JT2M0L3Y commented 3 months ago

Continuous Deployment (CD)

With the intention of having this tool run autonomously, having little or no intervention needed, it would be nice to have a workflow that deploys this bot and all its dependencies over to hosting server.

Ideally, this would involve scp or ssh to transfer the files between the workflow runner and the hosting server.

Requirements

JT2M0L3Y commented 3 months ago

GitHub Docs has a number of available endpoints for pulling a version of the project over to a server. Namely, a "Get the latest release" API endpoint at this link.

kevinthedang commented 2 months ago

@JT2M0L3Y

Another thing to consider is having some tests to run on Pull Request so the branch can be validated for the next released feature it has. Go here

PR that was Merged

on:
  pull_request:
    types:
      - closed

jobs:
  if_merged:
    if: github.event.pull_request.merged == true
    runs-on: ubuntu-latest
    steps:
    - run: |
        echo The PR was merged

PR that was Opened based on name and files

on:
  pull_request:
    types:
      - opened
    branches:
      - 'releases/**'
    paths:
      - '**.js'

Reviewed Pull Request

on:
  pull_request_review:
    types: [submitted]

jobs:
  approved:
    if: github.event.review.state == 'APPROVED'
    runs-on: ubuntu-latest
    steps:
      - run: echo "This PR was approved"