This article explains how to create and use a Docker container with an Oracle XE database on macOS. The following steps are very simple and easy. The database setup needs only minutes and works very well for development and testing purposes.
Requirements
Please go to the Oracle Database XE Community Support Forum for help, feedback, and enhancement requests. Note: Oracle Support Services only provides support for Oracle Database Enterprise Edition (EE) and Oracle Database Standard Edition 2 (SE2) in conjunction with a valid Oracle Database Technical Support agreement. Has to be owned by the Unix user „oracle“ or set appropriately. If omitted the database will not be persisted over container recreation. Use the Oracle XE container. Stop the container with docker stop or start it with docker start. Connect to the database from macOS using localhost, port 1521 and SID XE. If Oracle Database (Release 11 or later) is also installed, a version of SQL Developer is also included and is accessible through the menu system under Oracle.This version of SQL Developer is separate from any SQL Developer kit that you download and unzip on your own, so do not confuse the two, and do not unzip a kit over the SQL Developer files that are included with Oracle Database. Oracle VM VirtualBox Extension Pack. Free for personal, educational or evaluation use under the terms of the VirtualBox Personal Use and Evaluation License on Windows, Mac OS X, Linux and Solaris x-86 platforms.
Docker software for macOS is installed and configured (Download Docker for Mac).
Create and Configure the container
1. Navigate to github to get official Docker images for Oracle Software
2. Clone the git repository
IO Error: The Network Adapter could not establish the connection This means that you are trying to connect with SQL Developer, but your Docker container is stopped. Open Kitematic, select your Oracle container, and click “Start”. When the logs read “Database ready to use. Enjoy! ;)”