メイン コンテンツをスキップする 補完的コンテンツへスキップ

プロキシサーバーを使用するようTomcatを設定

手順

  1. Tomcatサーバーを停止します。
  2. 設定を完了させます。設定ファイルは<TomcatPath>/bin/setenv.shです。このファイルが存在しない場合は作成します。
  3. 次のパラメーターを追加し、設定に一致するよう変更します:
    CATALINA_OPTS=$CATALINA_OPTS -Dhttp.proxyHost=proxy.server.com # Specify the host name or IP address of your HTTP proxy server. You can use this parameter for http and https host names.
    CATALINA_OPTS=$CATALINA_OPTS -Dhttp.proxyPort=YourHttpProxyPort # Specify the port number of your proxy server.
    CATALINA_OPTS=$CATALINA_OPTS -Dhttp.nonProxyHosts="localhost|host.mydomain.com|192.168.0.1" # Specify a list of hosts separated by "|" that do not require access through your proxy server.
    例:
    CATALINA_OPTS=$CATALINA_OPTS -Dhttp.proxyHost=proxy.server.com 
    CATALINA_OPTS=$CATALINA_OPTS -Dhttp.proxyPort=3128
    CATALINA_OPTS=$CATALINA_OPTS -Dhttp.nonProxyHosts="localhost|host.mydomain.com|192.168.0.1"
    プロキシ設定の詳細は、https://docs.oracle.com/javase/8/docs/technotes/guides/net/proxies.htmlをご覧ください。
  4. Tomcatサーバーを再起動します。

このページは役に立ちましたか?

このページまたはコンテンツに、タイポ、ステップの省略、技術的エラーなどの問題が見つかった場合は、お知らせください。改善に役立たせていただきます。