Skip to content

CyberFM

  • Home
  • FileMaker Security
  • Disclaimer
  • Privacy Policy
  • Home
  • Matt Petrowsky
  • Running FileMaker Server in Docker Desktop
  • Matt Petrowsky

Running FileMaker Server in Docker Desktop

Dimitris Kokoutsidis 2 years ago3 months ago12 mins0

Matt Petrowsky, Jul 12, 2023, FileMaker Magazine

Source: https://www.filemakermagazine.com/videos/running-filemaker-server-docker-desktop

The files you need are part of a FileMaker Server installation. You need to install a Linux FileMaker server somewhere then you’ll find them within a Tools subfolder.

Installing into a local VM (Parallels, VM Ware, VirtualBox) will give you access to the Docker files.

Table of Contents

  1. Introduction
  2. Benefits of Running FileMaker Server Locally
  3. Requirements for Docker Desktop Setup
  4. Docker Fundamentals
    • Containers vs. Images
    • Volumes and Networking in Docker
  5. Setting Up Docker Desktop on Apple Silicon (M1/M2) or Intel
    • Installing Docker Desktop
    • Configuring File Sharing for Mac
  6. Creating a FileMaker Server Image
    • Preparing the Ubuntu Base Image
    • Using FileMaker’s Docker Script
    • Modifying the Script for macOS Compatibility
  7. Running FileMaker Server in a Container
    • Starting and Stopping the Container
    • Connecting to FileMaker Server Admin Console
  8. Managing FileMaker Server in Docker
    • Saving Customized Containers as Images
    • Deploying Pre-configured Images
  9. Advanced Docker Tips for FileMaker Development
    • Adding Custom Tools and Plugins
    • File Management and Backup
  10. Summary and Key Takeaways

Introduction

Running FileMaker Server in Docker Desktop offers a flexible, isolated environment for developing and testing FileMaker solutions locally. This setup allows you to easily manage multiple versions of FileMaker Server, streamline startup/shutdown processes, and leverage the advantages of containerization for efficient development.

This blog will guide you through the process of installing and configuring FileMaker Server in Docker Desktop on Apple Silicon (M1/M2) or Intel Macs, with detailed instructions on creating a FileMaker Server image, running it in a container, and managing your development environment.


Benefits of Running FileMaker Server Locally

Using a local FileMaker Server for development comes with several benefits:

  • Replicates Deployment Environment: Simulates a real-world deployment, offering a reliable testing environment for your solutions.
  • Crash Isolation: Protects your development from unexpected crashes by using an isolated server environment.
  • Quick Setup: Containers start within seconds, allowing rapid switching between different FileMaker Server versions.
  • Portability: Containers can be shared or moved easily, ensuring consistent development environments across teams.

Requirements for Docker Desktop Setup

To successfully set up FileMaker Server in Docker Desktop, you will need:

  1. Docker Desktop: Installed on an Apple Silicon (M1/M2) or Intel-based Mac.
  2. Ubuntu Base Image: A compatible Linux distribution, such as Ubuntu 22.04 LTS.
  3. FileMaker Server Linux Installation File: This .deb file is available from your FileMaker developer account.
  4. Terminal and Basic Command Line Knowledge: Familiarity with command-line operations is essential.

Docker Fundamentals

Before diving into the setup, understanding some Docker basics is crucial.

Containers vs. Images

  • Image: A snapshot of a system or software, acting like a template. An image includes the operating system, software, and configuration needed to run an application.
  • Container: A running instance of an image. Containers are lightweight and isolated, sharing the host’s operating system kernel.

Volumes and Networking in Docker

  • Volumes: Storage areas that are shared between the host and container, useful for persisting data such as databases.
  • Networking: Docker containers can share network configurations with the host, or use isolated internal networks for communication between containers.

Setting Up Docker Desktop on Apple Silicon (M1/M2) or Intel

Installing Docker Desktop

  1. Go to Docker’s website and download the appropriate version for your Mac.
  2. Install Docker Desktop and create a Docker account if required.
  3. Launch Docker Desktop and verify the installation by running the command:bashCopy codedocker --version
  4. Enable file sharing to allow Docker containers to access specific folders on your Mac.

Configuring File Sharing for Mac

  1. Open Docker Desktop and navigate to Settings (gear icon).
  2. Go to Resources > File Sharing.
  3. Add the following paths:
    • /opt/FileMaker/FileMaker Server/Data
    • /opt/FileMaker/FileMaker Server/Logs
    • /opt/FileMaker/FileMaker Server/CStore

