Posts

Showing posts from 2024

Obtaining Google Application Credentials for Python Development: A Comprehensive Guide

In this technical tutorial, we will walk you through the process of obtaining Google Application Credentials for Python development on your local machine. These credentials are essential for accessing Google APIs and authenticating your application's interaction with Google services. Step 1: Install Google Cloud CLI Before you begin, ensure that you have the Google Cloud CLI (Command Line Interface) installed on your system. This powerful tool provides a unified interface for interacting with the Google Cloud platform and its services. You can find the installation instructions for your specific operating system in the official documentation . Step 2: Authenticate with Google Cloud Once the Google Cloud CLI is installed, open your terminal window and run the following command: gcloud auth application-default login This command will prompt you to log in to your Google Cloud account. Upon successful authentication, your credentials will be stored in a JSON file in a default locatio...

NGINX Cheat Sheet

Image
  To manage the Nginx web server on a Linux system using systemd (which is used by most modern Linux distributions including Ubuntu), you can use the `systemctl` command. Here are the common commands for starting, stopping, checking the status, and restarting Nginx: 1. **Check the status of the Nginx server**:    ```bash    sudo systemctl status nginx    ```    This command displays the current status of the Nginx server, including whether it is running or not, and recent log entries. 2. **Start the Nginx server**:    ```bash    sudo systemctl start nginx    ```    Use this command to start the Nginx service if it's not already running. 3. **Stop the Nginx server**:    ```bash    sudo systemctl stop nginx    ```    This command stops the Nginx server. It's useful if you need to halt the server for maintenance or any other purpose. 4. **Restart the Nginx server**:...

GitHub Cheat Sheet: Basic Version Control with Git

  GitHub Cheat Sheet: Basic Version Control with Git This cheat sheet provides a quick reference for essential Git commands you'll use for version control on GitHub. Setup: Install Git: Download and install Git from the official website ( https://git-scm.com/downloads ) Configure Git: Run git config --global user.name "Your Name" and git config --global user.email "your_email@example.com" to set your username and email for commits. Working with Repositories: Clone an existing repository: git clone https://github.com/<username>/<repository-name>.git to create a local copy of a remote repository on GitHub. Create a new local repository: git init to initialize a new Git repository in your current directory. Managing Changes: Track changes: git add <filename> to add a specific file to the staging area (where files are prepared for commit). Track a new folder: git add <foldername> to add all files within a folder to the sta...