blob: 4116509bfeb5a3dba2d503ce2462ef05618de40e [file] [log] [blame]
vasraz987fc742021-11-29 17:42:02 +00001FROM onap/policy-jdk-debian:2.0.2
sebdet30670ac2020-08-04 14:16:00 +02002
sebdet30670ac2020-08-04 14:16:00 +02003RUN addgroup sdc
sebdet30670ac2020-08-04 14:16:00 +02004RUN adduser --gecos "sdc sdc,1,1,1" --disabled-password --ingroup sdc --shell /bin/sh sdc
5USER sdc
6RUN mkdir ~/.cassandra/ && \
7 echo '[cql]' > ~/.cassandra/cqlshrc && \
8 echo 'version=3.4.4' >> ~/.cassandra/cqlshrc
9USER root
10
eschcam94176d72023-03-30 13:47:20 +010011RUN apt-get update --allow-releaseinfo-change && \
12 apt-get purge python* -y && \
13 apt-get install -y python3-pip && \
14 python3 -m pip install --upgrade pip && \
15 pip3 install cqlsh==6.1.0 && \
sebdet30670ac2020-08-04 14:16:00 +020016 mkdir ~/.cassandra/ && \
17 echo '[cql]' > ~/.cassandra/cqlshrc && \
18 echo 'version=3.4.4' >> ~/.cassandra/cqlshrc && \
19 set -ex && \
sebdet30670ac2020-08-04 14:16:00 +020020 apt-get install -y \
21 make \
22 gcc \
23 ruby \
24 ruby-dev \
25 libffi-dev \
26 libxml2-dev && \
vasraz36edaac2023-06-06 17:12:59 +010027 gem install --no-update-sources public_suffix:4.0.7 multipart-post:2.2.0 etc:1.3.0 bundler:2.3.26 chef:13.8.5 berkshelf:6.3.1 io-console:0.4.6 webrick --no-document && \
sebdetdf353be2020-09-21 22:13:05 +020028 apt-get update -y && apt-get remove bash -y --allow-remove-essential && \
sebdet30670ac2020-08-04 14:16:00 +020029 apt-get install -y binutils && apt-get clean && gem cleanup
sebdetdf353be2020-09-21 22:13:05 +020030
sebdet30670ac2020-08-04 14:16:00 +020031USER sdc
MichaelMorrisa2abf6e2020-03-10 12:37:48 +000032COPY --chown=sdc:sdc chef-solo /home/sdc/chef-solo/
MichaelMorrisa2abf6e2020-03-10 12:37:48 +000033COPY --chown=sdc:sdc chef-repo/cookbooks /home/sdc/chef-solo/cookbooks/
MichaelMorrisa2abf6e2020-03-10 12:37:48 +000034COPY --chown=sdc:sdc startup.sh /home/sdc/
Yuli Shlosberg0875ce02018-01-25 13:53:36 +020035
MichaelMorrisa2abf6e2020-03-10 12:37:48 +000036RUN chmod 770 /home/sdc/startup.sh
Yuli Shlosberg0875ce02018-01-25 13:53:36 +020037
MichaelMorrisa2abf6e2020-03-10 12:37:48 +000038ENTRYPOINT [ "/home/sdc/startup.sh" ]