-
Notifications
You must be signed in to change notification settings - Fork 14
Tutorial Part 6
Previous: Installing and deploying snapshot and release configuration bundles
In the previous chapters of the tutorial, all the necessary preliminaries to set up airship were done.
- A local environment for airship service installation was created
- Configuration for coordinator and agent was set up
- Configuration bundles were released and installed.
Now it is time to install the coordinator and agent binary. This tutorial uses a released version of airship, so the binaries are available from Maven Central. When using a development or unreleased version, the binaries would either need to be deployed to the repository server or available in the local repository.
With configuration and binary available, airship can now deploy coordinator and agent into the local environment:
airship --batch install io.airlift.airship:airship-coordinator:0.13 @io.airlift.airship.tutorial:local-coordinator:1
uuid host machine status binary config
22d9 localhost local STOPPED airship-coordinator:0.13 @local-coordinator:1
airship --batch install airship-agent:0.13 @local-agent:1
uuid host machine status binary config
1b5c localhost local STOPPED airship-agent:0.13 @local-agent:1
airship show
uuid host machine status binary config
22d9 localhost local STOPPED airship-coordinator:0.13 @local-coordinator:1
1b5c localhost local STOPPED airship-agent:0.13 @local-agent:1
Note: Without the --batch
option, airship will ask for confirmation for each service installation.
The first install command uses the full GAV (groupId:artifactId:version) triple to install the coordinator and its configuration. The second command omits the groupId. In this case, the group id is resolved using the maven-default-group-id
settings that were given when the local environment was installed. For any other environment, the groups in the coordinator.default-group-id
of the coordinator are used.
When listing services using airship show
, binary and configuration artifacts will be shortened if they use a groupId that is configured as a default group id.
Once the services are successfully installed, they can now be started.
airship --batch start -u 22d9
uuid host machine status binary config
22d9 localhost local RUNNING airship-coordinator:0.13 @local-coordinator:1
airship start -b airship-agent
uuid host machine status binary config
1b5c localhost local STOPPED airship-agent:0.13 @local-agent:1
Are you sure you would like to START these servers? [Y/n] y
uuid host machine status binary config
1b5c localhost local RUNNING airship-agent:0.13 @local-agent:1
airship show
uuid host machine status binary config
22d9 localhost local RUNNING airship-coordinator:0.13 @local-coordinator:1
1b5c localhost local RUNNING airship-agent:0.13 @local-agent:1
The first form of the airship start
command uses the service uuid (22d9) to select and start the coordinator. The second form uses the name of the binary (airship-agent). More details about selectors available with the start
command can be displayed using airship help start
.
The subsequent airship show
command now reports both services as RUNNING
.
Next: Odds and ends