Exporting MySQL table data: "into outfile" fails, directory stays NULL after editing variables in cnf files
It could be you missed the [mysqld] section for the configuration file however here is a complete example:

$ mkdir conf
$ mkdir home
$ mkdir datadir
$  echo -e '[mysqld]\nsecure_file_priv= "/home/"' | tee conf/native.cnf
[mysqld]
secure_file_priv= "/home/"

$ cat conf/native.cnf
[mysqld]
secure_file_priv= "/home/"

$ docker run -v $PWD/conf:/etc/mysql/conf.d \
             -v $PWD/home:/home  \
             -v $PWD/datadir:/var/lib/mysql \
             -e MYSQL_ROOT_PASSWORD=my-secret-pw \
             --name mysql \
             mysql:5.7


Another terminal:

$  docker exec -ti mysql  mysql -pmy-secret-pw -e 'select @@GLOBAL.secure_file_priv'

mysql: [Warning] Using a password on the command line interface can be insecure.
+---------------------------+
| @@GLOBAL.secure_file_priv |
+---------------------------+
| /home/                    |
+---------------------------+