Web app that predicts the direction of airplane traffic based on the weather report to help homeowners near an airport plan the best days to picnic outside and throw awesome parties in their back yards.
Plane-a-picnic utilizes the open sourced data available on OurAirports to reference runways located worldwide given an airport. A user is able to select an airport and given an airport, the app retrieves a five day forecast for where the airport is located. Using the forecast information, primarily the opposing wind angle, the app predicts and returns the most expected runway to be used each day. With the predicted runway, the user is able to plan on those days better picnic spots.
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.
What things you need to start the web app
npm >= 6.50
aurelia-cli >= 1.0.0
PowerShell Core >= 6.0
.Net Core == 2.1
Azure SQL Database Instance
OpenWeatherMapAPI Key
A step by step series of examples that tell you how to get a development env running
Clone the respository to your local environment
git clone https://github.com/htmercury/plane-a-picnic.git
Navigate into the project directory.
cd plane-a-picnic/plane-a-picnic
Set up your credentials by creating appsettings.json
cat appsettings.json
Format the appsettings.json similar to:
{
"Logging": {
"LogLevel": {
"Default": "Warning"
}
},
"AllowedHosts": "*",
"ConnectionStrings": {
"DefaultConnection": "{CONNECTION_STRING}"
},
"User": "{DB_USER}",
"Password": "{DB_PASS}",
"Server": "{SERVER_URL}",
"OpenWeatherKey": "{API_KEY}"
}
Add initial migrations and update database. (Make sure the DB firewall accepts your IP)
dotnet ef migrations add init
dotnet ef database update
Start powershell core.
pwsh
Import the open source data into your Azure SQL Database.
./importData.ps
Exit powershell core.
exit
Navigate to the aurelia project. (frontend)
cd ClientApp
Install the necessary dependencies.
npm install
Now, everything needed to run the project is installed.
At the project directory (/plane-a-picnic/plane-a-picnic), start up a local backend server.
dotnet run
OR
dotnet watchrun
In another shell window at (/plane-a-picnic/plane-a-picnic/ClientApp), start up a local frontend server.
au run
OR
au run --watch --hmr
Build and transpile the frontend at (/plane-a-picnic/plane-a-picnic/ClientApp).
au build
At the project directory (/plane-a-picnic/plane-a-picnic), start up a local backend server.
dotnet run
OR
dotnet watchrun
At the base directory (/plane-a-picnic), execute
dotnet test
The 15 tests all examine the components of AirportWeatherHandler.cs for expected behavior and accurate predictions based on toy data. The Nunit tests can be found in (/plane-a-picnic/plane-a-picnic.Nunit).
Add additional notes about how to deploy this on a live system. TBD
- Aurelia - Frontend Framework
- .NET Core 2.1 - Backend framework
- Azure SQL Database - DBMS
Distributed under the MIT license. See LICENSE
for more information.
https://github.com/htmercury
- Hat tip to OurAirports for open sourced data on world-wide airports + runways
- Props to OpenWeatherMapAPI for accurate and up-to-date forecast information
- Fork it (https://github.com/htmercury/plane-a-picnic/fork)
- Create your feature branch (
git checkout -b feature/fooBar
) - Commit your changes (
git commit -am 'Add some fooBar'
) - Push to the branch (
git push origin feature/fooBar
) - Create a new Pull Request