**Apache Airflow version**: 2.0.0

**Kubernetes version (if you are using kubernetes)** (use `kubectl version`): NA

**Environment**: 
* local Ubuntu 18.04 LTS / 
* docker-compose version 1.25.3, build d4d1b42b
* docker  20.10.1, build 831ebea

**What happened**:

when enabling xcom push for a docker operator the following error is thrown after the task finishes succesfully:
`TypeError: Object of type bytes is not JSON serializable`


**What you expected to happen**:

* error is not thrown
* if xcom_all is True: xcom contains all log lines
* if xcom_all is False: xcom contains last log line


**How to reproduce it**:

see docker compose and readme here:
https://github.com/AlessioM/airflow-xcom-issue

tests/providers/docker/operators/test_docker.py
)
        with self.assertLogs(operator.log, level=logging.WARNING) as captured:
            operator.execute(None)
            assert (
                "WARNING:airflow.task.operators:Using remote engine or docker-in-docker "
                "and mounting temporary volume from host is not supported" in captured.output[0]
            )
        self.client_class_mock.assert_called_once_with(
            base_url='unix://var/run/docker.sock', tls=None, version='1.19'
        )
        self.client_mock.create_container.assert_has_calls(
            [
                call(
                    command='env',
                    name='test_container',
                    environment={'AIRFLOW_TMP_DIR': '/tmp/airflow', 'UNIT': 'TEST', 'PRIVATE': 'MESSAGE'},
                    host_config=self.client_mock.create_host_config.return_value,
                    image='ubuntu:latest',
                    user=None,
                    entrypoint=['sh', '-c'],
                    working_dir='/container/path',
                    tty=True,
                ),
                call(
                    command='env',
                    name='test_container',
                    environment={'UNIT': 'TEST', 'PRIVATE': 'MESSAGE'},
                    host_config=self.client_mock.create_host_config.return_value,
                    image='ubuntu:latest',
                    user=None,