msoap / shell2http

Executing shell commands via HTTP server
MIT License
1.32k stars 129 forks source link

Ability to define multiple endpoints in dockerfile #89

Closed Semetra22 closed 1 year ago

Semetra22 commented 1 year ago

I would like to define multiple endpoints in the Dockerfile.

Here is my Dockerfile:

FROM msoap/shell2http
RUN apk add --no-cache curl

EXPOSE 8080
CMD ["-no-index","-form","-log=endpoint1.log","/v0/endpoint1","/scripts/script1.sh $v_param"]
CMD ["-no-index","-log=endpoint2.log","/v0/endpoint2","/scripts/script2.sh $v_param"]

However, only the last command is executed after the build. Any idea?

msoap commented 1 year ago

Docker not supported several CMD's, but you can run two endpoints on one shell2http