Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a devcontainer.json for all Dependency Needs. #184

Open
3 tasks
Welding-Torch opened this issue Sep 16, 2023 · 1 comment
Open
3 tasks

Add a devcontainer.json for all Dependency Needs. #184

Welding-Torch opened this issue Sep 16, 2023 · 1 comment

Comments

@Welding-Torch
Copy link

Issue Description

I propose adding a devcontainer.json file to the Our Tech Community repository. This file will enable developers to set up a consistent development environment quickly using GitHub Codespaces or other similar services.

Why is this needed?

A devcontainer.json file:

  • Standardizes development environments across team members, reducing configuration discrepancies.
  • Simplifies onboarding for new contributors.
  • Ensures that the project's dependencies and tools are isolated, avoiding conflicts with the developer's local environment.
  • Facilitates automated testing and continuous integration.

Proposed Changes

  • Create a devcontainer directory in the root of the repository.
  • Add a devcontainer.json file to the devcontainer directory, specifying the necessary development environment setup.
  • Update the README with instructions for using the development container.

Additional Information

  • There is already a .gitpod.yml file that mentions the dependencies. But the devcontainer.json format is more widely used and is supported by more platforms.
  • If you have any additional context, ideas, or suggestions, please feel free to share them here.

🤍 Thank you, OTC.

@Welding-Torch
Copy link
Author

Code for devcontainer.json (Suggested Code)

Learn Development Containers: https://containers.dev/
Development Container For Ruby: https://github.com/devcontainers/images/tree/main/src/ruby

devcontainer.json

{
  "image": "mcr.microsoft.com/devcontainers/ruby",
  "features": {
    "ghcr.io/devcontainers/features/node:1": {}
  },
  "customizations": {
    "vscode": {
      "extensions": [
        "asciidoctor.asciidoctor-vscode",
        "mikestead.dotenv",
        "redhat.vscode-yaml",
        "streetsidesoftware.code-spell-checker"
      ]
    }
  },
  "postCreateCommand": "sh postCreateCommand.sh",
  "forwardPorts": [5000]
}

postCreateCommand.sh

gem install asciidoctor
cp sample.env .env
npm install
exit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant