# Upgrade gitea docker container failed, ran out of disk space

**URL:** <https://forum.gitea.com/t/upgrade-gitea-docker-container-failed-ran-out-of-disk-space/3054>\
**Category:** Install/Maintain/Configure\
**Created:** [March 10, 2021, 2:33am UTC](https://forum.gitea.com/t/upgrade-gitea-docker-container-failed-ran-out-of-disk-space/3054 "2021-03-10T02:33:44Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![davehouser1](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.gitea.com/davehouser1/32/1193_2.png) [@davehouser1](https://forum.gitea.com/u/davehouser1)\
**Post date:** [March 10, 2021, 2:33am UTC](https://forum.gitea.com/t/upgrade-gitea-docker-container-failed-ran-out-of-disk-space/3054/1 "2021-03-10T02:33:44Z")

</div>

I have a docker-compose file that runs our ci env. Included are many containers (Docker repo, drone, drone runner, postgress, gitea). We are currently running version 1.12, I want to pull the latest and rebuild.

**Process:**  
docker-compose stop  
docker-compose pull gitea  
docker-compose up --build

**Problem:**  
Stuck on the “Building gitea” after running the build command. Doing a “df -H” shows that I have 0 disk space.

**Trouble shooting:**

- I ran system prune, and volume prune, this freed up 60 gigs
- The system sits on a 200gig hard drive, 100gigs of which were being used. So before my build I had around 100gigs of space available. I also checked (and think) gitea only uses around 4 gigs of space, not sure if this is true.
- Docker file currently has gitea set to use “latest”

Why is gitea build filling up the hard drive?  
Is there a proper way to upgrade only the gitea container image?

---

<div class="post-metadata">

**Author:** ![techknowlogick](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.gitea.com/techknowlogick/32/4706_2.png) [@techknowlogick](https://forum.gitea.com/u/techknowlogick)\
**Post date:** [March 11, 2021, 7:15am UTC](https://forum.gitea.com/t/upgrade-gitea-docker-container-failed-ran-out-of-disk-space/3054/2 "2021-03-11T07:15:11Z")

</div>

It really shouldn’t fill up your drive since our images are only ~60mb: [Docker Hub](https://hub.docker.com/r/gitea/gitea/tags?page=1&ordering=last_updated)

---

<div class="post-metadata">

**Author:** ![davehouser1](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.gitea.com/davehouser1/32/1193_2.png) [@davehouser1](https://forum.gitea.com/u/davehouser1)\
**Post date:** [April 15, 2021, 4:48pm UTC](https://forum.gitea.com/t/upgrade-gitea-docker-container-failed-ran-out-of-disk-space/3054/3 "2021-04-15T16:48:20Z")

</div>

Still having this issue, but at this point I need to rebuild to apply new certs.  
I did a “docker system prune -a”, 78GB were remove. So now the server is a total of 208GB, and 100GB is currently being used, most of which were the docker-registry I configured in the past.  
I disabled building the docker-registry in my docker-compose file, not sure its related as “docker-compose build”, is hung on “building gitea”. I am watching “df -H”, and the hard drive just fills up to capacity (Over 100GB), and nothing happens.

Here is the section for gitea in my docker-compose

```auto
services:
  gitea:
    build:
      context: ./
      dockerfile: services/gitea/gitea.Dockerfile
    volumes:
      - ./services/gitea/data:/data
      - /etc/timezone:/etc/timezone:ro
      - /etc/localtime:/etc/localtime:ro
    ports:
      - 10.10.10.10:22:22
      - 10.10.10.10:80:3080
      - 10.10.10.10:443:3443
    environment:
      - USER_UID=1000
      - USER_GID=1000
      - DB_TYPE=postgres
      - DB_HOST=postgres:5432
      - DB_NAME=mruser
      - DB_USER=mruser
      - DB_PASSWD=mypassword

```

I checked “./services/gitea/data” size with du, its only 4GB. Why does this take so long / wont build?
