-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathsetup.sh
executable file
·19 lines (14 loc) · 939 Bytes
/
setup.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#!/bin/bash
PROJECT=aspera
oc project $PROJECT
oc create -f aspera.yaml
oc adm policy add-scc-to-group anyuid system:serviceaccounts:$PROJECT
oc adm policy add-scc-to-group ibm-anyuid-scc system:serviceaccounts:$PROJECT
# THIS WILL VARY PER ENVIRONMENT
oc label node 10.95.219.177 node-role.kubernetes.io/ascp=true
oc label node 10.95.219.177 node-role.kubernetes.io/noded=true
kubectl create secret generic aspera-server --from-file=ASPERA_LICENSE="./aspera-license" --from-literal=TOKEN_ENCRYPTION_KEY="$(LC_CTYPE=C tr -dc A-Za-z0-9_\!\@\#\$\%\^\&\*\(\)-+= < /dev/urandom | tr -dc A-Za-z0-9 | head -c 40 )"
kubectl create secret generic asperanode-nodeadmin --from-literal=NODE_USER="myuser" --from-literal=NODE_PASS="mypassword"
kubectl create secret generic asperanode-accesskey --from-literal=ACCESS_KEY_ID="my_access_key" --from-literal=ACCESS_KEY_SECRET="my_access_key_secret"
echo "Setup of Aspera is now complete"
echo