Skip to content

Latest commit

 

History

History
87 lines (65 loc) · 2.4 KB

File metadata and controls

87 lines (65 loc) · 2.4 KB

Fantasy Football Metrics Weekly Report Deployment

  1. (Optional) Clear virtual machine of old requirements:

    pip uninstall -y -r <(pip freeze)
  2. (Optional) Check requirements.txt and requirement-dev.txt for latest dependency versions.

  3. (Optional) Update virtual machine with the latest dependencies:

    pip install -r requirements.txt -r requirements-dev.txt
  4. (Optional) Lint code with flake8:

    flake8 . --count --show-source --statistics
  5. (Optional) Check code security with bandit:

    bandit -r .
  6. (Optional) Run all pytest tests:

    python -m pytest
  7. (Optional) Run all pytest tests verbosely:

    python -m pytest -v -s
  8. (Optional) Test Python support using act for GitHub Actions:

    act -j build

    Note: If act is unable to locate Docker, make sure that the required /var/run/docker.sock symlink exists. If it does not, you can fix it by running:

    sudo ln -s "$HOME/.docker/run/docker.sock" /var/run/docker.sock`
  9. Update the Docker compose.yaml file with the latest version of the app.

  10. Build and push a new Docker image for the app (see DEPLOYMENT.md).

  11. (Optional) Create a new git branch if creating a release:

    git checkout -b release/vX.X.X
  12. Create a git commit:

    git add .
    git commit -m 'commit message'
  13. Update the git tag (format: git tag -a [tag_name/version] -m [message]):

    git tag -a v1.0.0 -m 'first release'
    git push origin --tags
  14. (Optional) View git tags:

    git tag -l --sort=v:refname -n99
  15. Update fantasy-football-metrics-weekly-report GitHub repository:

    • (Optional) If creating a release:

      git push -u origin release/vX.X.X
    • If updating main:

      git push
  16. Open a pull request (PR) with the release/vX.X.X branch, allow GitHub actions to complete successfully, draft release notes, and merge it.

  17. Go to the FFMWR Releases page and draft a new release using the above git tag.