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

VIC Appliance API 502 Bad Gateway #8651

Open
Texnomic opened this issue Dec 6, 2020 · 3 comments
Open

VIC Appliance API 502 Bad Gateway #8651

Texnomic opened this issue Dec 6, 2020 · 3 comments

Comments

@Texnomic
Copy link

Texnomic commented Dec 6, 2020

Summary

All API Calls to VIC Appliance responds with 502 Bad Gateway. Tried to restart multiple times.

vSphere and vCenter Server version

7.0

VIC version

v1.5.6-7849-bd6fe58a

@samized
Copy link

samized commented Jan 12, 2021

Same issue, it seems the registry is in a restart loop because of:
goharbor/harbor#11633

Jan 12 16:07:18 192.168.128.1 registry[344]: Changing password for root.
Jan 12 16:07:18 192.168.128.1 registry[344]: sudo: a terminal is required to read the password; either use the -S option to read from standard input or configure an askpass helper
Jan 12 16:07:18 192.168.128.1 registry[344]: sudo: unable to change expired password: Authentication token manipulation error
Jan 12 16:08:19 192.168.128.1 registry[344]: sudo: Account or password is expired, reset your password and try again
Jan 12 16:08:19 192.168.128.1 registry[344]: Changing password for root.
Jan 12 16:08:19 192.168.128.1 registry[344]: sudo: a terminal is required to read the password; either use the -S option to read from standard input or configure an askpass helper
Jan 12 16:08:19 192.168.128.1 registry[344]: sudo: unable to change expired password: Authentication token manipulation error
Jan 12 16:09:19 192.168.128.1 registry[344]: sudo: Account or password is expired, reset your password and try again
Jan 12 16:09:19 192.168.128.1 registry[344]: Changing password for root.
Jan 12 16:09:19 192.168.128.1 registry[344]: sudo: a terminal is required to read the password; either use the -S option to read from standard input or configure an askpass helper
Jan 12 16:09:19 192.168.128.1 registry[344]: sudo: unable to change expired password: Authentication token manipulation error

@samized
Copy link

samized commented Jan 20, 2021

My Workaround:
Extract Harbor Pre-release offline artifact:
https://github.com/goharbor/harbor/releases/tag/v1.7.8-rc1
Import images on VIC Appliance:
docker load -i ./harbor*.tar.gz
Edit docker-compose.yml on VIC Appliance to use fixed images
vi /etc/vmware/harbor/docker-compose.yml

@gdesoto-lhs
Copy link

Thanks @samized !

To fill a couple of the blanks, here's the steps I went through. Not sure if it was all necessary, but it seems to be working now.

  1. Download 1.7.8 using link above: https://github.com/goharbor/harbor/releases/tag/v1.7.8-rc1
  2. Extract the harbor folder in the download.
  3. Transfer the harbor folder and its contents to the VIC Appliance /root folder using scp/winscp.
  4. SSH into VIC appliance.
  5. Go into the transferred harbor folder: cd /root/harbor
  6. Loaded the new docker images per the command above: docker load -i ./harbor*.tar.gz
  7. Just took note of all the images by running: docker images
  8. Took a backup of the /etc/vmware/harbor folder in case anything blew up.
  9. Edited 3 docker-compose files located in /etc/vmware/harbor and replaced all image instances of v1.7.7 with v1.7.8: docker-compose.yml docker-compose.notary.yml docker-compose.clair.yml
  10. Made sure I was in the /etc/vmware/harbor directory: cd /etc/vmware/harbor
  11. Took notes of the running containers: docker ps -a
  12. Bring down the harbor containers: docker-compose down
  13. Bring up the new images:
    /usr/local/bin/docker-compose -f /etc/vmware/harbor/docker-compose.yml -f /etc/vmware/harbor/docker-compose.notary.yml -f /etc/vmware/harbor/docker-compose.clair.yml up -d
  14. Verified the containers were running using the new images: docker ps -a

After a minute or two for the containers to start, they all reported healthy, and I no longer received the 502 error.

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

No branches or pull requests

3 participants