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

container build failed ! #51

Open
ravikumargrk opened this issue Apr 25, 2023 · 3 comments · May be fixed by #52
Open

container build failed ! #51

ravikumargrk opened this issue Apr 25, 2023 · 3 comments · May be fixed by #52

Comments

@ravikumargrk
Copy link

I have created a codespace and built container using your .devcontainer config untouched.
build has failed.

@ncvescera
Copy link
Collaborator

I have created a codespace and built container using your .devcontainer config untouched. build has failed.

Hallo 🌈
thank you for your feedback. I'll check ASAP.

Could you attach the error message ?
Are you on Linux, Windows, MacOS ?

@ncvescera
Copy link
Collaborator

@ravikumargrk I found the problem.

When you are creating and using a Github Codespace, there are no files like ~/.gitconfig, ~/.ssh, etc.

Try with commenting all the volumes inside the docker-compose.yml file (except for ../ and /var/run/docker.sock).
The following code should works:

version: "3.2"

services:
  vscode:
    build: .
    image: latexdevcontainer
    volumes:
      - ../:/workspace
      # Docker socket to access Docker server
      - /var/run/docker.sock:/var/run/docker.sock
      # SSH directory
      # - ~/.ssh:/root/.ssh
      # For Windows without WSL, a copy will be made
      # from /tmp/.ssh to ~/.ssh to fix permissions
      # - ~/.ssh:/tmp/.ssh:ro
      # Shell history persistence
      # - ~/.zsh_history:/root/.zsh_history:z
      # Git config
      # - ~/.gitconfig:/root/.gitconfig
    environment:
      - TZ=
    entrypoint: ["zsh", "-c", "while sleep 1000; do :; done"]

@ncvescera
Copy link
Collaborator

@qdm12 should we add this to the README ?
A subsection inside 'More' section maybe ?

ncvescera added a commit that referenced this issue May 10, 2023
Added a subsection of 'Setup for a project' named 'Run inside GihHub Codespaces'
in where is explained how to setup the devcontainer inside a GitHub Codespace.

Fix #51
@ncvescera ncvescera linked a pull request May 10, 2023 that will close this issue
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

Successfully merging a pull request may close this issue.

2 participants