Skip to content

Social media absolute url config#5245

Merged
joshmoore merged 1 commit intoome:metadata53from
manics:social_media_absolute_url_config
Apr 19, 2017
Merged

Social media absolute url config#5245
joshmoore merged 1 commit intoome:metadata53from
manics:social_media_absolute_url_config

Conversation

@manics
Copy link
Copy Markdown
Member

@manics manics commented Apr 10, 2017

What this PR does

Allows absolute URL for social media to be overriden by the OMERO.web administrator, the default is to use Django's build_absolute_uri which probably uses the Host header sent by the client.

--depends-on #5244

In conjunction with #5244 this includes all required changes from #4744 (some commits were already rebased to develop, others are unnecessary following the addition of omero.web.api.absolute_url in mainline.

Testing this PR

  1. Configure a public web user, enable social media options, e.g. https://github.com/manics/deployment/blob/9bba3a5c7223acb6b9f01c16fc5435778796d2e8/ansible/group_vars/omero-hosts.yml#L109
  2. Check the twitter and opengraph metadata is present in the HTML source of the full image viewer
  3. Set a custom value for omero.web.api.absolute_url, check this is reflected in the hard-coded URL.

Related reading

https://trello.com/c/z2U5K6ht/1-omero-5-3-migration

@aleksandra-tarkowska

@manics manics changed the base branch from develop to metadata53 April 10, 2017 14:36
@manics
Copy link
Copy Markdown
Member Author

manics commented Apr 10, 2017

--rebased-from #4744

@atarkowska
Copy link
Copy Markdown
Member

atarkowska commented Apr 13, 2017

works as expected with #5244

<meta name="twitter:image" content="https://test.example.org.custom.domain/prefix/webgateway/render_thumbnail/1229801/280/">

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.

4 participants