title: Remote connection to oracle database running on a docker container from outside the docker's host machine
body: <p>I have been recently trying to set up an Oracle Database Server 12c R2 using its official docker images from <a href="https://hub.docker.com/u/hamednq/content/sub-f12a3e99-85f2-4284-88e2-b561dfd17911" rel="nofollow noreferrer">this website</a>, and I've successfully run a container from that image and connected to the database both from the inside of the container and its outside (from the docker host machine). 
  The docker host machine is a VPS (ubuntu 16.04), and I have telnet to the IP/PORT of the database from my laptop (centos 7), but I'm not able to connect to the database using sqlplus command. The tnsnames.ora file is something like this: </p>
  
  <pre><code>ORCLCDB = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 217.182.235.26)(PORT = 32756)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = ORCLCDB.localdomain)))
  ORCLPDB1 = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 217.182.230.21)(PORT = 32756)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = ORCLPDB1.localdomain)))
  
  </code></pre>
  
  <p>and the listener.ora is like this:</p>
  
  <pre><code>LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 217.182.235.26)(PORT = 32756)) (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))))
  DIAG_ADR_ENABLED = off
  SSL_VERSION = 1.0
  </code></pre>
  
  <p>and the command that I'm using to connect from my local machine is: </p>
  
  <pre><code>sqlplus64 UI_TEST/ut@217.182.235.26:32756/ORCLCDB.localdomain
  </code></pre>
  
  <p>But I get <code>ORA-12537: TNS:connection closed</code></p>
  
  <p>What is the problem?
  What am I missing?</p>