systemctl & service are not working in amazonlinux:2 container

0

I am attempting to create a custom Neo4j image. I have chosen the Amazon Linux 2 base image and installed all the necessary dependencies, including the specific Neo4j Community version. Additionally, I have installed Python 3.7 and copied my Python files to enable the execution of desired tasks. My objective is to initiate the Neo4j service and have my Python files connect with Neo4j. To achieve this, I initially tried using the following command: CMD [ "neo4j", "start" ] However, this approach proved unsuccessful. I now intend to use either systemctl or service to start the Neo4j service and subsequently run my Python file. Please guide me to achieve this scenario

2 個答案
2

Hi,

Why don't you rather use the official Neo4j docker image available at https://hub.docker.com/_/neo4j ?

If you need more stuff in it (Python, etc.) , you can add your own container layers on top.

The official Neo4j image supports API to the database.

Best,

Didier

profile pictureAWS
專家
已回答 4 個月前
2

Just a side note, python 3.7 is EOL, so I would recommend moving off this.

As for your issue, are you sure you dont just run "neo4j" ?? What i would try instead is launch a bash shell in the container and try and start it manually from the container to find the correct exec command.

Other than that, I would turn to the neo4j community for more specific support.

profile picture
專家
已回答 4 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南