Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(sas):add default file shortcut #646

Merged
merged 11 commits into from
Jul 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .github/workflows/build_push.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,6 @@ jobs:
- jupyterlab-cpu
- jupyterlab-pytorch
- jupyterlab-tensorflow
- remote-desktop
needs: pre-build-checks
runs-on: ubuntu-latest
services:
Expand Down
5 changes: 5 additions & 0 deletions docker-bits/6_sas.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ ARG QUARTO_VERSION=1.4.176
ARG QUARTO_SHA=c06edd8930903a1018a27eb9f70fb9037b28a3cd8a7eb6299e8136876b4e11b3
ARG QUARTO_URL=https://github.com/quarto-dev/quarto-cli/releases/download/v${QUARTO_VERSION}/quarto-${QUARTO_VERSION}-linux-amd64.tar.gz

ENV SASSTUDIO_TEMP_HOME=/etc/sasstudio

RUN wget -q ${QUARTO_URL} -O /tmp/quarto-${QUARTO_VERSION}-linux-amd64.tar.gz && \
echo "${QUARTO_SHA} /tmp/quarto-${QUARTO_VERSION}-linux-amd64.tar.gz" | sha256sum -c - && \
tar -xzvf /tmp/quarto-${QUARTO_VERSION}-linux-amd64.tar.gz -C /tmp/ && \
Expand All @@ -28,6 +30,9 @@ RUN ln -s /usr/local/SASHome/SASFoundation/9.4/bin/sas_en /usr/local/bin/sas &&

WORKDIR /home/jovyan

# Adds default workspace shortcut to sasstudio
COPY SWE.folderShortcuts.key $SASSTUDIO_TEMP_HOME/preferences/SWE.folderShortcuts.key

ENV PATH=$PATH:/usr/local/SASHome/SASFoundation/9.4/bin

ENV PATH=$PATH:/usr/local/SASHome/SASPrivateJavaRuntimeEnvironment/9.4/jre/bin
Expand Down
9 changes: 9 additions & 0 deletions output/docker-stacks-datascience-notebook/start-custom.sh
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,15 @@ if [ ! -d "$HOME/workspace" ]; then
mkdir -p "$HOME/workspace/repositories"
fi

# Add sasstudio default
if [[ -z "${SASSTUDIO_TEMP_HOME}" ]]; then
echo "No sas studio default settings created"
else
echo "Creating sas studio default settings"
mkdir -p "$HOME/.sasstudio"
cp -r "$SASSTUDIO_TEMP_HOME/." "$HOME/.sasstudio"
fi

# Retrieve service account details
serviceaccountname=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Username}} | base64 --decode`
serviceaccounttoken=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Token}} | base64 --decode`
Expand Down
9 changes: 9 additions & 0 deletions output/jupyterlab-cpu/start-custom.sh
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,15 @@ if [ ! -d "$HOME/workspace" ]; then
mkdir -p "$HOME/workspace/repositories"
fi

# Add sasstudio default
if [[ -z "${SASSTUDIO_TEMP_HOME}" ]]; then
echo "No sas studio default settings created"
else
echo "Creating sas studio default settings"
mkdir -p "$HOME/.sasstudio"
cp -r "$SASSTUDIO_TEMP_HOME/." "$HOME/.sasstudio"
fi

# Retrieve service account details
serviceaccountname=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Username}} | base64 --decode`
serviceaccounttoken=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Token}} | base64 --decode`
Expand Down
9 changes: 9 additions & 0 deletions output/jupyterlab-pytorch/start-custom.sh
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,15 @@ if [ ! -d "$HOME/workspace" ]; then
mkdir -p "$HOME/workspace/repositories"
fi

# Add sasstudio default
if [[ -z "${SASSTUDIO_TEMP_HOME}" ]]; then
echo "No sas studio default settings created"
else
echo "Creating sas studio default settings"
mkdir -p "$HOME/.sasstudio"
cp -r "$SASSTUDIO_TEMP_HOME/." "$HOME/.sasstudio"
fi

# Retrieve service account details
serviceaccountname=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Username}} | base64 --decode`
serviceaccounttoken=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Token}} | base64 --decode`
Expand Down
9 changes: 9 additions & 0 deletions output/jupyterlab-tensorflow/start-custom.sh
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,15 @@ if [ ! -d "$HOME/workspace" ]; then
mkdir -p "$HOME/workspace/repositories"
fi

# Add sasstudio default
if [[ -z "${SASSTUDIO_TEMP_HOME}" ]]; then
echo "No sas studio default settings created"
else
echo "Creating sas studio default settings"
mkdir -p "$HOME/.sasstudio"
cp -r "$SASSTUDIO_TEMP_HOME/." "$HOME/.sasstudio"
fi

