-
Notifications
You must be signed in to change notification settings - Fork 123
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
AsciiNema improvements #2742
Comments
I can rerecord everything as it is now to show the error message since it minorly belongs under "my domain" but I do not want to completely instruct a whole yaml, python, specmount example as this is a lot of work to sensefully show a user what elektra can do. We agreed that only error message related issues belong to me... |
I agree that python is not something you worked with. YAML is just an example, not really important. The other things are perfectly in scope. |
Ok, but what about "should work as-is also in docker" |
That the tutorial is done inside of docker. So you start the tutorial by pulling a docker image (maybe you can push an alpine Docker image to docker.com which has Elektra 0.9.1 installed so that you do not need to install during the tutorial). |
Why would I need to do that in a docker container? I have asciinema local on my system and record it there. All that asciinema emits is a .json file |
As first command during the tutorial you pull and enter the docker container. This has the advantage that what is recorded also works for people who want to try out themselves without the need to go through installation. |
Don't we have a docker registry already were jenkins pulls all the containers? If I would push such a docker image to dockerhub then I probably need your account for that so the docker image stays online for the lifetime of elektra. |
This should be no problem but can you create a Docker image? @mpranj did you plan to do such an image for releases? |
No immediate plans, but sounds like nice to have. I like the idea very much that we publish such an image officially with each release. Elektra is quite a pain to compile and set up for novices. |
Ok, can you create an alpine docker image and upload it to a (newly created public?) repo? It would make most sense that you as build master do that :) |
I can create it but probably not today. |
Ok, so I created it today.
|
Amazing job! Do not forget to advertise it in the next release notes. We should also add this information to the important places for newcomers (@d3nwp). |
@mpranj Which plugins did you include in the image? json for example does not exist. If I should include yaml you probably should install one of that. Btw is sudo not installed in the image but required to mount (actually very weird). Furthermore: this image is whopping 700 mb big, did you take an alpine version? |
The image is constructed in a way that you do not need sudo. So simply type as first command (after docker run):
Then "sudo" will not happen in the image but if users try it out on their machine, they will have all the commands that need sudo with sudo. |
@Piankero you can inspect the image in #3300 and add suggestions.
I think actually the image is not constructed such that sudo is not needed, I need to improve that. Or did you try it out? |
|
@Piankero yes, it is configured incorrectly. Sorry, I'll try to fix it soon! |
I tried to simply configure elektra to not write anything outside the user directory, but the tutorial includes things like editing the hosts file as root. Maybe it makes sense that the image is run as root so these things can be done easily? EDIT: ping also does not work in alpine / busybox without root. EDIT: another thing that is not available in alpine to my knowledge is xerces, so there is no xmltool :( EDIT: elektrify-getenv does not work because alpine does not use glibc. |
I pushed Since not everything from the AsciiNema tutorial will work on alpine, I'm open for other suggestions. |
Yes.
Maybe sudo is better, as all our tutorials use sudo. e.g. scripts/docker/cirrus/arch/Dockerfile has sudo
Not a big deal to not have it (as we also do not have getenv)
Not a big deal: then we do not show the xerces plugin. xmltool is deprecated anyway.
This part we can remove. |
Thank you! I will add sudo then! |
I pushed |
@markus2330 Before I record the new tutorial I want you to approve the whole playbook. Here is the new version: docker run -it elektra/elektra > NEW LINE
sudo kdb mount hello.js /hello json
kdb set user/hello/hello/world "Hello World"
kdb get user/hello/hello/world
kdb file user/hello/hello/world
vi /home/elektra/.config/hello.js
# Edit file to say "Hello World from File!"
kdb get user/hello/hello/world
kdb editor user/hello ini
# Edit file to say "Hello World from INI!"
kdb get user/hello/hello/world
kdb export user/hello
kdb export user/hello tcl
kdb export user/hello yaml > NEW LINE
kdb rm user/hello/hello/world
cat /home/markus/.config/hello.ini
sudo kdb umount /hello
echo "Now let us change something.. With validation"
vi specification.ini > NEW START
# content:
# []
# mountpoint = specification.ini
# [hostip]
# check/ipaddr =
# [timeout]
# check/range = 0-100
sudo kdb mount /home/elektra/specification.ini spec/validation ni
sudo kdb spec-mount /validation
kdb set /validation/hostip 123.123.123.1233
kdb set /validation/timeout 500
kdb editor spec/validation ni
#edit range to 1000
kdb set /validation/timeout 500
sudo kdb umount spec/validation
kdb rm -r /validation > NEW END
echo "What to do next???"
kdb
kdb --help
kdb --find-tools |
Wow, you even scripted it 👍 . I am already looking forward to the result. Can you put the script into a PR so that we can discuss line-by-line? At first glance I notice:
Btw. I just read that https://github.com/dhobsd/castty supports audio 😉 |
|
I mark this issue stale as it did not have any activity for one year. I'll close it in two weeks if no further activity occurs. If you want it to be alive again, ping the issue by writing a message here or create a new issue with the remainder of this issue. |
I mark this stale as it did not have any activity for one year. I'll close it in two weeks if no further activity occurs. If you want it to be alive again, ping by writing a message here or create a new issue with the remainder of this issue. |
I closed this now because it has been inactive for more than one year. If I closed it by mistake, please do not hesitate to reopen it or create a new issue with the remainder of this issue. |
The text was updated successfully, but these errors were encountered: