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

hotfix wrong docker arch pull #555

Merged
merged 4 commits into from
Dec 27, 2020
Merged

hotfix wrong docker arch pull #555

merged 4 commits into from
Dec 27, 2020

Conversation

Mevel
Copy link
Contributor

@Mevel Mevel commented Dec 27, 2020

hotfix for wrong arch pull docker image

@Mevel Mevel requested a review from mariusmotea December 27, 2020 18:34
@alexyao2015
Copy link
Member

This won't work... It's a known docker bug (look though my commit history for the bug number). In fact, this will make things worse as you are modifying the base docker image that is applied to every architecture. I have it setup so it correctly pulls the correct architecture when building.

@Mevel
Copy link
Contributor Author

Mevel commented Dec 27, 2020

the fix is not the buster or stable-slim base image. the actual fix is the removal of the lowercase "L" in the manifest annotation. Currently on RPI3 and 2 the docker pulls the wrong arch.

@alexyao2015
Copy link
Member

Again, if you look through the commit history, you will find that I indeed had it that way previously and from multiple bug reports, that didn't work. In fact, I had to manually go an retag everything that way in an effort to fix it. The l at the end is in reference to a potential fix, which doesn't seem to work.

@alexyao2015
Copy link
Member

Also, the changes to the dockerfile appear to be unnecessary as it should be handled by the base image. There also appears to be an apt-get update, which doesn't appear to be necessary.

@Mevel
Copy link
Contributor Author

Mevel commented Dec 27, 2020

The big issue was the wrong pulled arch

Also, the changes to the dockerfile appear to be unnecessary as it should be handled by the base image. There also appears to be an apt-get update, which doesn't appear to be necessary.

Thats correct the architecture is basically handled by the image it was for testing: adding armhf support natively

@alexyao2015
Copy link
Member

Go ahead and merge if you wish to disregard my warnings.

@Mevel
Copy link
Contributor Author

Mevel commented Dec 27, 2020

if you have another idea on how to fix the issue of Raspbian docker pulling the wrong image from docker hub i am all ears! glad you followed the PR

@alexyao2015
Copy link
Member

alexyao2015 commented Dec 27, 2020

It's a known docker bug

There is no fix

@mariusmotea
Copy link
Member

mariusmotea commented Dec 27, 2020

@alexyao2015 today we fight for a few hours with this bug. Too many users where not able to run entertainment effects so i made a test with a raspberry pi and i also was affected. It was good because i was able to test now. After many tests we conclude the issue is on client side that pull the wrong image arch, but this was happening only with diyhue image, not for example with buster-slim. Using the command docker manifest inspect --verbose i was able to see the manifests differences, and only noticiable difference was on the "platform" => "variant".

                     "platform": {
                                "architecture": "arm",
                                "os": "linux",
                                "variant": "v6"
                        }
                },

After we test with same manifest on platform key, docker pull the correct version, so i don't think it can be worst than currently

@alexyao2015
Copy link
Member

I've concluded the same thing a few months back. The issue ultimately led to a known Docker bug. There seems to be no way to fix Docker so it correctly pulls images from the manifest. If users want to use it, I suggest they simply manually pull the correct architecture, which is why individual architecture tags are still available.

@mariusmotea
Copy link
Member

Test this fix, you will see it simply works. This was made after we read more about this issue, is a good workaround.

@alexyao2015
Copy link
Member

alexyao2015 commented Dec 27, 2020

I implemented this fix back in August after multiple bug reports. 6b11738

Ultimately reverting and reapplying the fix over the course of serveral months, leading me to the conclusion that there is simply no way to fix it. 25d837e

I'll leave you to determine what you would best like to do and if you would wish to further pursue this rabbit chase.

@Mevel
Copy link
Contributor Author

Mevel commented Dec 27, 2020

i found those articles quiet useful:

https://github.com/opencontainers/image-spec/blob/79b036d80240ae530a8de15e1d21c7ab9292c693/image-index.md#image-index-property-descriptions

moby/moby#34875 (comment)

Copy link
Member

@mariusmotea mariusmotea left a comment

Choose a reason for hiding this comment

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

Work on my Pi4 and Pi2

