Skip to content

Commit

Permalink
Update provisioning so individual targets, and helper scripts, can be…
Browse files Browse the repository at this point in the history
… installed
  • Loading branch information
AdamSimpson committed Feb 6, 2018
1 parent 10c6fd7 commit f5ae86a
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 13 deletions.
11 changes: 8 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ project(ContainerBuilder)
set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

SET(CMAKE_SKIP_INSTALL_ALL_DEPENDENCY TRUE)

include_directories(BuilderQueue/include Builder/include Client/include Common/include)

set(SOURCE_FILES_QUEUE
Expand Down Expand Up @@ -80,9 +82,12 @@ target_link_libraries(builder-queue ${Boost_LIBRARIES})
target_link_libraries(builder-server ${Boost_LIBRARIES})
target_link_libraries(container-builder ${Boost_LIBRARIES})

install(TARGETS builder-queue builder-server container-builder RUNTIME DESTINATION bin)
# Install executables
install(TARGETS builder-queue COMPONENT builder-queue DESTINATION bin OPTIONAL)
install(TARGETS builder-server COMPONENT builder-server DESTINATION bin OPTIONAL)
install(TARGETS container-builder COMPONENT container-builder DESTINATION bin OPTIONAL)

# Install scripts
# Install scripts if target the builder-server
install(FILES ${SCRIPTS}
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_WRITE GROUP_EXECUTE WORLD_READ
WORLD_EXECUTE DESTINATION "${CMAKE_INSTALL_PREFIX}/bin")
WORLD_EXECUTE DESTINATION "${CMAKE_INSTALL_PREFIX}/bin" COMPONENT server OPTIONAL)
4 changes: 2 additions & 2 deletions Deployment/deploy-summitdev.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ rm -rf /boost_1_66_0
cd ${TOP_LEVEL}
rm -rf build && mkdir build && cd build
CC=gcc CXX=g++ cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=${SW_ROOT} ..
make
make install
make container-builder
cmake -DCOMPONENT=container-builder -P cmake_install.cmake

# Generate a public modulefile
MF_ROOT=/sw/summitdev/modulefiles/core/container-builder
Expand Down
4 changes: 2 additions & 2 deletions Deployment/deploy-titan.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ rm -rf /boost_1_66_0
cd ${TOP_LEVEL}
rm -rf build && mkdir build && cd build
CC=gcc CXX=g++ cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=${SW_ROOT} ..
make
make install
make container-builder
cmake -DCOMPONENT=container-builder -P cmake_install.cmake

# Generate a public modulefile
MF_ROOT=/sw/xk6/modulefiles/container-builder
Expand Down
6 changes: 3 additions & 3 deletions Deployment/provision-builder.sh
Original file line number Diff line number Diff line change
Expand Up @@ -88,10 +88,10 @@ git clone https://code.ornl.gov/olcf/container-builder.git
cd container-builder
mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX="/usr/local" ..
make
make install

make builder-server
cmake -DCOMPONENT=builder-server -P cmake_install.cmake
cd /
rm -rf /container-builder

# Create systemd script and launch the Builder daemon
cat << EOF > /etc/systemd/system/builder-server.service
Expand Down
6 changes: 3 additions & 3 deletions Deployment/provision-queue.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@ cd /
git clone https://code.ornl.gov/olcf/container-builder.git
cd container-builder
mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTAL_PREFIX="/usr/local" ..
make
make install
cmake -DCOMPONENT=builder-queue -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTAL_PREFIX="/usr/local" ..
make builder-queue
cmake -DCOMPONENT=builder-queue -P cmake_install.cmake
cd /
rm -rf /container-builder

Expand Down

0 comments on commit f5ae86a

Please sign in to comment.