I don't need the shell name to be the username, I just want access to the
username (whatever was passed from the hub) so that I can customize the UI
logout button to say
"Logout <username>"
instead of just "logout" to meet a local requirement. I believe I can make
the UI change from the custom.css or custom.js but first I have to figure
out how to get the username that the hub has for a particular single user
instance
Ted
On Monday, August 8, 2016 at 2:06:50 AM UTC-7, Min RK wrote:
>
> The server has the user's name, but it's not the name of the user in the
> container. To do that, you would need to run
>
> usermod -l newname jovyan
>
> in the container *on startup*, which means that the container must
> initially start as root, and then switch to the user after modifying the
> system. This is what the SystemUserSpawner does, and one of the reasons I
> recommend against using the SystemUserSpawner if it can be avoided.
>
> Is it important to you for the shell username to be your user's name?
>
> -MinRK
>
>
> On Fri, Aug 5, 2016 at 6:48 PM, Ted Liefeld <[email protected]
> <javascript:>> wrote:
>
>> Any suggestion for how to get the username in the singleuser image
>> launched by dockerspawner? I don't seem to have the user there and (as
>> intended) its running as jovyan
>>
>> Ted
>>
>> On Friday, August 5, 2016 at 1:33:26 AM UTC-7, Min RK wrote:
>>>
>>>
>>>
>>> On Thu, Aug 4, 2016 at 9:17 PM, Ted Liefeld <[email protected]>
>>> wrote:
>>>
>>>> Answering myself again...
>>>>
>>>> in the hub you can add this to the logout button of the template
>>>>
>>>> {{user.orm_user.name}}
>>>>
>>>
>>> {{user.name}} works, too.
>>>
>>>
>>>>
>>>>
>>>> Still working on the docker image to see if it will work there too
>>>>
>>>>
>>>>
>>>>
>>>> On Thursday, August 4, 2016 at 11:08:39 AM UTC-7, Ted Liefeld wrote:
>>>>>
>>>>> On a related note,
>>>>>
>>>>> how can I access the current username so that I can change the logout
>>>>> button to be "Logout {username}" (a feature requested for my server by
>>>>> the
>>>>> management...
>>>>>
>>>>> Thanks
>>>>>
>>>>> On Thursday, August 4, 2016 at 4:04:48 AM UTC-7, Min RK wrote:
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Wed, Aug 3, 2016 at 8:02 PM, Ted Liefeld <
>>>>>> [email protected]> wrote:
>>>>>>
>>>>>>> Answering my own post (partially) for anyone who comes later
>>>>>>>
>>>>>>> The hub seems to use this version of the file
>>>>>>>
>>>>>>> /usr/local/share/jupyter/hub/static/css/style.min.css
>>>>>>>
>>>>>>
>>>>>> That's the default installation location, yes. For customization, one
>>>>>> option is to edit the LESS files in the JupyterHub repo prior to
>>>>>> installation, then run:
>>>>>>
>>>>>> python setup.py css
>>>>>>
>>>>>>
>>>>>>>
>>>>>>> on my AWS instance (deployed following these instructions
>>>>>>> https://github.com/jupyterhub/jupyterhub/wiki/Deploying-JupyterHub-on-AWS)
>>>>>>>
>>>>>>> but you do need to restart to have changes reflected. Also need to
>>>>>>> still
>>>>>>> figure out how to customize the docker-spawned single user notebooks
>>>>>>> that
>>>>>>> seem to be using a drive mounted from somewhere still TBD
>>>>>>>
>>>>>>
>>>>>> The default spawner doesn't mount any volumes, but you can ask it to
>>>>>> via configuration.
>>>>>>
>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Wednesday, August 3, 2016 at 10:25:35 AM UTC-7, Ted Liefeld wrote:
>>>>>>>>
>>>>>>>> I am installing a jupyterhub (using custom auth and dockerspawner)
>>>>>>>> for a project and we would like to customize the css for the hub and
>>>>>>>> the
>>>>>>>> notebooks. I can't seem to find any docs that indicate where I can
>>>>>>>> find
>>>>>>>> the css and there are ~30 different files matching style.min.css on my
>>>>>>>> installation. Can someone point me to a doc on customizing the
>>>>>>>> jupyterhub
>>>>>>>> appearance or suggest what the right path is for the css?
>>>>>>>>
>>>>>>>> Running jupyterhub 0.6.1 fwiw
>>>>>>>>
>>>>>>>> Thanks
>>>>>>>>
>>>>>>>> Ted
>>>>>>>>
>>>>>>> --
>>>>>>> You received this message because you are subscribed to the Google
>>>>>>> Groups "Project Jupyter" group.
>>>>>>> To unsubscribe from this group and stop receiving emails from it,
>>>>>>> send an email to [email protected].
>>>>>>> To post to this group, send email to [email protected].
>>>>>>> To view this discussion on the web visit
>>>>>>> https://groups.google.com/d/msgid/jupyter/3ce01808-6fe9-4902-8d26-39136107511f%40googlegroups.com
>>>>>>>
>>>>>>> <https://groups.google.com/d/msgid/jupyter/3ce01808-6fe9-4902-8d26-39136107511f%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>>>>> .
>>>>>>>
>>>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>>>
>>>>>>
>>>>>> --
>>>> You received this message because you are subscribed to the Google
>>>> Groups "Project Jupyter" group.
>>>> To unsubscribe from this group and stop receiving emails from it, send
>>>> an email to [email protected].
>>>> To post to this group, send email to [email protected].
>>>> To view this discussion on the web visit
>>>> https://groups.google.com/d/msgid/jupyter/6d3e71a0-919e-4151-bc2e-cb2ffa380aa6%40googlegroups.com
>>>>
>>>> <https://groups.google.com/d/msgid/jupyter/6d3e71a0-919e-4151-bc2e-cb2ffa380aa6%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>> .
>>>>
>>>> For more options, visit https://groups.google.com/d/optout.
>>>>
>>>
>>> --
>> You received this message because you are subscribed to the Google Groups
>> "Project Jupyter" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected] <javascript:>.
>> To post to this group, send email to [email protected]
>> <javascript:>.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/jupyter/32256b91-71c4-4103-a594-96fc76e75c19%40googlegroups.com
>>
>> <https://groups.google.com/d/msgid/jupyter/32256b91-71c4-4103-a594-96fc76e75c19%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
--
You received this message because you are subscribed to the Google Groups
"Project Jupyter" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jupyter/c5462ed2-b549-4800-ae0d-0b2ae0a16543%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.