These directories will be used to share data between your Mac and Docker containers.


Creating a FileMaker Server Image

Preparing the Ubuntu Base Image

  1. Pull the required Ubuntu version for FileMaker Server. Use the following command:bashCopy codedocker pull ubuntu:22.04 This command downloads the Ubuntu 22.04 LTS image, which is recommended for FileMaker Server 20+.

Using FileMaker’s Docker Script

FileMaker provides a Docker script to create a containerized FileMaker Server environment. This script requires some modifications for compatibility with macOS.

  1. Download the FileMaker Server installer for Linux (Ubuntu) from your developer account.
  2. Locate the FMS Docker Installer Script provided by FileMaker. Duplicate and rename the script for macOS adjustments.

Modifying the Script for macOS Compatibility

  1. Open the script in a text editor (e.g., VS Code).
  2. Adjust the following key variables:
    • OS Version: Replace any OS detection commands with a hard-coded version:bashCopy codeUBUNTU_VERSION="22.04"
    • File Sharing Paths: Ensure the script references the correct shared directories.
    • Networking: Skip or adjust networking options that rely on Linux-only features.
  3. Save the modified script and proceed to build the image.

Running FileMaker Server in a Container

Starting and Stopping the Container

To start the FileMaker Server container:

  1. Run the Docker command to start a container from your customized image:bashCopy codedocker run -d --name FMS_Server -p 80:80 -p 443:443 -p 5003:5003 \ -v /opt/FileMaker/FileMaker\ Server/Data:/opt/FileMaker/FileMaker\ Server/Data \ -v /opt/FileMaker/FileMaker\ Server/Logs:/opt/FileMaker/FileMaker\ Server/Logs \ -v /opt/FileMaker/FileMaker\ Server/CStore:/opt/FileMaker/FileMaker\ Server/CStore \ ubuntu:22.04

This command runs the container in detached mode (-d), mapping necessary ports and directories.

Connecting to FileMaker Server Admin Console

  1. Open a web browser and navigate to:arduinoCopy codehttp://localhost/admin-console
  2. Use the credentials you specified during the FileMaker Server setup to log in.

Stopping the Container

To stop the container, use:

bashCopy codedocker stop FMS_Server

To restart, use:

bashCopy codedocker start FMS_Server

Managing FileMaker Server in Docker

Saving Customized Containers as Images

After configuring FileMaker Server with your preferences (plugins, tools), you can save the container state as an image:

  1. Use the following command to commit the running container:bashCopy codedocker commit FMS_Server customized_fms_server

Deploying Pre-configured Images

To share your pre-configured image with another developer:

  1. Save the image to a file:bashCopy codedocker save -o customized_fms_server.tar customized_fms_server
  2. Provide the .tar file to your colleague, who can load the image using:bashCopy codedocker load -i customized_fms_server.tar

Advanced Docker Tips for FileMaker Development

Adding Custom Tools and Plugins

  1. Access the container’s shell:bashCopy codedocker exec -it FMS_Server /bin/bash
  2. Install desired tools or plugins using standard Linux commands.
  3. Once customization is complete, save the container as a new image.

File Management and Backup

FileMaker Server’s data and logs are accessible via the shared directories configured earlier. To back up your data:

  1. Navigate to /opt/FileMaker/FileMaker Server/Data.
  2. Copy the databases to your local backup location.

Summary and Key Takeaways

Running FileMaker Server in Docker Desktop provides an agile development environment that mimics production, isolates server operations, and offers flexibility. Using Docker containers, you can switch between multiple server versions seamlessly, share setups across development teams, and avoid local system interference.

Docker makes FileMaker development more efficient, allowing rapid experimentation, consistent environments, and quick deployments—vital for professional developers.


For additional resources on Docker and FileMaker Server, check out the official documentation and forums for the latest tips and updates.

Tagged: Account API Apple Backup Bash Blog Post Container Crash Credentials Deployment Docker Documentation FileMaker Pro FileMaker Server Install Linux Load macOS Management Network Plugin Server Shell SSL Test Ubuntu Update UPS Web YouTube

Dimitris Kokoutsidis

Post navigation

July 12, 2023
Ultimate Guide to Modernizing a FileMaker Legacy Application
July 12, 2023
PHP no longer bundled with FileMaker Server

Related Articles

How to Troubleshoot & Research FileMaker Issues

Dimitris Kokoutsidis3 years ago3 months ago0