Skip to content

Commit

Permalink
Improvements for release
Browse files Browse the repository at this point in the history
  • Loading branch information
Morgan Rodgers committed Aug 15, 2019
1 parent 395d6d9 commit cb551a8
Show file tree
Hide file tree
Showing 5 changed files with 83 additions and 5 deletions.
11 changes: 11 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Changelog
All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [Unreleased]

## 0.0.1 - 2019-08-15
### Added
- Initial release!
67 changes: 65 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,65 @@
# bc_osc_stata
Batch Connect - OSC Stata
# Batch Connect - OSC Stata

![GitHub Release](https://img.shields.io/github/release/osc/bc_osc_stata.svg)
[![GitHub License](https://img.shields.io/badge/license-MIT-green.svg)](https://opensource.org/licenses/MIT)

A Batch Connect app designed for OSC OnDemand that launches Stata within an
Owens batch job.

## Prerequisites

This Batch Connect app requires the following software be installed on the
**compute nodes** that the batch job is intended to run on (**NOT** the
OnDemand node):

- [Stata] 15
- [Xfce Desktop] 4+

For VNC server support:

- [TurboVNC] 2.1+
- [websockify] 0.8.0+

**Optional** software:

- [Lmod] 6.0.1+ or any other `module purge` and `module load <modules>` based
CLI used to load appropriate environments within the batch job

[Stata]: https://www.stata.com/
[Xfce Desktop]: https://xfce.org/
[TurboVNC]: http://www.turbovnc.org/
[websockify]: https://github.com/novnc/websockify
[Lmod]: https://www.tacc.utexas.edu/research-development/tacc-projects/lmod

## Install

Use git to clone this app and checkout the desired branch/version you want to
use:

```sh
scl enable rh-git29 -- git clone <repo>
cd <dir>
scl enable rh-git29 -- git checkout <tag/branch>
```

You will not need to do anything beyond this as all necessary assets are
installed. You will also not need to restart this app as it isn't a Passenger
app.

To update the app you would:

```sh
cd <dir>
scl enable rh-git29 -- git fetch
scl enable rh-git29 -- git checkout <tag/branch>
```

Again, you do not need to restart the app as it isn't a Passenger app.

## Contributing

1. Fork it ( https://github.com/OSC/bc_osc_stata/fork )
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create a new Pull Request
Binary file added icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion manifest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ category: Interactive Apps
subcategory: GUIs
role: batch_connect
description: |
This app will laynch a [Stata] GUI on the [Owens cluster]. You will be able to interact with the Stata GUI
This app will launch a [Stata] GUI on the [Owens cluster]. You will be able to interact with the Stata GUI
through a VNC session.
[Stata]: https://www.stata.com/
Expand Down
8 changes: 6 additions & 2 deletions template/script.sh.erb
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,13 @@ cd "${HOME}"
# Load the required enviornment
module load stata

# Launch stat
# Launch stata
# note that xstata-mp doesn't block so we have to watch it
xstata-mp
stata_pid=$(ps | grep 'xstata-mp' | awk '{print $1}')

# Get the PID of the last xstata-mp process started that I own
stata_pid=$( pgrep -u "$USER" 'xstata-mp' | tail )
# As long as the PID directory exists we wait
while [[ -d "/proc/$stata_pid" ]]; do
sleep 1
done

0 comments on commit cb551a8

Please sign in to comment.