GithubHelp home page GithubHelp logo

Comments (3)

crazy-max avatar crazy-max commented on June 15, 2024 1

Your context is really big, almost 14GB:

#7 [2/8] WORKDIR /usr/src/app
#7 DONE 0.6s
#6 [internal] load build context
#6 transferring context: 180.43MB 10.2s
#6 transferring context: 293.10MB 15.2s
#6 transferring context: 407.39MB 20.3s
#6 transferring context: 513.48MB 25.4s
#6 transferring context: 617.43MB 30.5s
#6 transferring context: 806.25MB 35.5s
#6 transferring context: 949.40MB 40.7s
#6 transferring context: 1.11GB 45.9s
#6 transferring context: 1.22GB 51.0s
#6 transferring context: 1.32GB 56.0s
#6 transferring context: 1.41GB 61.0s
#6 transferring context: 1.51GB 66.0s
#6 transferring context: 1.79GB 71.1s
#6 transferring context: 2.19GB 76.2s
#6 transferring context: 2.61GB 81.2s
#6 transferring context: 2.99GB 86.2s
#6 transferring context: 3.47GB 91.3s
#6 transferring context: 3.97GB 96.4s
#6 transferring context: 4.47GB 101.5s
#6 transferring context: 4.95GB 106.5s
#6 transferring context: 5.04GB 111.5s
#6 transferring context: 5.19GB 116.6s
#6 transferring context: 5.31GB 121.8s
#6 transferring context: 5.46GB 126.9s
#6 transferring context: 5.57GB 132.0s
#6 transferring context: 5.72GB 137.0s
#6 transferring context: 5.86GB 142.0s
#6 transferring context: 5.99GB 147.0s
#6 transferring context: 6.10GB 152.2s
#6 transferring context: 6.24GB 157.3s
#6 transferring context: 6.36GB 162.4s
#6 transferring context: 6.48GB 167.4s
#6 transferring context: 6.82GB 172.6s
#6 transferring context: 7.33GB 177.7s
#6 transferring context: 7.92GB 182.8s
#6 transferring context: 8.48GB 187.8s
#6 transferring context: 9.07GB 192.9s
#6 transferring context: 9.61GB 198.1s
#6 transferring context: 10.20GB 203.1s
#6 transferring context: 10.75GB 208.2s
#6 transferring context: 11.19GB 213.3s
#6 transferring context: 11.47GB 218.4s
#6 transferring context: 11.79GB 223.4s
#6 transferring context: 12.08GB 228.4s
#6 transferring context: 12.29GB 233.5s
#6 transferring context: 12.57GB 238.5s
#6 transferring context: 12.84GB 243.6s
#6 transferring context: 13.09GB 248.6s
#6 transferring context: 13.30GB 255.7s done

I guess you're running out of space on the runner.

I also don't have access to https://github.com/orgs/geoapi-pt/root which you're cloning in https://github.com/geoapi-pt/main/blob/bd95fd9240e64ad12a105c92e41eaaa5538195cd/.github/workflows/docker.yml#L55-L60 to check the Dockerfile and I suspect this repo takes more than 14GB. So cloning + uploading context + cache handling would require more than 42GB from what I see.

It "might" work if you're using the docker driver:

      -
        name: Set up Docker Buildx
        uses: docker/setup-buildx-action@v3
        with:
          driver: docker

And disable cache:

      -
        name: Build and push
        uses: docker/build-push-action@v5
        with:
          context: .
          file: ./Dockerfile
          push: true
          tags: ${{ secrets.DOCKER_USERNAME }}/geoapi.pt:latest
          no-cache: true

But there might be an anti-pattern or bad practice in your Dockerfile and workflow as this is unsual to have a context that big. If you can share https://github.com/orgs/geoapi-pt/root that would help to understand.

@tonistiigi Related to COPY command hanging, I don't recall this issue being reported already. Rings a bell?

from build-push-action.

jfoclpf avatar jfoclpf commented on June 15, 2024

Thanks a lot for the quick reply

Yes, the repo is big, thus the top commands to release some space.

The geoapi-pt/root repo is private though very basic, it has only few files like credentials and Dockerfile, which is:

FROM node:16-slim

# Create app directory
WORKDIR /usr/src/app

# Install app dependencies
# A wildcard is used to ensure both package.json AND package-lock.json are copied
# where available (npm@5+)
COPY resources/package*.json ./resources/
COPY main/package*.json ./main/

# RUN npm install
# If you are building your code for production
RUN cd resources && npm ci --omit=dev
RUN cd main && npm ci --omit=dev

RUN npm install pm2 -g

# Bundle app source
COPY . .

ENV NODE_ENV production
EXPOSE 8080
CMD [ "pm2-runtime", "main/src/server/index.js", "--", "--buildFeAssets", "--port", "8080" ]

I will try again with driver: docker and no cache

Thanks again

from build-push-action.

jfoclpf avatar jfoclpf commented on June 15, 2024

Thank you, your suggestion made it work

https://github.com/geoapi-pt/main/actions/runs/8080969130/job/22078477115

from build-push-action.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.