Skip to content
This repository has been archived by the owner on Dec 14, 2023. It is now read-only.

Cron to rebuild base Docker image #775

Open
jtotoole opened this issue Mar 4, 2021 · 1 comment
Open

Cron to rebuild base Docker image #775

jtotoole opened this issue Mar 4, 2021 · 1 comment

Comments

@jtotoole
Copy link
Contributor

jtotoole commented Mar 4, 2021

At present, we sometimes find ourselves unable to build certain containers because our base image doesn't change much, and consequently isn't rebuilt very often. That means that the apt package links occasionally 404 as a result of old packages getting removed from the repository when new ones become available (additional context here).

One way to solve this problem would be to create a cron to rebuild the base image daily or weekly.

@pypt
Copy link
Contributor

pypt commented Mar 5, 2021

Just to reiterate, this is "someday / nice to have" task.

Some notes:

  • GitHub Workflows support scheduled jobs: https://docs.github.com/en/actions/reference/events-that-trigger-workflows#scheduled-events

  • We're supposedly limited to 2000 Action minutes/month but I think in our case they're effectively unlimited for some reason? Is this limit for private repos only?

  • Easy way to trigger the base image rebuild would be to print out the docker pull commands instead of running them directly from the ./dev/pull.py script, grep out the base containers (being careful to leave others that might be matching the base string), and pull only those, i.e. instead of:

    ./dev/pull.py
    

    one can do something like:

    ./dev/pull.py -p | grep -v '/base' | bash
    

    (We're reverse-grepping for slash-base here so that it doesn't match images such as solr-base.)

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

No branches or pull requests

2 participants