Can't connect to Oracle 12c Release 1 in docker container from host
I'm running Oracle 11g Personal edition docker container

$ docker ps
CONTAINER ID        IMAGE                                    COMMAND                  CREATED             STATUS              PORTS                                                                     NAMES
d84af138d77a        oracleinanutshell/oracle-xe-11g:latest   "/bin/sh -c '/usr/sb…"   22 minutes ago      Up 22 minutes       0.0.0.0:32777-&gt;22/tcp, 0.0.0.0:32776-&gt;1521/tcp, 0.0.0.0:32775-&gt;8080/tcp   oracle-xe-11g


As you can see port 1521 was  mapped to 32776.

Replace 0.0.0.0 with ipaddress of docker vm running on Virtualbox i.e 192.168.99.100

 sqlplus test/test@192.168.99.100:32776/XE

SQL*Plus: Release 19.0.0.0.0 - Production on Fri Aug 9 13:12:19 2019
Version 19.3.0.0.0

Copyright (c) 1982, 2019, Oracle.  All rights reserved.

SQL&gt; select * from v$version;

BANNER
--------------------------------------------------------------------------------
Oracle Database 11g Express Edition Release 11.2.0.2.0 - 64bit Production
PL/SQL Release 11.2.0.2.0 - Production
CORE    11.2.0.2.0      Production
TNS for Linux: Version 11.2.0.2.0 - Production
NLSRTL Version 11.2.0.2.0 - Production


If you're trying to login as sys user add sysdba at the end