Skip to content

Commit 8e539ab

Browse files
author
Eliot Eshelman
committed
Simplify directory paths and naming of scripts
1 parent 04e897e commit 8e539ab

File tree

7 files changed

+18
-17
lines changed

7 files changed

+18
-17
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,18 +11,18 @@ ubiquitous screen utility) and resource monitoring (via htop/top).
1111

1212
###Usage
1313

14-
Ensure the `mcms_interactive_session` script is in your PATH (usually this is
14+
Ensure the `interactive_session` script is in your PATH (usually this is
1515
already done for you by the system administrator). From your shell, run:
16-
`mcms_interactive_session`
16+
`interactive_session`
1717

1818
To see a full list of options, run:
19-
`mcms_interactive_session -h`
19+
`interactive_session -h`
2020

2121
The script will allocate the requested cluster resources, wait for them to
2222
become available and then log you into the compute node. You may specify which
2323
resources you require via command-line arguments (or via your own configuration
24-
file: `~/.config/mcms_interactive_session.conf`). Your administrator may have
25-
also set up a system-wide configuration file (but any options you specify will
24+
file: `~/.config/interactive_session.conf`). Your administrator may have also
25+
set up a system-wide configuration file (but any options you specify will
2626
over-ride the default settings in the system-wide configuration file).
2727

2828
###Installation Requirements

usr/bin/mcms_interactive_session renamed to usr/bin/interactive_session

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,8 @@ export SCRIPT_DIR="$( dirname "$( readlink -f "${BASH_SOURCE[0]}" )" )"
5656
export SLURM_PATH="$( dirname "$( readlink -f "$(which squeue)" )" )"
5757

5858

59-
GLOBAL_CONFIG=/etc/microway/mcms_interactive_session.conf
60-
USER_CONFIG=~/.config/mcms_interactive_session.conf
59+
GLOBAL_CONFIG=/etc/microway/interactive_session.conf
60+
USER_CONFIG=~/.config/interactive_session.conf
6161

6262

6363
function help() {
@@ -107,7 +107,7 @@ function help() {
107107
(major changes by Josh McSavaney)
108108
109109
Modified scripts (with bugfixes and additional feature support):
110-
Copyright (C) 2015 Microway, Inc. All rights reserved.
110+
Copyright (C) 2015-2016 Microway, Inc. All rights reserved.
111111
http://www.microway.com
112112
113113
EOF
@@ -415,10 +415,10 @@ assemble_allocation_options
415415

416416

417417
# This script will be started on the remote node (by the batch scheduler)
418-
BATCH_SCRIPT="${SCRIPT_DIR}/../libexec/mcms_interactive_batch_script"
418+
BATCH_SCRIPT="${SCRIPT_DIR}/../libexec/microway/interactive_batch_script"
419419

420420
# This script will be called by SSH (to connect the user to their session)
421-
CONNECTION_SCRIPT="${SCRIPT_DIR}/../libexec/mcms_interactive_connection_script"
421+
CONNECTION_SCRIPT="${SCRIPT_DIR}/../libexec/microway/interactive_connection_script"
422422

423423

424424

usr/libexec/mcms_interactive_batch_script renamed to usr/libexec/microway/interactive_batch_script

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ if [[ -z "$SLURM_JOB_ID" ]]; then
5454
fi
5555

5656

57-
SCREEN_RC=/etc/microway/mcms_interactive_screenrc.conf
57+
SCREEN_RC=/etc/microway/interactive_screenrc.conf
5858

5959
if [[ ! -r "${SCREEN_RC}" ]]; then
6060
echo "Unable to locate the necessary screenrc file:"

usr/libexec/mcms_interactive_connection_script renamed to usr/libexec/microway/interactive_connection_script

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
#
1717
#
1818
# Modified scripts (with bugfixes and additional feature support):
19-
# Copyright (C) 2015 Microway, Inc. All rights reserved.
19+
# Copyright (C) 2015-2016 Microway, Inc. All rights reserved.
2020
# http://www.microway.com
2121
#
2222
#
@@ -39,8 +39,11 @@
3939
################################################################################
4040
#
4141
# This script connects a user to their existing screen session (which is started
42-
# by the mcms_interactive_session utility). That script will SSH into the node
43-
# that has been reserved by SLURM and run this script.
42+
# by the interactive_session utility). That interactive_session script will SSH
43+
# into the node that has been reserved by SLURM and run this script.
44+
#
45+
# In this script, we set up the X11 session (if there is one), start up a 'top'
46+
# monitoring tool and connect the user to the seesion.
4447
#
4548
################################################################################
4649

@@ -54,8 +57,6 @@ fi
5457

5558
SCREENSESSION="$2"
5659

57-
SCRIPT_DIR="$( dirname "$( readlink -f "${BASH_SOURCE[0]}" )" )"
58-
5960

6061
# There is a possible race condition here. If the job has just started, we
6162
# might be trying to connect to the screen session before it has finished
@@ -97,7 +98,7 @@ fi
9798
screen -S "$SCREENSESSION" -X screen -t "bash" 1 bash -i -l
9899

99100
# Start up a splash screen with a welcome message
100-
screen -S "$SCREENSESSION" -X screen -t "Help" 2 ${SCRIPT_DIR}/../libexec/mcms_interactive_splash
101+
screen -S "$SCREENSESSION" -X screen -t "Help" 2 /usr/libexec/microway/interactive_splash
101102

102103
# Remove the META tab, which has outlived its usefulness
103104
screen -p0 -S "$SCREENSESSION" -X kill

0 commit comments

Comments
 (0)