やり直しができる世界
先日構築したDockerの環境でRSS処理だけ動いてなかったのでモジュールを追加 ────
$ cpanm XML::RSS
Expat must be installed prior to building XML::Parser and I can't find it in the standard library directories. Install 'expat-devel' (or 'libexpat1-dev') package with your OS package manager. See 'README'.
なんか怒られた(T^T)
助けてChatGPT先生!!!
$ apt-get update
$ apt-get libexpat1-dev
$ cpanm XML::RSS
よし! よくわからないけど動いた(汗) それじゃあDockerfileも直しておこうか。
FROM httpd:latest ENV TZ Asia/Tokyo RUN apt-get update \ && apt-get install -y perl tar bzip2 gcc make curl libexpat1-dev \ && curl -L https://cpanmin.us | perl - App::cpanminus \ && rm -rf /var/lib/apt/lists/* \ && mkdir /home/user-name RUN cpanm CGI \ && cpanm DBI \ && cpanm DBD::SQLite \ && cpanm HTML::Template \ && cpanm XML::RSS COPY ./lib/perl5/CR/ /usr/local/share/perl/5.32.1/CR/ COPY ./httpd.conf /usr/local/apache2/conf/httpd.conf