-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
109 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
ARG OPENC3_REGISTRY=docker.io | ||
ARG OPENC3_NAMESPACE=openc3inc | ||
ARG OPENC3_TAG=latest | ||
ARG OPENC3_IMAGE=openc3-base | ||
|
||
FROM ${OPENC3_REGISTRY}/${OPENC3_NAMESPACE}/${OPENC3_IMAGE}:${OPENC3_TAG} | ||
|
||
WORKDIR /src/ | ||
COPY Gemfile ./ | ||
|
||
USER root | ||
|
||
RUN bundle config set --local without 'development' \ | ||
&& bundle install --quiet \ | ||
&& rm Gemfile.lock \ | ||
&& rm -rf /usr/lib/ruby/gems/*/cache/* \ | ||
/var/cache/apk/* \ | ||
/tmp/* \ | ||
/var/tmp/* | ||
|
||
RUN ["chown", "-R", "openc3:openc3", "/src/"] | ||
COPY --chown=${IMAGE_USER}:${IMAGE_GROUP} ./ ./ | ||
RUN ["chmod", "-R", "777", "/src/"] | ||
|
||
EXPOSE 2901 | ||
|
||
USER ${USER_ID}:${GROUP_ID} | ||
CMD [ "shoreman" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
ARG OPENC3_REGISTRY=docker.io | ||
ARG OPENC3_NAMESPACE=openc3inc | ||
ARG OPENC3_TAG=latest | ||
ARG OPENC3_IMAGE=openc3-base | ||
|
||
FROM ${OPENC3_REGISTRY}/${OPENC3_NAMESPACE}/${OPENC3_IMAGE}:${OPENC3_TAG} | ||
|
||
WORKDIR /src/ | ||
COPY Gemfile ./ | ||
|
||
USER root | ||
|
||
RUN bundle config set --local without 'development' \ | ||
&& bundle install --quiet \ | ||
&& rm Gemfile.lock \ | ||
&& rm -rf /usr/lib/ruby/gems/*/cache/* \ | ||
/var/cache/apk/* \ | ||
/tmp/* \ | ||
/var/tmp/* | ||
|
||
RUN ["chown", "-R", "openc3:openc3", "/src/"] | ||
COPY --chown=${IMAGE_USER}:${IMAGE_GROUP} ./ ./ | ||
RUN ["chmod", "-R", "777", "/src/"] | ||
RUN ["chmod", "-R", "555", "/src/scripts"] | ||
|
||
EXPOSE 2902 | ||
|
||
USER ${USER_ID}:${GROUP_ID} | ||
CMD [ "shoreman" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
ARG OPENC3_REGISTRY=docker.io | ||
ARG OPENC3_NAMESPACE=openc3inc | ||
ARG OPENC3_TAG=latest | ||
ARG OPENC3_IMAGE=openc3-ruby | ||
|
||
FROM ${OPENC3_REGISTRY}/${OPENC3_NAMESPACE}/${OPENC3_IMAGE}:${OPENC3_TAG} | ||
|
||
WORKDIR /openc3/ | ||
|
||
USER ${USER_ID}:${GROUP_ID} | ||
|
||
COPY --chown=${IMAGE_USER}:${IMAGE_GROUP} . . | ||
|
||
USER root | ||
|
||
RUN mkdir -p lib/openc3/ext \ | ||
&& git config --global http.sslCAinfo /devel/cacert.pem \ | ||
&& bundle config set --local without 'development' \ | ||
&& bundle install --quiet \ | ||
&& rake gems \ | ||
&& gem install --local ./openc3-*.gem \ | ||
&& openc3_gem=$(dirname `gem which openc3`) \ | ||
&& ln -s $openc3_gem/openc3 $openc3_gem/cosmos \ | ||
&& mkdir -p gems \ | ||
&& mv *.gem gems/. \ | ||
&& gem cleanup \ | ||
&& rm -rf /usr/lib/ruby/gems/*/cache/* /var/cache/apk/* /tmp/* /var/tmp/* | ||
|
||
WORKDIR /openc3/python | ||
|
||
RUN . /openc3/venv/bin/activate \ | ||
&& pip3 install -r requirements.txt && pip3 install --pre . | ||
|
||
WORKDIR /openc3/ | ||
|
||
RUN mkdir /gems && chown openc3:openc3 /gems | ||
RUN mkdir /plugins && chown openc3:openc3 /plugins | ||
RUN ["chmod", "-R", "777", "/gems/"] | ||
RUN ["chmod", "-R", "777", "/plugins/"] | ||
RUN ["chmod", "-R", "777", "/openc3/"] | ||
ENV HOME=/openc3 | ||
USER ${USER_ID}:${GROUP_ID} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters