<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def create_missing(self):
 """Conditionally mark ``docker_upstream_name`` as required. Mark ``docker_upstream_name`` as required if ``content_type`` is "docker". """

        if getattr(self, 'content_type', '') == 'docker':
            self._fields['docker_upstream_name'].required = True
        super(Repository, self).create_missing()