@mariusmotea mariusmotea merged commit dfc6c15 into master Dec 27, 2020
mariusmotea added a commit that referenced this pull request Mar 11, 2021
* Update hyperion.py (#526) (#527)

- add "manufacturername"
- add "swversion"
- change light model
this fixes a problem in homeassistant trying to detect the manufacturer of the lights, misinterpreted as OSRAM.
#472

Co-authored-by: juanesf <juanesf91@gmail.com>

* Update README.md

experimental description updated

* Update README.md

* Update README.md

typo fix

* hotfix wrong docker arch pull (#555)

* Update Dockerfile

* add-architecture armhf

* try buster-slim

* remove "l" from arm version

Co-authored-by: Motea Marius <marius.motea@gmail.com>

* Fix #566 (#567)

Signed-off-by: Max Beckenbauer <max.bec92@gmail.com>

* fix: BridgeEmulator/web-ui-src/package.json & BridgeEmulator/web-ui-src/package-lock.json to reduce vulnerabilities (#529)

The following vulnerabilities are fixed with an upgrade:
- https://snyk.io/vuln/SNYK-JS-NODENOTIFIER-1035794

* change Log Level for Deconz to Debug

elevate Loglevel to Debug

* swversion update (#585)

For control over Hue App and full function control

* Fix cert.pem had hardcoded path. It is now expected to reside in the current working directory, which doesn’t change the behaviour in any way, but gives us more flexibility in case we need multiple instances.

Co-authored-by: Motea Marius <marius.motea@gmail.com>
Co-authored-by: juanesf <juanesf91@gmail.com>
Co-authored-by: Mevel <4347330+Mevel@users.noreply.github.com>
Co-authored-by: Max Beckenbauer <max.bec92@gmail.com>
Co-authored-by: Snyk bot <snyk-bot@snyk.io>
Co-authored-by: lnfactionfreddy <66081193+lnfactionfreddy@users.noreply.github.com>
Co-authored-by: Robert von Könemann <lordtaifleh@gmail.com>
mariusmotea added a commit that referenced this pull request Mar 24, 2021
* Update hyperion.py (#526)

- add "manufacturername"
- add "swversion"
- change light model
this fixes a problem in homeassistant trying to detect the manufacturer of the lights, misinterpreted as OSRAM.
#472

* Update hyperion.py (#526) (#527) (#530)

- add "manufacturername"
- add "swversion"
- change light model
this fixes a problem in homeassistant trying to detect the manufacturer of the lights, misinterpreted as OSRAM.
#472

Co-authored-by: juanesf <juanesf91@gmail.com>

Co-authored-by: Motea Marius <marius.motea@gmail.com>
Co-authored-by: juanesf <juanesf91@gmail.com>

* Implement HomeAssistant integration (#523)

Co-authored-by: foxy82 <foxy82.github@gmail.com>

* Add Debug Output Annotation "MQTT: "

* WLED Support (#531)

* Add Debug Output Annotation "MQTT: " (#2)

Co-authored-by: Mevel <4347330+Mevel@users.noreply.github.com>

* WLED support

- wled support by @gmallios
- rebased on HomeAssistant implementation

Co-Authored-By: Gregory Mallios <44323649+gmallios@users.noreply.github.com>

Co-authored-by: Mevel <4347330+Mevel@users.noreply.github.com>
Co-authored-by: Gregory Mallios <44323649+gmallios@users.noreply.github.com>

* update sw version to 1941132080

* Update homeassistant_ws.py (#549)

There is no such key alert in turn_on service. https://www.home-assistant.io/integrations/light/#service-lightturn_on

```voluptuous.error.MultipleInvalid: extra keys not allowed @ data['alert']```

* add option to use custom config path

* add arg description

* fix typo error

* use cwd if config_path not specified

* keep a copy of the certificate also in config path

* remove export folder

* check if srv and dst are not the same

* Return HTTP_PORT from os.getenv() as int (#557)

os.getenv always return a string. (line 90)
Port-number in server_class must be an int (line 1990).

This minor change makes sure that HOST_HTTP_PORT is an int when using environment-variable HTTP_PORT to avoid a crash at startup.

* add Branch select on Install

Choose Branch install promt added.
Choose between MASTER and DEV

* MQTT improvements (TLS, Plugs, Check availability) (#556)

* added more light_types (Lightstripes + Plug)

* MQTT improvements: TLS support, Plugs support, Check availability (if enabled in zigbee2mqtt) for unreachable-state, detect Lighstripes a litte bit more correct

* Changed line encoding for readable diff

* Changed line encoding for readable diff

* Use new astral library

* change Log Level for Deconz to Debug

elevate Loogin.info to logging.debug

* Use dedicted config path on volume mount

* add options in web interface for xiaomi motion sensor

* change default config path

* fix typo, update for openwrt, update host scripts ... (#569)

* update host scripts

- Add zeroconf 0.28.6 to the easy_install and install script (Wled dependency).
- Eliminate unnecessary spaces.
- Add Branch select on easy_install script. (from @Mevel )

* fix typo

- url_pices -> url_pieces
- pices -> pieces

* Fix entertainment stoppage

This fixes an issue stopping Entertainment, which announces that the area is still running.

* Add port reuse

- add reuse of port in entertainment
- add port reuse in scan host

* `is not` is deprecated...

- same as: #566

* Stop script when pressing ctrl-c

- when ctrl-c is pressed the emulator does not stop the script. Adding sys.exit() works

* Update for OpenWrt

- rename OpenWrt service name
- add branch select prompt to OpenWrt
- add zeroconf to OpenWrt

* Update Api and Swversion

- update swversion to 1941132080
- update api version to 1.39.0

* fix indentation error

File "/opt/hue-emulator/HueEmulator3.py", line 2026
    sys.exit()
             ^
TabError: inconsistent use of tabs and spaces in indentation

* Revert "Fix entertainment stoppage"

This reverts commit cc39165.

* Fix cert.pem had hardcoded path.  (#593)

* Update hyperion.py (#526) (#527)

- add "manufacturername"
- add "swversion"
- change light model
this fixes a problem in homeassistant trying to detect the manufacturer of the lights, misinterpreted as OSRAM.
#472

Co-authored-by: juanesf <juanesf91@gmail.com>

* Update README.md

experimental description updated

* Update README.md

* Update README.md

typo fix

* hotfix wrong docker arch pull (#555)

* Update Dockerfile

* add-architecture armhf

* try buster-slim

* remove "l" from arm version

Co-authored-by: Motea Marius <marius.motea@gmail.com>

* Fix #566 (#567)

Signed-off-by: Max Beckenbauer <max.bec92@gmail.com>

* fix: BridgeEmulator/web-ui-src/package.json & BridgeEmulator/web-ui-src/package-lock.json to reduce vulnerabilities (#529)

The following vulnerabilities are fixed with an upgrade:
- https://snyk.io/vuln/SNYK-JS-NODENOTIFIER-1035794

* change Log Level for Deconz to Debug

elevate Loglevel to Debug

* swversion update (#585)

For control over Hue App and full function control

* Fix cert.pem had hardcoded path. It is now expected to reside in the current working directory, which doesn’t change the behaviour in any way, but gives us more flexibility in case we need multiple instances.

Co-authored-by: Motea Marius <marius.motea@gmail.com>
Co-authored-by: juanesf <juanesf91@gmail.com>
Co-authored-by: Mevel <4347330+Mevel@users.noreply.github.com>
Co-authored-by: Max Beckenbauer <max.bec92@gmail.com>
Co-authored-by: Snyk bot <snyk-bot@snyk.io>
Co-authored-by: lnfactionfreddy <66081193+lnfactionfreddy@users.noreply.github.com>
Co-authored-by: Robert von Könemann <lordtaifleh@gmail.com>

* fix bug: color temp lights are added as dimmable

* fix conflict

* update swversion to version 1943185030

* Fix file error

Co-authored-by: juanesf <juanesf91@gmail.com>
Co-authored-by: Mevel <4347330+Mevel@users.noreply.github.com>
Co-authored-by: foxy82 <neil.renaud@gmail.com>
Co-authored-by: foxy82 <foxy82.github@gmail.com>
Co-authored-by: Gregory Mallios <44323649+gmallios@users.noreply.github.com>
Co-authored-by: zewelor <zewelor@gmail.com>
Co-authored-by: Heikki Henriksen <heikkih@gmail.com>
Co-authored-by: crietzschel <35508091+crietzschel@users.noreply.github.com>
Co-authored-by: U-PAYPOINT\MoteaM <MariusMotea@paypoint.com>
Co-authored-by: Robert von Könemann <vKnmnn@users.noreply.github.com>
Co-authored-by: Max Beckenbauer <max.bec92@gmail.com>
Co-authored-by: Snyk bot <snyk-bot@snyk.io>
Co-authored-by: lnfactionfreddy <66081193+lnfactionfreddy@users.noreply.github.com>
Co-authored-by: Robert von Könemann <lordtaifleh@gmail.com>
@mariusmotea mariusmotea deleted the ex-arch branch March 22, 2022 16:52
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

Successfully merging this pull request may close these issues.

3 participants