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

cat: /etc/docker/daemon.json: No such file or directory #40

Open
hansehe opened this issue Sep 27, 2024 · 2 comments
Open

cat: /etc/docker/daemon.json: No such file or directory #40

hansehe opened this issue Sep 27, 2024 · 2 comments

Comments

@hansehe
Copy link

hansehe commented Sep 27, 2024

Hi, and first of all, a great package!

But just yesterday, I continuously get this error in the github actions pipeline:

Run docker-practice/actions-setup-docker@master
check docker systemd status
check docker version
add apt source
update apt cache
show available docker version
remove default moby
install docker
check docker version
check docker systemd status
show default daemon json content
  /usr/bin/sudo cat /etc/docker/daemon.json
  cat: /etc/docker/daemon.json: No such file or directory
  Error: Error: The process '/usr/bin/sudo' failed with exit code 1

The job runs on ubuntu-latest, with this setup:

name: CD

on: 
  workflow_dispatch: {}
  push:
    tags: [ 'v*' ]

env:
  DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
  DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}

jobs:
  build:
    runs-on: ubuntu-latest
    strategy:
      matrix:
        docker_channel:
          - stable

    steps:
      - uses: actions/checkout@v2
      - name: Set up Python
        uses: actions/setup-python@v2
      - name: setup Docker
        uses: docker-practice/actions-setup-docker@master
        with:
          docker_channel: ${{ matrix.docker_channel }}
      - name: login to docker hub
        uses: docker/login-action@v1
        with:
          registry: docker.io
          username: ${{ secrets.DOCKER_USERNAME }}
          password: ${{ secrets.DOCKER_PASSWORD }}

      - name: Install requirements
        run: |
          pip install DockerBuildManagement
      
      - name: Publish
        run: |
          dbm -build -publish prod

I think it's a problem with some runners hosted by github, but is there something we can do to handle this?

Best regards.
Hans Erik Heggem

@hansehe
Copy link
Author

hansehe commented Sep 28, 2024

After some experimenting, I tried to downgrade to using ubuntu-22.04 (from ubuntu-latest, which is ubuntu-24.04), and then it all works. So I've posted an issue here:

@korridor
Copy link

We had the same issue. I tried to deactivate experimental with the config of the action, like it is suggested in the linked issue, but that didn't change anything. I wanted to prevent downgrading Ubuntu.

We now replaced this GitHub action with this action: https://github.com/crazy-max/ghaction-setup-docker
It was straightforward to migrate, just changed the uses: property. This action also has the advantage of better versioning.

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

2 participants