Skip to content

akin0ri/python3-devcontainer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 

Repository files navigation

Python Devcontainer Environment with Docker

This repository contains a Docker-based development environment for Python projects. It provides a consistent and isolated environment for Python development, ensuring that all team members use the same dependencies and configurations.

Prerequisites

Visual Studio Code Extention Package

  • Dev Containers
    • Remote Development with Dev Containers included is also OK.

Getting Started

  1. Clone this repository to your local machine:

    git clone <this repository url>
  2. Navigate to the project directory:

    cd <project_directory>
  3. Enter the required pip package in the requirements.txt file in the .devcontainer folder example:

    numpy==1.26.0
    pandas=>2.2.0
  4. Press ctrl + shift + p to select >Dev Containers: rebuild and reopen in container

  5. Wait a little....

How to change remote repositories for development

  1. Create a new repository on GitHub.

  2. In your local environment, use the following command to check the information of the current remote repository:

    git remote -v
  3. Change the remote repository to the new GitHub repository. Use the following command to change the remote URL:

    git remote set-url origin <your_new_github_repository>
  4. Push the changes.

    git push origin main

    (Or use the branch name corresponding to the main branch)

  5. Refresh the repository page on GitHub to reflect the changes.

Directory Structure

The directory structure of this project is as follows:

project_root/
│
├── .devcontainer/
│   ├── Dockerfile
│   ├── devcontainer.json
│   └── requirements.txt
│
│── .gitignore
│
│── LICENSE.txt
│── README.md
│
├── other_project_files...
  • .devcontainer/: Contains Docker configuration files.

    • Dockerfile: Defines the Docker image for the development environment.
    • devcontainer.json: Configuration file for Visual Studio Code Remote Development.
    • requirements.txt: File containing Python dependencies for the project.
  • .gitignore: This file allows you to specify files or directories to exclude from Git tracking.

Contributing

If you encounter any issues or have suggestions for improvements, please feel free to open an issue or submit a pull request.

About

python3.10 devcontainer sample file

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published