-
Notifications
You must be signed in to change notification settings - Fork 190
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
Use app password, change setup method #1957
Conversation
Hmm annoying locally it is running fine. As the sleep also helped in the beginning maybe the machine is too slow. |
Could you try and use the occ command instead? Edit: nextcloud/server#24317 |
Yea I will take a look at it, it seems that this api is not a 100% stable at least on my dev setup. I ran it a few times and also added more sleep commands hoping that it would help. In manually running these actions I don't have that issue but I'm also slower than the bats script of course ... |
The app password is nice in local testing, since Nextcloud logs too much data if you use the user password. Setup_file and teardown_file are only executed once instead of running before and after every job. Use bats from npm as ubuntu's version is old. Switch to occ for app password Signed-off-by: Benjamin Brahmer <info@b-brahmer.de>
Seems to work reliable now :) The occ command is apparently more stable for this situation. I left the cleanup command via the api as it seems like occ can't do that. And if it works it is nicer for a local setup not to have thousands of tokens. For actions it doesn't matter of course since it always has a fresh db. |
@@ -59,7 +59,7 @@ jobs: | |||
coverage: none | |||
|
|||
- name: Setup BATS & httpie | |||
run: sudo apt-get install -y bats httpie | |||
run: sudo apt-get install -y httpie && npm install -g bats@1.7.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wait, why use npm for this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because the Ubuntu package has like 1.1 in their repo slightly newer on new versions.
There is also no backports. For the basic stuff it will work but of course there are details that are different.
I can't work with that though latest is 1.8 but I didn't test that yet on my machine since it didn't land in manjaro as of now.
npm is one of the projects official distribution ways (not sure why), I checked the repo for alternative install methods after I noticed that Ubuntu is hanging behind.
And since npm is available in the action image I think this is the best way.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will probably in the future also add a requires bats version X line to the bats files.
I have no time to debug issues because of bugs that were already fixed by the project.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's start like this then
The app password is nice in local testing, since Nextcloud logs too much data if you use the user password. Setup_file and teardown_file are only executed once instead of running before and after every job.