diff options
author | Andreas Maunz <andreas@maunz.de> | 2011-11-16 15:21:07 +0100 |
---|---|---|
committer | Andreas Maunz <andreas@maunz.de> | 2011-11-16 15:21:07 +0100 |
commit | 483d87ed8064573f60194f7936701d21f8728e61 (patch) | |
tree | f8ef74d71d1a000760c6e0d1b35792896cb77fee | |
parent | 69fa1d589bce1d6b17ea9948cce3cb80a7f84819 (diff) |
Fixed PORT to NGINX_PORT
-rw-r--r-- | aa-server.yaml | 30 | ||||
-rwxr-xr-x | config.sh | 4 | ||||
-rw-r--r-- | nginx.conf | 12 | ||||
-rwxr-xr-x | nginx.sh | 8 | ||||
-rwxr-xr-x | opentox-ruby.sh | 4 | ||||
-rw-r--r-- | production.yaml | 14 |
6 files changed, 36 insertions, 36 deletions
diff --git a/aa-server.yaml b/aa-server.yaml index 5ca2b72..aa08799 100644 --- a/aa-server.yaml +++ b/aa-server.yaml @@ -15,25 +15,25 @@ # Exceptions: :free_uris: #request-method for uri not controlled by A&A ? - :GET - : - !ruby/regexp /http:\/\/ESCAPEDSERVERPORT\/algorithm/ - - "http://SERVERNAMEPORT/model" - - "http://SERVERNAMEPORT/dataset" - - "http://SERVERNAMEPORT/validation" - - !ruby/regexp /http:\/\/ESCAPEDSERVERPORT\/validation\/resources/ - - !ruby/regexp /http:\/\/ESCAPEDSERVERPORT\/validation\/[a-z,A-Z,\/,_\-]*$/ + : - !ruby/regexp /http:\/\/ESCAPEDSERVERNGINX_PORT\/algorithm/ + - "http://SERVERNAMENGINX_PORT/model" + - "http://SERVERNAMENGINX_PORT/dataset" + - "http://SERVERNAMENGINX_PORT/validation" + - !ruby/regexp /http:\/\/ESCAPEDSERVERNGINX_PORT\/validation\/resources/ + - !ruby/regexp /http:\/\/ESCAPEDSERVERNGINX_PORT\/validation\/[a-z,A-Z,\/,_\-]*$/ ? - :GET - :POST - : - !ruby/regexp /http:\/\/ESCAPEDSERVERPORT\/toxcreate\/[a-z,A-Z,\/,_\-]*$/ - - !ruby/regexp /http:\/\/ESCAPEDSERVERPORT\/task/ - - !ruby/regexp /http:\/\/ESCAPEDSERVERPORT\/compound/ + : - !ruby/regexp /http:\/\/ESCAPEDSERVERNGINX_PORT\/toxcreate\/[a-z,A-Z,\/,_\-]*$/ + - !ruby/regexp /http:\/\/ESCAPEDSERVERNGINX_PORT\/task/ + - !ruby/regexp /http:\/\/ESCAPEDSERVERNGINX_PORT\/compound/ - !ruby/regexp /sign_(in|out)$/ ? - :PUT - : - !ruby/regexp /http:\/\/ESCAPEDSERVERPORT\/task/ + : - !ruby/regexp /http:\/\/ESCAPEDSERVERNGINX_PORT\/task/ :authorize_exceptions: #request-method for uri only authenticated, no authorization ? - :POST - : - !ruby/regexp /http:\/\/ESCAPEDSERVERPORT\/algorithm/ - - "http://SERVERNAMEPORT/dataset" - - "http://SERVERNAMEPORT/model" - - "http://SERVERNAMEPORT/validation" - - !ruby/regexp /http\:\/\/ESCAPEDSERVERPORT\/validation\/[a-z,A-Z,\/,_\-]*$/ + : - !ruby/regexp /http:\/\/ESCAPEDSERVERNGINX_PORT\/algorithm/ + - "http://SERVERNAMENGINX_PORT/dataset" + - "http://SERVERNAMENGINX_PORT/model" + - "http://SERVERNAMENGINX_PORT/validation" + - !ruby/regexp /http\:\/\/ESCAPEDSERVERNGINX_PORT\/validation\/[a-z,A-Z,\/,_\-]*$/ @@ -22,8 +22,8 @@ REDIS_NUM_VER="2.2.2" # 4) Server settings. NGINX_SERVERNAME="toxcreate3.in-silico.ch" WWW_DEST="$OT_PREFIX/www" -PORT=":8081" # set to empty string ("") for port 80 otherwise set to port *using colon* e.g. ":8080" -OHM_PORT="6379" # set to port (no colon) +NGINX_PORT=":8081" # set to empty string ("") for port 80 otherwise set to port *using colon* e.g. ":8080" +OHM_PORT="6380" # set to port (no colon) # Done. @@ -8,14 +8,14 @@ http { server_names_hash_bucket_size 256; - passenger_root RUBY_DEST/lib/ruby/gems/1.8/gems/PASSENGER; - passenger_ruby RUBY_DEST/bin/ruby; - passenger_default_user USER; + passenger_root /home/am/opentox-ruby/ruby-enterprise-1.8.7-2011.03/lib/ruby/gems/1.8/gems/passenger-3.0.9; + passenger_ruby /home/am/opentox-ruby/ruby-enterprise-1.8.7-2011.03/bin/ruby; + passenger_default_user am; passenger_log_level 2; passenger_spawn_method conservative; #passenger_use_global_queue on; - include NGINX_DEST/conf/mime.types; + include /home/am/opentox-ruby/nginx/conf/mime.types; default_type application/octet-stream; sendfile on; @@ -25,9 +25,9 @@ http { server { listen PORT; client_max_body_size 5000m; - server_name SERVERNAME; + server_name z21mn; location / { - root WWW_DEST; + root /home/am/opentox-ruby/www; passenger_enabled on; } passenger_base_uri /compound; @@ -53,11 +53,11 @@ servername=`hostname` $GIT checkout nginx.conf>>$LOG 2>&1 cmd="sed -i -e \"s,PASSENGER,$passenger,;s,SERVERNAME,$servername,;s,RUBY_DEST,$RUBY_DEST,;s,NGINX_DEST,$NGINX_DEST,;s,WWW_DEST,$WWW_DEST,\" ./nginx.conf" && run_cmd "$cmd" "Config" cmd="sed -i -e \"s,USER,`whoami`,\" ./nginx.conf" && run_cmd "$cmd" "User" -PORT=`echo "$PORT" | sed 's/^.//g'` -if [ -z "$PORT" ]; then - PORT=80 +NGINX_PORT=`echo "$NGINX_PORT" | sed 's/^.//g'` +if [ -z "$NGINX_PORT" ]; then + NGINX_PORT=80 fi -cmd="sed -i -e \"s,PORT,$PORT,\" ./nginx.conf" && run_cmd "$cmd" "Port" +cmd="sed -i -e \"s,NGINX_PORT,$NGINX_PORT,\" ./nginx.conf" && run_cmd "$cmd" "NGINX_PORT" cmd="cp ./nginx.conf \"$NGINX_DEST/conf\"" && run_cmd "$cmd" "Copy" if [ ! -f $NGINX_CONF ]; then diff --git a/opentox-ruby.sh b/opentox-ruby.sh index f6fa077..ec7f5c2 100755 --- a/opentox-ruby.sh +++ b/opentox-ruby.sh @@ -71,8 +71,8 @@ mkdir -p "$HOME/.opentox/tmp" >>$LOG 2>&1 $GIT checkout production.yaml >>$LOG 2>&1 $GIT checkout aa-$OT_INSTALL.yaml >>$LOG 2>&1 -cmd="sed -e \"s,SERVERNAME,$servername,;s,ESCAPEDSERVER,$escapedserver,;s,LOGGER,$logger,;s,AA,$aa,;s,WWW_DEST,$WWW_DEST,;s,PORT,$PORT,;s,OHM_PORT,$OHM_PORT,\" production.yaml > $HOME/.opentox/config/production.yaml" && run_cmd "$cmd" "Config 1" -cmd="sed -e \"s,SERVERNAME,$servername,;s,ESCAPEDSERVER,$escapedserver,;s,LOGGER,$logger,;s,AA,$aa,;s,WWW_DEST,$WWW_DEST,;s,PORT,$PORT,;s,OHM_PORT,$OHM_PORT,\" aa-$OT_INSTALL.yaml >> $HOME/.opentox/config/production.yaml" && run_cmd "$cmd" "Config 2" +cmd="sed -e \"s,SERVERNAME,$servername,;s,ESCAPEDSERVER,$escapedserver,;s,LOGGER,$logger,;s,AA,$aa,;s,WWW_DEST,$WWW_DEST,;s,NGINX_PORT,$NGINX_PORT,;s,OHM_PORT,$OHM_PORT,\" production.yaml > $HOME/.opentox/config/production.yaml" && run_cmd "$cmd" "Config 1" +cmd="sed -e \"s,SERVERNAME,$servername,;s,ESCAPEDSERVER,$escapedserver,;s,LOGGER,$logger,;s,AA,$aa,;s,WWW_DEST,$WWW_DEST,;s,NGINX_PORT,$NGINX_PORT,;s,OHM_PORT,$OHM_PORT,\" aa-$OT_INSTALL.yaml >> $HOME/.opentox/config/production.yaml" && run_cmd "$cmd" "Config 2" if [ "$OT_BRANCH" = "development" ] || expr match "$OT_BRANCH" "release"; then mkdir -p $WWW_DEST/opentox >>$LOG 2>&1 diff --git a/production.yaml b/production.yaml index 709b133..e0f39d4 100644 --- a/production.yaml +++ b/production.yaml @@ -2,13 +2,13 @@ :services: # make sure to enter a full uri (including training slash) - opentox-compound: "http://SERVERNAMEPORT/compound/" - opentox-dataset: "http://SERVERNAMEPORT/dataset/" - opentox-algorithm: "http://SERVERNAMEPORT/algorithm/" - opentox-model: "http://SERVERNAMEPORT/model/" - opentox-task: "http://SERVERNAMEPORT/task/" - opentox-toxcreate: "http://SERVERNAMEPORT/toxcreate/" - opentox-validation: "http://SERVERNAMEPORT/validation/" + opentox-compound: "http://SERVERNAMENGINX_PORT/compound/" + opentox-dataset: "http://SERVERNAMENGINX_PORT/dataset/" + opentox-algorithm: "http://SERVERNAMENGINX_PORT/algorithm/" + opentox-model: "http://SERVERNAMENGINX_PORT/model/" + opentox-task: "http://SERVERNAMENGINX_PORT/task/" + opentox-toxcreate: "http://SERVERNAMENGINX_PORT/toxcreate/" + opentox-validation: "http://SERVERNAMENGINX_PORT/validation/" opentox-ontology: "http://apps.ideaconsult.net:8080/ontology" :json_hosts: |