я новые с грузчиком и хочу установить nginx
внутри моего контейнера для перенаправления на внешнем IPDocker инсталляции Nginx
моя цели отправить запрос на http://localhost:3010/api/v1/service
внутри грузчика, и он должен перенаправить меня в мой http://192.168.99.1:3010/api/v1/service
http://192.168.99.1:3010 -it my rails server running
Или, может быть, я полностью ошибаюсь в своей идее?
я пытаюсь сделать это RUN yum install nginx
но я получил
ERROR: Service 'my_service_name' failed to build: The command '/bin/sh -c yum install nginx' returned a non-zero code: 1
dockerfile
FROM jboss/wildfly:latest
USER root
ENV TERM dumb
RUN yum -y install wget && \
wget https://github.com/papertrail/remote_syslog2/releases/download/v0.15/remote_syslog_linux_amd64.tar.gz && \
tar xzf ./remote_syslog*.tar.gz && \
cd remote_syslog && \
cp ./remote_syslog /usr/local/bin && \
yum -y install postgresql && yum clean all
ADD customization/DigiCertCA.pem /etc/pki/ca-trust/source/anchors/DigiCertCA.pem
RUN update-ca-trust extract
# install nginx
RUN yum install nginx
# Copy a configuration file from the current directory
ADD nginx.conf /etc/nginx/
# Set the default command to execute when creating a new container
CMD service nginx start
CMD ["find/-type f -exec ls -l {} \;"]
CMD ["chmod 666 customization/*.properties"]
ADD customization /opt/jboss/wildfly/customization/
COPY customization/WebService.* /opt/jboss/wildfly/standalone/deployments/
ADD newrelic /opt/jboss/wildfly/newrelic/
CMD ["/opt/jboss/wildfly/customization/execute.sh"]
EXPOSE 8080
Какое ваше базовое изображение? Можете ли вы опубликовать весь файл докеров? –
@YaronIdan добавлен – user
Существует также [официальный образ] (https://hub.docker.com/_/nginx/), который вы можете использовать. Вы можете расширить это и добавить свои собственные файлы конфигурации и быть хорошими, чтобы идти. – R0MANARMY