mirror of
https://github.com/iiab/iiab.git
synced 2025-02-13 03:32:12 +00:00
19 lines
791 B
Bash
Executable file
19 lines
791 B
Bash
Executable file
#!/bin/bash -x
|
|
# add await to asyncio change password function
|
|
|
|
SITE_PACKAGES=$({{ jupyterhub_venv }}/bin/getsite.py)
|
|
cat $SITE_PACKAGES/firstuseauthenticator/firstuseauthenticator.py |grep 'await self.render'
|
|
if [ $? -ne 0 ];then
|
|
echo Updating to \"await self.render\"
|
|
sed -i -e's/self.render/await self.render/' $SITE_PACKAGES/firstuseauthenticator/firstuseauthenticator.py
|
|
else
|
|
echo Await patch already applied. Skipping. . .
|
|
fi
|
|
cat $SITE_PACKAGES/firstuseauthenticator/firstuseauthenticator.py |grep data['data'].lower()'
|
|
if [ $? -ne 0 ];then
|
|
echo Updating to data['username'].lower()
|
|
sed -i -e's/data['username']/data['username'].lower()/' $SITE_PACKAGES/firstuseauthenticator/firstuseauthenticator.py
|
|
else
|
|
echo username.lower() patch already applied. Skipping. . .
|
|
fi
|
|
|