From 392b12bc47106bc7a9e25f6f7f3bb8b8b600c06d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Raul=20Ota=C3=B1o?= Date: Mon, 14 Jul 2025 23:35:56 +0200 Subject: [PATCH] Added docker support --- Dockerfile | 5 +++++ README.md | 14 ++++++++++++++ 2 files changed, 19 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..d1512ae --- /dev/null +++ b/Dockerfile @@ -0,0 +1,5 @@ +FROM perl:5.42.0-slim-threaded-bullseye + +COPY pg2mysql.pl pg2mysql.pl + +ENTRYPOINT [ "./pg2mysql.pl" ] \ No newline at end of file diff --git a/README.md b/README.md index 4e1a7b9..a303ad3 100644 --- a/README.md +++ b/README.md @@ -43,6 +43,20 @@ about: You must have Perl installed at `/usr/bin/perl` to run the script directly. +# Execute with Docker + +First need to build it into one image: + +```sh +docker image build . -t pg2mysql +``` + +then you can just running with docker run like this (be aware of the -i argument): + +```sh +docker run -v --rm -i pg2mysql < drupal_pg.dump > mysql.sql +``` + # Credits pg2mysql is heavily inspired and informed by this project of the same