Caching of profile pictures/ avatars ( Office365 Libravatar integration broken avatar when not logged in )
Office365 Libravatar integration displays broken profile images when a user is not logged into an Office365 domain.
Steps to reproduce
Integrate according to this doc (http://docs.gitlab.com/ee/customization/libravatar.html). Ensure you are using the same account names as your office365 account in GitLab or just integrate through LDAP
Log in to GitLab & office365 domain.
Log out of Office365 and refresh any profile image containing page
Some kind of graceful failure when it cannot load profile images or the caching of those images.
Relevant logs and/or screenshots
Output of checks
Results of GitLab Application Check
machine:~$ sudo gitlab-rake gitlab:check SANITIZE=true Checking GitLab Shell ... GitLab Shell version >= 3.2.1 ? ... OK (3.2.1) Repo base directory exists? default... yes Repo storage directories are symlinks? default... no Repo paths owned by git:git? default... yes Repo paths access is drwxrws---? default... yes hooks directories in repos are links: ... 2/1 ... ok Running /opt/gitlab/embedded/service/gitlab-shell/bin/check Check GitLab API access: OK Check directories and files: /mnt/it-gitlab/.ssh/authorized_keys: OK Send ping to redis server: gitlab-shell self-check successful Checking GitLab Shell ... Finished Checking Sidekiq ... Running? ... yes Number of Sidekiq processes ... 1 Checking Sidekiq ... Finished Checking Reply by email ... IMAP server credentials are correct? ... yes Init.d configured correctly? ... skipped (omnibus-gitlab has no init script) MailRoom running? ... can't check because of previous errors Checking Reply by email ... Finished Checking LDAP ... LDAP users with access to your GitLab server (only showing the first 100 results) Server: ldapmain **Removed** Checking LDAP ... Finished Checking GitLab ... Git configured with autocrlf=input? ... yes Database config exists? ... yes All migrations up? ... yes Database contains orphaned GroupMembers? ... no GitLab config exists? ... yes GitLab config outdated? ... no Log directory writable? ... yes Tmp directory writable? ... yes Uploads directory setup correctly? ... yes Init script exists? ... skipped (omnibus-gitlab has no init script) Init script up-to-date? ... skipped (omnibus-gitlab has no init script) projects have namespace: ... 2/1 ... yes Redis version >= 2.8.0? ... yes Ruby version >= 2.1.0 ? ... yes (2.1.8) Your git bin path is "/opt/gitlab/embedded/bin/git" Git version >= 2.7.3 ? ... yes (2.7.4) Active users: 3 Checking GitLab ... Finished
Results of GitLab Environment Info
$ sudo gitlab-rake gitlab:env:info System information System: Ubuntu 14.04 Current User: git Using RVM: no Ruby Version: 2.1.8p440 Gem Version: 2.5.1 Bundler Version:1.10.6 Rake Version: 10.5.0 Sidekiq Version:4.1.4 GitLab information Version: 8.10.3-ee Revision: 9851edb Directory: /opt/gitlab/embedded/service/gitlab-rails DB Adapter: PostgreSQL DB Version: 9.5.2 URL: https://FQDN HTTP Clone URL: https://FQDN/some-group/some-project.git SSH Clone URL: git@FQDN:some-group/some-project.git Elasticsearch: no Geo: no Using LDAP: yes Using Omniauth: yes Omniauth Providers: github GitLab Shell Version: 3.2.1 Repository storage paths: - default: /mnt/it-gitlab/git-data/repositories Hooks: /opt/gitlab/embedded/service/gitlab-shell/hooks/ Git: /opt/gitlab/embedded/bin/git
They should be saved in GitLab/users browser and refreshed or at least fall back on the stock gitlab profile images. Image below when I am not logged into Office365.
Would it be possible to save a users profile picture to the GitLab server itself with periodic updates when available?
Originally raised in #17427 (closed), somewhat related since these images obviously are also not being cached but this looks actually broken to end users. I suspect this is probably also issue with normal gravatar/Libravatar if the GitLab user cannot reach that server since the office365 integration seem to just throw a URL for the user to resolve.