DEV Community

Cover image for WEATHER DASHBOARD
Oluwaseun Olaleye
Oluwaseun Olaleye

Posted on

3

WEATHER DASHBOARD

USE CASE
My manager tasked me with creating a weather dashboard and storing it in an s3 bucket using weather API and python.

PREREQUISITES

  • Linux commands

  • Ubuntu server

  • AWS free tier account.

  • AWS CLI

Let's dive into it.

Firstly, I commenced by cloning a GitHub repository from https://github.com/ShaeInTheCloud/30days-weather-dashboard. This step enabled me to obtain a local copy of the repository's codebase.
Image description

Next. I installed all dependencies including Python. Then, I activated a virtual environment to isolate the project dependencies. With the virtual environment activated, i proceeded to install pip, Python package installer to facilitate the installation of additional project dependencies.

Image description

Image description

Image description

Image description

AWS Command Line Interface
Next, I installed the AWS CLI on my ubuntu server https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html. Additionally, I created a new IAM user and generated access keys for that user. I then utilized those credentials to configure the AWS CLI.

Image description

Image description

Image description

Image description

Image description

Image description

Image description

Image description

Next, I used the Weather API to retrieve current weather conditions and forecasts. After retrieving the weather data, I processed it into a JSON format and stored it in a python dictionary. I then used the boto3 library to upload the data to an S3 bucket.

Image description

Image description

Image description

After executing the code, I verified the creation of the S3 bucket and confirmed that it had been successfully established.

Image description

Image description

CONCLUSION
I successfully created a weather dashboard utilizing python and the Weather API , and subsequently stored the weather forecast data to amazon S3 bucket.

Billboard image

Deploy and scale your apps on AWS and GCP with a world class developer experience

Coherence makes it easy to set up and maintain cloud infrastructure. Harness the extensibility, compliance and cost efficiency of the cloud.

Learn more

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

Dive into an ocean of knowledge with this thought-provoking post, revered deeply within the supportive DEV Community. Developers of all levels are welcome to join and enhance our collective intelligence.

Saying a simple "thank you" can brighten someone's day. Share your gratitude in the comments below!

On DEV, sharing ideas eases our path and fortifies our community connections. Found this helpful? Sending a quick thanks to the author can be profoundly valued.

Okay