1.7. Initialize the Fabric Server on EC2
Overview Copy linkLink copied to clipboard!
Copy linkLink copied to clipboard!
Now that you have a Fabric Server in the cloud, you need to set it up so that it is capable of expanding. You can initialize the Fabric Server so that it is capable of creating and provisioning new managed containers in the cloud.
Steps to initialize the Fabric Server Copy linkLink copied to clipboard!
Copy linkLink copied to clipboard!
To initialize the Fabric Server on EC2, perform the following steps:
- Log on to the remote Fabric Server using the command-line client. In the
InstallDir/bindirectory there is a client utility, which you can use to get console access to the remote Fabric Server. Enter the following at the command line:cd InstallDir/bin ./client -u admin -p admin -h 50.19.18.91
cd InstallDir/bin ./client -u admin -p admin -h 50.19.18.91Copy to Clipboard Copied! Toggle word wrap Toggle overflow Where50.19.18.91should be replaced by the public IP address of theregistrycontainer that you created in the previous section. If this command is successful, you should see the following client console:Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Deploy the
cloud-aws.ec2profile, to gain access to the cloud console commands:Fabric8:admin@registry> fabric:container-add-profile registry cloud-aws.ec2
Fabric8:admin@registry> fabric:container-add-profile registry cloud-aws.ec2Copy to Clipboard Copied! Toggle word wrap Toggle overflow NoteDuring re-deployment, you will automatically be logged out of the client! - Log back on to the Fabric Server using the
clientutility:./client -u admin -p admin -h 50.19.18.91
./client -u admin -p admin -h 50.19.18.91Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Register the Amazon EC2 provider, by entering the following console command:
Fabric8:admin@registry> fabric:cloud-service-add --name aws-ec2 --provider aws-ec2 --identity AccessKeyID --credential SecretAccessKey
Fabric8:admin@registry> fabric:cloud-service-add --name aws-ec2 --provider aws-ec2 --identity AccessKeyID --credential SecretAccessKeyCopy to Clipboard Copied! Toggle word wrap Toggle overflow - You can check that the
aws-ec2service has been registered, by entering the following command:Fabric8:admin@registry> fabric:cloud-service-list
Fabric8:admin@registry> fabric:cloud-service-listCopy to Clipboard Copied! Toggle word wrap Toggle overflow Which should display output like the following:Copy to Clipboard Copied! Toggle word wrap Toggle overflow