-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
912d477
commit 0cc25e3
Showing
7 changed files
with
266 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
[core] | ||
editor = nano |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
{ | ||
"cells": [ | ||
{ | ||
"cell_type": "markdown", | ||
"id": "c86cd54f-b73c-4781-b6eb-89c79d3d3b22", | ||
"metadata": {}, | ||
"source": [ | ||
"## Acknowledgements\n", | ||
"\n", | ||
"Launching this JupyterHub server is the result of a collaboration between several research and academic institutions and their staff. For Jetstream2 and JupyterHub expertise, we thank Andrea Zonca (San Diego Supercomputing Center), Jeremy Fischer, Mike Lowe (Indiana University), the NSF Jetstream2 (`doi:10.1145/3437359.3465565`) team.\n", | ||
"\n", | ||
"This work employs the NSF Jetstream2 Cloud at Indiana University through allocation EES220002 from the Advanced Cyberinfrastructure Coordination Ecosystem: Services & Support (ACCESS) program, which is supported by National Science Foundation grants #2138259, #2138286, #2138307, #2137603, and #2138296.\n", | ||
"\n", | ||
"Unidata is one of the University Corporation for Atmospheric Research (UCAR)'s Community Programs (UCP), and is funded primarily by the National Science Foundation (AGS-2403649).\n", | ||
"\n", | ||
"## To Acknowledge This JupyterHub and the Unidata Science Gateway\n", | ||
"\n", | ||
"If you have benefited from the Unidata Science Gateway, please cite `doi:10.5065/688s-2w73`. Additional citation information can be found in this [Citation File Format file](https://raw.githubusercontent.com/Unidata/science-gateway/master/CITATION.cff).\n" | ||
] | ||
} | ||
], | ||
"metadata": { | ||
"kernelspec": { | ||
"display_name": "Python 3 (ipykernel)", | ||
"language": "python", | ||
"name": "python3" | ||
}, | ||
"language_info": { | ||
"codemirror_mode": { | ||
"name": "ipython", | ||
"version": 3 | ||
}, | ||
"file_extension": ".py", | ||
"mimetype": "text/x-python", | ||
"name": "python", | ||
"nbconvert_exporter": "python", | ||
"pygments_lexer": "ipython3", | ||
"version": "3.10.6" | ||
} | ||
}, | ||
"nbformat": 4, | ||
"nbformat_minor": 5 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
# Heavily borrowed from docker-stacks/minimal-notebook/ | ||
# https://github.com/jupyter/docker-stacks/blob/main/minimal-notebook/Dockerfile | ||
|
||
ARG BASE_CONTAINER=jupyter/minimal-notebook | ||
FROM $BASE_CONTAINER | ||
|
||
ENV DEFAULT_ENV_NAME=uw-fall-2024 | ||
|
||
LABEL maintainer="Unidata <[email protected]>" | ||
|
||
USER root | ||
|
||
RUN apt-get update && \ | ||
apt-get install -y --no-install-recommends vim curl zip unzip nano && \ | ||
apt-get clean && \ | ||
rm -rf /var/lib/apt/lists/* | ||
|
||
USER $NB_UID | ||
|
||
ADD environment.yml /tmp | ||
ADD environment-satpy.yml /tmp | ||
|
||
RUN mamba install --quiet --yes \ | ||
'conda-forge::nb_conda_kernels' \ | ||
'conda-forge::jupyterlab-git' \ | ||
'conda-forge::ipywidgets' && \ | ||
mamba update mamba -y && \ | ||
mamba env update --name $DEFAULT_ENV_NAME -f /tmp/environment.yml && \ | ||
mamba env update --name uw-satpy-fall-2024 -f /tmp/environment-satpy.yml && \ | ||
pip install --no-cache-dir nbgitpuller && \ | ||
mamba clean --all -f -y && \ | ||
jupyter lab clean -y && \ | ||
npm cache clean --force && \ | ||
rm -rf /home/$NB_USER/.cache/yarn && \ | ||
rm -rf /home/$NB_USER/.node-gyp && \ | ||
fix-permissions $CONDA_DIR && \ | ||
fix-permissions /home/$NB_USER | ||
|
||
COPY Acknowledgements.ipynb / | ||
COPY .gitconfig / | ||
|
||
USER $NB_UID |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
#!/bin/bash | ||
|
||
# Check if an image name is provided | ||
if [ -z "$1" ]; then | ||
echo "Error: No image name provided." | ||
echo "Usage: $0 <image-name>" | ||
exit 1 | ||
fi | ||
|
||
IMAGE_NAME=$1 | ||
|
||
DATE_TAG=$(date "+%Y%b%d_%H%M%S") | ||
RANDOM_HEX=$(openssl rand -hex 2) | ||
TAG="${DATE_TAG}_${RANDOM_HEX}" | ||
|
||
FULL_TAG="unidata/$IMAGE_NAME:$TAG" | ||
|
||
echo "Building Docker image with tag: $FULL_TAG" | ||
|
||
docker build --no-cache --pull --tag "$FULL_TAG" . | ||
|
||
# Check if the build was successful | ||
if [ $? -eq 0 ]; then | ||
echo "Docker image built successfully: $FULL_TAG" | ||
else | ||
echo "Error: Docker build failed." | ||
exit 1 | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
name: uw-satpy-fall-2024 | ||
channels: | ||
- conda-forge | ||
- defaults | ||
dependencies: | ||
# Required by JupyterLab | ||
- ipykernel | ||
- nb_conda_kernels | ||
- python=3.11 | ||
# User requested packages | ||
- cartopy | ||
- goes2go | ||
- imageio | ||
- imageio-ffmpeg | ||
- matplotlib | ||
- satpy | ||
- xarray |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
name: uw-fall-2024 | ||
channels: | ||
- defaults | ||
- conda-forge | ||
- anaconda-fusion | ||
dependencies: | ||
# Required by JupyterLab | ||
- ipykernel | ||
- nb_conda_kernels | ||
- python=3.11 | ||
# User requested packages | ||
- altair | ||
- aospy | ||
- bokeh | ||
- build | ||
- cartopy | ||
- celluloid | ||
- cfgrib | ||
- cmocean | ||
- dask | ||
- datashader | ||
- distributed | ||
- fsspec | ||
- geopandas | ||
- geoviews | ||
- gsw | ||
- h5netcdf | ||
- h5py | ||
- hatchling | ||
- hvplot | ||
- ipykernel | ||
- ipympl | ||
- ipywidgets | ||
- iris | ||
- jupyterlab | ||
- matplotlib | ||
- matplotlib-inline | ||
- metpy | ||
- nbdime | ||
- nc-time-axis | ||
- netcdf-fortran | ||
- netcdf4 | ||
- nodejs | ||
- numcodecs | ||
- numpy | ||
- pandas | ||
- plotly | ||
- plotnine | ||
- pyresample | ||
- pytest | ||
- python | ||
- python-graphviz | ||
- scikit-image | ||
- scikit-learn | ||
- scipy | ||
- seaborn | ||
- setuptools | ||
- siphon | ||
- twine | ||
- vega_datasets | ||
- xarray | ||
- xesmf | ||
- xgcm | ||
- zarr |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
hub: | ||
cookieSecret: "xxx" | ||
config: | ||
Authenticator: | ||
admin_users: | ||
- admins | ||
#If you have a large list of users, consider using allowed_users.yaml | ||
allowed_users: | ||
- users | ||
# necessary for jhub admins to add user via admin page `<url>/hub/admin` | ||
allow_existing_users: true | ||
GitHubOAuthenticator: | ||
client_id: "xxx" | ||
client_secret: "xxx" | ||
oauth_callback_url: "https://uw24f-1.ees220002.projects.jetstream-cloud.org:443/oauth_callback" | ||
JupyterHub: | ||
authenticator_class: github | ||
|
||
|
||
proxy: | ||
secretToken: "xxx" | ||
|
||
ingress: | ||
enabled: true | ||
annotations: | ||
kubernetes.io/ingress.class: "nginx" | ||
cert-manager.io/cluster-issuer: "letsencrypt" | ||
#For manually issuing certificates: see vms/jupyter/readme.md | ||
#cert-manager.io/issuer: "incommon" | ||
nginx.ingress.kubernetes.io/proxy-body-size: 500m | ||
hosts: | ||
- "uw24f-1.ees220002.projects.jetstream-cloud.org" | ||
tls: | ||
- hosts: | ||
- "uw24f-1.ees220002.projects.jetstream-cloud.org" | ||
secretName: certmanager-tls-jupyterhub | ||
|
||
singleuser: | ||
extraEnv: | ||
NBGITPULLER_DEPTH: "0" | ||
storage: | ||
capacity: 10Gi | ||
startTimeout: 600 | ||
memory: | ||
guarantee: 4G | ||
limit: 4G | ||
cpu: | ||
guarantee: 1 | ||
limit: 2 | ||
defaultUrl: "/lab" | ||
image: | ||
name: unidata/uw24f | ||
tag: "xxx" | ||
lifecycleHooks: | ||
postStart: | ||
exec: | ||
command: | ||
- "bash" | ||
- "-c" | ||
- > | ||
dir="/home/jovyan/.ssh"; [ -d $dir ] && { chmod 700 $dir && \ | ||
chmod -f 600 $dir/* && chmod -f 644 $dir/*.pub; } || true; | ||
cp -t /home/jovyan /Acknowledgements.ipynb; | ||
# gitpuller https://github.com/HannahZanowski/AOS573 main AOS573; | ||
[[ -f $HOME/.bashrc ]] || cp /etc/skel/.bashrc $HOME/; | ||
[[ -f $HOME/.profile ]] || cp /etc/skel/.profile $HOME/; | ||
[[ -f $HOME/.bash_logout ]] || cp /etc/skel/.bash_logout $HOME/; | ||
[[ -f $HOME/.condarc ]] || cp /.condarc $HOME/; | ||
[[ -f $HOME/.gitconfig ]] || cp /.gitconfig $HOME/; | ||
[ -d "/share" ] && [ ! -L ~/share ] && ln -s /share ~/share || true; |