Skip to content

distro: alpine: consolidate EXTRA_INDEX_URL#361

Merged
sairon merged 1 commit into
home-assistant:masterfrom
eshattow:consolidate-alpine-extra-index-url
Apr 23, 2026
Merged

distro: alpine: consolidate EXTRA_INDEX_URL#361
sairon merged 1 commit into
home-assistant:masterfrom
eshattow:consolidate-alpine-extra-index-url

Conversation

@eshattow
Copy link
Copy Markdown
Contributor

  • add required EXTRA_INDEX_URL docker build ARG to alpine distro Dockerfile and workflow
  • alpine docker image refers corresponding pip and uv env variables to EXTRA_INDEX_URL as built
  • drop now-redundant config file definition of pip extra-index-url from alpine rootfs

@eshattow
Copy link
Copy Markdown
Contributor Author

Please review carefully before merging, I am not sure how this will interact with S6. The objective is have control of the build-time extra wheels index url configuration within the workflow instead of spread out over several files.

@eshattow eshattow force-pushed the consolidate-alpine-extra-index-url branch from 840f11d to bd6bc2e Compare April 23, 2026 00:03
Copy link
Copy Markdown
Member

@sairon sairon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally LGTM, but there are some fundamental issues of the current validation and passing of the arg, see below.

I don't know what interactions with S6 it could have - do you have some particular in mind?

Comment thread alpine/Dockerfile Outdated
Comment thread alpine/Dockerfile
@home-assistant home-assistant Bot marked this pull request as draft April 23, 2026 11:52
@home-assistant
Copy link
Copy Markdown

Please take a look at the requested changes, and use the Ready for review button when you are done, thanks 👍

Learn more about our pull request process.

@eshattow eshattow force-pushed the consolidate-alpine-extra-index-url branch 2 times, most recently from ae68de7 to 148d60d Compare April 23, 2026 12:51
* Introduce ARG EXTRA_INDEX_URL to alpine docker build and import in final
alpine distro output image as PIP_EXTRA_INDEX_URL and UV_EXTRA_INDEX_URL
runtime environment variables

* Remove now-redundant config file definition of extra-index-url from
  alpine docker rootfs

* No change to https://wheels.home-assistant.io/musllinux-index/ default
  in final alpine distro output image, may override as-built value in the
  usual way setting build-args from build workflow
@eshattow eshattow force-pushed the consolidate-alpine-extra-index-url branch from 148d60d to 4d8c99a Compare April 23, 2026 12:52
@eshattow eshattow marked this pull request as ready for review April 23, 2026 12:52
@home-assistant home-assistant Bot requested a review from sairon April 23, 2026 12:52
@eshattow
Copy link
Copy Markdown
Contributor Author

Generally LGTM, but there are some fundamental issues of the current validation and passing of the arg, see below.

I don't know what interactions with S6 it could have - do you have some particular in mind?

None, just my ignorance as I have no experience with what "S6" is and the previously existing comment says that these environment variables exist to support it. The only thought I have about how this could break is if some user of this depends on being able to provide both an extra-wheels-index and an env variable for this value simultaneously, which although I find unlikely or not the situation as-is, I want to be sure this is not going to break for users.

Assuming you're okay with the requested changes as implemented, I have no additional concerns. Thanks for reviewing!

Copy link
Copy Markdown
Member

@sairon sairon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good now, image only has two layers and the environment is set correctly:

"Config": {
    "Env": [
        "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
        "LANG=C.UTF-8",
        "S6_BEHAVIOUR_IF_STAGE2_FAILS=2",
        "S6_CMD_WAIT_FOR_SERVICES_MAXTIME=0",
        "S6_CMD_WAIT_FOR_SERVICES=1",
        "S6_SERVICES_READYTIME=50",
        "PIP_EXTRA_INDEX_URL=https://wheels.home-assistant.io/musllinux-index/",
        "UV_EXTRA_INDEX_URL=https://wheels.home-assistant.io/musllinux-index/"
    ],
...

Thanks!

@sairon sairon merged commit 19b37ae into home-assistant:master Apr 23, 2026
66 checks passed
@eshattow eshattow deleted the consolidate-alpine-extra-index-url branch April 23, 2026 13:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants