Skip to content

Commit

Permalink
keycloak OS replaced with CENTOS 8
Browse files Browse the repository at this point in the history
portal reverse proxies are fixied.
general bug fixes for compose file etc.
  • Loading branch information
anatolicvs committed Mar 3, 2020
1 parent ebb484b commit ad090fb
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 10 deletions.
11 changes: 9 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ services:
image: in-sylva.keycloak:latest
container_name: in-sylva.keycloak
environment:
network.host: 0.0.0.0
DB_VENDOR: POSTGRES
DB_ADDR: postgres
DB_DATABASE: keycloak
Expand Down Expand Up @@ -187,10 +188,16 @@ services:
DB_PASSWORD: v2kGBDUaGjXK2VuPyf5R64VS
DB_DATABASE: insylva
PORT: 4000
IN_SYLVA_KEYCLOAK_HOST: http://in-sylva.keycloak
IN_SYLVA_KEYCLOAK_PORT: 7000
IN_SYLVA_KEYCLOAK_HOST: http://keycloak
IN_SYLVA_KEYCLOAK_PORT: 8080
KEYCLOAK_USERNAME: insylva_admin
KEYCLOAK_PASSWORD: v2kGBDUaGjXK2VuPyf5R64VS
KEYCLOAK_GRANT_TYPE: password
KEYCLOAK_CLIENT_ID: client_id
networks:
- app-network
links:
- keycloak
restart: unless-stopped

source-manager:
Expand Down
15 changes: 9 additions & 6 deletions keycloak/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,29 +1,32 @@
FROM registry.access.redhat.com/ubi8-minimal
FROM centos:latest

ENV KEYCLOAK_VERSION 9.0.0
ENV JDBC_POSTGRES_VERSION 42.2.5
ENV JDBC_MYSQL_VERSION 5.1.46
ENV JDBC_MARIADB_VERSION 2.2.3
ENV JDBC_MSSQL_VERSION 7.4.1.jre11

ENV LAUNCH_JBOSS_IN_BACKGROUND=1
ENV PROXY_ADDRESS_FORWARDING=true
ENV LAUNCH_JBOSS_IN_BACKGROUND 1
ENV PROXY_ADDRESS_FORWARDING true
ENV JBOSS_HOME /opt/jboss/keycloak
ENV LANG en_US.UTF-8
ENV network.host=0.0.0.0

ARG GIT_REPO
ARG GIT_BRANCH
ARG KEYCLOAK_DIST=https://downloads.jboss.org/keycloak/$KEYCLOAK_VERSION/keycloak-$KEYCLOAK_VERSION.tar.gz

USER root

RUN microdnf update -y && microdnf install -y gzip hostname java-11-openjdk-headless openssl tar which && microdnf clean all
RUN yum update -y && yum install -y gzip hostname java-11-openjdk-headless openssl tar which && yum clean all

ADD tools /opt/jboss/tools
RUN /opt/jboss/tools/build-keycloak.sh

USER 1000
RUN sed -i -e 's/<web-context>auth<\/web-context>/<web-context>keycloak\/auth<\/web-context>/' $JBOSS_HOME/standalone/configuration/standalone.xml
RUN sed -i -e 's/<web-context>auth<\/web-context>/<web-context>keycloak\/auth<\/web-context>/' $JBOSS_HOME/standalone/configuration/standalone-ha.xml
RUN sed -i -e 's/name="\/"/name="\/keycloak\/"/' $JBOSS_HOME/standalone/configuration/standalone.xml
RUN sed -i -e 's/name="\/"/name="\/keycloak\/"/' $JBOSS_HOME/standalone/configuration/standalone-ha.xml
RUN sed -i -e 's/\/auth/\/keycloak\/auth"/' $JBOSS_HOME/welcome-content/index.html

EXPOSE 8080
EXPOSE 8443
Expand Down
4 changes: 3 additions & 1 deletion portal/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,14 @@ RUN yarn build
# production environment
FROM nginx:latest

RUN apt-get update && apt-get install wget -y
RUN apt-get update && apt-get install wget && apt-get install telnet -y

RUN apt-get install iputils-ping -y

RUN apt-get update && apt-get install nginx-extras -y

RUN apt-get install telnet

ARG REACT_APP_IN_SYLVA_GATEKEEPER_HOST
ARG REACT_APP_IN_SYLVA_GATEKEEPER_PORT
ARG REACT_APP_IN_SYLVA_SOURCE_MANAGER_HOST
Expand Down
2 changes: 1 addition & 1 deletion portal/nginx/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ upstream backend_gatekeeper {
upstream backend_keycloak {
hash $remote_addr$remote_port consistent;

server keycloak:7000;
server keycloak:8080;
}

upstream backend_source_manager {
Expand Down

0 comments on commit ad090fb

Please sign in to comment.