GlassFish V3 Prelude と OSGi その3
まず、/home/shioda/glassfishv3-prelude/glassfish/felix/conf/system.properties ファイルをエディタで開きます。コメントアウトされた3つの変数が書かれていますので、これを自分の環境に合わせて変更しコメントアウトを外します。私の場合ですと次のようになります。
com.sun.aas.installRoot=/home/shioda/glassfishv3-prelude/glassfish/ com.sun.aas.instanceRoot=/home/shioda/glassfishv3-prelude/glassfish/domains/domain1/ com.sun.aas.installRootURI=file:///home/shioda/glassfishv3-prelude/glassfish/このファイルの上の方にあるコメントに書いてありますが、asadmin などから起動するのであれば、これらの変数は launcher が面倒を見てくれるから設定する必要はありません。しかし今回は felix から直接起動ということで設定します。あとは felix を起動しましょう。
% java -jar /home/shioda/glassfishv3-prelude/glassfish/felix/bin/felix.jar Welcome to Felix. ================= Enter profile name: shioda ...プロファイル名は何でも良いと思います。$HOME にそのプロファイルのデータが置かれるようです。
n% ls /home/shioda/.felix/shioda bundle0 bundle114 bundle18 bundle34 bundle50 bundle67 bundle83 bundle1 bundle115 bundle19 bundle35 bundle51 bundle68 bundle84 bundle10 bundle116 bundle2 bundle36 bundle52 bundle69 bundle85 bundle100 bundle117 bundle20 bundle37 bundle53 bundle7 bundle86 bundle101 bundle118 bundle21 bundle38 bundle54 bundle70 bundle87 bundle102 bundle119 bundle22 bundle39 bundle55 bundle71 bundle88 bundle103 bundle12 bundle23 bundle4 bundle56 bundle72 bundle89 bundle104 bundle120 bundle24 bundle40 bundle57 bundle73 bundle9 bundle105 bundle121 bundle25 bundle41 bundle58 bundle74 bundle90 bundle106 bundle122 bundle26 bundle42 bundle59 bundle75 bundle91 bundle107 bundle123 bundle27 bundle43 bundle6 bundle76 bundle92 bundle108 bundle124 bundle28 bundle44 bundle60 bundle77 bundle93 bundle109 bundle125 bundle29 bundle45 bundle61 bundle78 bundle94 bundle11 bundle13 bundle3 bundle46 bundle62 bundle79 bundle95 bundle110 bundle14 bundle30 bundle47 bundle63 bundle8 bundle96 bundle111 bundle15 bundle31 bundle48 bundle64 bundle80 bundle97 bundle112 bundle16 bundle32 bundle49 bundle65 bundle81 bundle98 bundle113 bundle17 bundle33 bundle5 bundle66 bundle82 bundle99FELIX SHELL は前回やったのと同様にポート 6666 にアクセスすれば使えます。