[question] Possible to run Containerpilot (or other init processes) as entrypoint?
See original GitHub issueDescription of the issue:
Consul is useful in service discovery, and rather than running something like Registrator as a sidecar to the application, would it be possible to add ContainerPilot that is ran within the container as a type of init system (other examples for non service discovery would be s6
or tini
)?
I pick those because I think they have little dependencies. I’m leaving supervisord
out of the list because that requires Python, IIUC (although, that can be added with one’s own base image)
Expected behavior:
- Install
containerpilot
into image (for simplicity, let’s say the base image has it), or better - Can Jib do multistage builds yet?
It is a statically linked binary, written in go
# get ContainerPilot release RUN curl -Lo /tmp/cb.tar.gz https://github.com/joyent/containerpilot... \ && tar -xz -f /tmp/cb.tar.gz && mv /containerpilot /bin/
-
contiainerpilot.json
can be added intosrc/main/jib/app
-
ENV CONTAINERPILOT=file:///app/containerpilot.json
can be put into the build system -
Question: Is this possible?
ENTRYPOINT ["/bin/containerpilot"]
CMD ["java", "-cp" ...jibStuff...]
Or even with a custom entrypoint, are the JVM args exposed to a custom entrypoint script?
I’m leaning towards the thought a custom entrypoint is required to run the config templating command i.e./bin/containerpilot -config /app/containerpilot.json5
Additional Information: Feel free to ask. Disclaimer - I have only done a few projects with Containerpilot, but it is required for our containers to work “properly” in our environment and I just copy paste from others’ code. At a high level, I think the above are the only steps required.
Issue Analytics
- State:
- Created 5 years ago
- Comments:6 (6 by maintainers)
Top GitHub Comments
So, to summarize this, I got
Well, that would be similar to the
ADD
semantics in Dockerfile. Might be useful ¯\_(ツ)_/¯.Okay, I think we can close this issue, for the purpose of tracking open issues. Feel free to reopen if you have questions.