Terminal access is required for following troubleshooting legacy AppStore issues.
Logs should be the first thing you look at when issues happen.
Run following command to view logs of casaos-app-management:
journalctl -xeu casaos-app-management --no-pager
There is a formatter tool (https://tinyurl.com/formatlog) that allows better viewing of the logs by simply pasting.
If you need to share the logs with CasaOS team or anyone from the community, run following command and share the resulting short URL.
By running the command, you acknowledge that the logs will be shared with internet, and can be accessed by anyone potentially.
journalctl -xeu casaos-app-management --no-pager | curl -F 'sprunge=<-' http://sprunge.us
If successful, it returns something looks like http://sprunge.us/qV3VEA
There are 2 ways to synchronize the system time:
timedatectlRun timedatectl (Ubuntu or its variants):
                     Local time: Thu 2021-08-05 11:56:40 EDT
           Universal time: Thu 2021-08-05 15:56:40 UTC
                 RTC time: Thu 2021-08-05 15:56:41
                Time zone: America/New_York (EDT, -0400)
System clock synchronized: yes
              NTP service: active
          RTC in local TZ: no
System clock synchronized: yes reflects that the time is successfully syncedNTP service: active means that timesyncd is up and running.If your output shows that NTP service isn’t active, turn it on with timedatectl:
sudo timedatectl set-ntp on
After this, run timedatectl again to confirm the network time status. It may take a minute for the sync to happen, but eventually System clock synchronized: will read yes and NTP service: will show as active.
ntpdateIf you don't already have ntpdate installed, run
sudo apt-get install ntpdate
If ntpdate is installed, run:
sudo ntpdate time.nist.gov
There are other time servers you can try, for example:
time.google.com
time.cloudflare.com
time.facebook.com
time.windows.com
time.apple.com
Legacy AppStore makes API call to https://api.casaos.io to retrieve app catalog before anything is cached.
Run through following commands to check if AppStore API returns app catalog
curl https://api.casaos.io/casaos-api/token
If successful, a JSON payload like sample below will be returned
{
   "code" : 200,
   "data" : "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VybmFtZSI6IiIsInBhc3N3b3JkIjoiIiwiZXhwIjoxNjc2NDI0MDIzLCJpc3MiOiJnaW4tYmxvZyJ9._nj5ZFUsicx5q5swKh1cwUdooslnK582By3o3K-P_u4",
   "mssage" : "ok"
}
Copy the token in data above and replace the <token> below with it
curl https://api.casaos.io/casaos-api/v2/app/newlist  -H "Authorization: <token>"
If AppStore API is running, a JSON payload of app catalog will be returned.
TODO