Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/unfor19/github-copilot-starter
https://github.com/unfor19/github-copilot-starter
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/unfor19/github-copilot-starter
- Owner: unfor19
- Created: 2024-07-09T05:14:39.000Z (4 months ago)
- Default Branch: main
- Last Pushed: 2024-07-09T12:37:21.000Z (4 months ago)
- Last Synced: 2024-07-10T15:55:40.407Z (4 months ago)
- Language: Dockerfile
- Size: 2.93 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# github-copilot-starter
This is a starter project for GitHub Copilot.
## Goals
- The application will send a request to [catninja api](https://catfact.ninja/fact)
- The application will run as a web server using Flask - will server on http://localhost:8080
- The application will get a request to `GET /` and return the cat random fact from the `catninja api` by using the `requests` python package to send a request to the `catninja api`
- We are going to use venv for Virtual Environment `.VENV` dir
- The app requires Python to run
- The app will be wrapped with Docker (Dockerfile)## Requirements
- Python 3.6+
- Docker## Setup
Initial setup to run this application:
1. Clone this repository
1. Create a virtual environment
```bash
python -m venv .VENV
```
2. Activate the virtual environment
```bash
source .VENV/bin/activate
```
3. Install the dependencies
```bash
pip install -r requirements.txt
```## Docker
1. Build the docker image
```bash
docker build -t copilot-starter .
```
1. Run the docker container
```bash
docker run -p 8080:8080 copilot-starter
```
1. Run container with env var `MOCK_RESPONSE`
```bash
docker run -p 8080:8080 -e MOCK_RESPONSE=True copilot-starter
```