# Retrieve service account details
serviceaccountname=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Username}} | base64 --decode`
serviceaccounttoken=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Token}} | base64 --decode`
Expand Down
9 changes: 9 additions & 0 deletions output/remote-desktop/start-custom.sh
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,15 @@ if [ ! -d "$HOME/workspace" ]; then
mkdir -p "$HOME/workspace/repositories"
fi

# Add sasstudio default
if [[ -z "${SASSTUDIO_TEMP_HOME}" ]]; then
echo "No sas studio default settings created"
else
echo "Creating sas studio default settings"
mkdir -p "$HOME/.sasstudio"
cp -r "$SASSTUDIO_TEMP_HOME/." "$HOME/.sasstudio"
fi

# Retrieve service account details
serviceaccountname=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Username}} | base64 --decode`
serviceaccounttoken=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Token}} | base64 --decode`
Expand Down
9 changes: 9 additions & 0 deletions output/rstudio/start-custom.sh
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,15 @@ if [ ! -d "$HOME/workspace" ]; then
mkdir -p "$HOME/workspace/repositories"
fi

# Add sasstudio default
if [[ -z "${SASSTUDIO_TEMP_HOME}" ]]; then
echo "No sas studio default settings created"
else
echo "Creating sas studio default settings"
mkdir -p "$HOME/.sasstudio"
cp -r "$SASSTUDIO_TEMP_HOME/." "$HOME/.sasstudio"
fi

# Retrieve service account details
serviceaccountname=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Username}} | base64 --decode`
serviceaccounttoken=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Token}} | base64 --decode`
Expand Down
5 changes: 5 additions & 0 deletions output/sas/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -391,6 +391,8 @@ ARG QUARTO_VERSION=1.4.176
ARG QUARTO_SHA=c06edd8930903a1018a27eb9f70fb9037b28a3cd8a7eb6299e8136876b4e11b3
ARG QUARTO_URL=https://github.com/quarto-dev/quarto-cli/releases/download/v${QUARTO_VERSION}/quarto-${QUARTO_VERSION}-linux-amd64.tar.gz

ENV SASSTUDIO_TEMP_HOME=/etc/sasstudio

RUN wget -q ${QUARTO_URL} -O /tmp/quarto-${QUARTO_VERSION}-linux-amd64.tar.gz && \
echo "${QUARTO_SHA} /tmp/quarto-${QUARTO_VERSION}-linux-amd64.tar.gz" | sha256sum -c - && \
tar -xzvf /tmp/quarto-${QUARTO_VERSION}-linux-amd64.tar.gz -C /tmp/ && \
Expand All @@ -414,6 +416,9 @@ RUN ln -s /usr/local/SASHome/SASFoundation/9.4/bin/sas_en /usr/local/bin/sas &&

WORKDIR /home/jovyan

# Adds default workspace shortcut to sasstudio
COPY SWE.folderShortcuts.key $SASSTUDIO_TEMP_HOME/preferences/SWE.folderShortcuts.key

ENV PATH=$PATH:/usr/local/SASHome/SASFoundation/9.4/bin

ENV PATH=$PATH:/usr/local/SASHome/SASPrivateJavaRuntimeEnvironment/9.4/jre/bin
Expand Down
1 change: 1 addition & 0 deletions output/sas/SWE.folderShortcuts.key
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
["Workspace~ps~/home/jovyan/workspace"]
9 changes: 9 additions & 0 deletions output/sas/start-custom.sh
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,15 @@ if [ ! -d "$HOME/workspace" ]; then
mkdir -p "$HOME/workspace/repositories"
fi

# Add sasstudio default
if [[ -z "${SASSTUDIO_TEMP_HOME}" ]]; then
echo "No sas studio default settings created"
else
echo "Creating sas studio default settings"
mkdir -p "$HOME/.sasstudio"
cp -r "$SASSTUDIO_TEMP_HOME/." "$HOME/.sasstudio"
fi

# Retrieve service account details
serviceaccountname=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Username}} | base64 --decode`
serviceaccounttoken=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Token}} | base64 --decode`
Expand Down
9 changes: 9 additions & 0 deletions resources/common/start-custom.sh
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,15 @@ if [ ! -d "$HOME/workspace" ]; then
mkdir -p "$HOME/workspace/repositories"
fi

# Add sasstudio default
if [[ -z "${SASSTUDIO_TEMP_HOME}" ]]; then
echo "No sas studio default settings created"
else
echo "Creating sas studio default settings"
mkdir -p "$HOME/.sasstudio"
cp -r "$SASSTUDIO_TEMP_HOME/." "$HOME/.sasstudio"
fi

# Retrieve service account details
serviceaccountname=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Username}} | base64 --decode`
serviceaccounttoken=`kubectl get secret artifactory-creds -n $NB_NAMESPACE --template={{.data.Token}} | base64 --decode`
Expand Down
1 change: 1 addition & 0 deletions resources/sas/SWE.folderShortcuts.key
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
["Workspace~ps~/home/jovyan/workspace"]
Loading