Skip to content
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

Not seems to work at all #153

Closed
lablnet opened this issue Aug 24, 2020 · 23 comments · May be fixed by #157
Closed

Not seems to work at all #153

lablnet opened this issue Aug 24, 2020 · 23 comments · May be fixed by #157

Comments

@lablnet
Copy link

lablnet commented Aug 24, 2020

image

@steevanb
Copy link
Member

Hi,

Could you please show me the full code?
assets:install is not called by benchmark kit.

@lablnet
Copy link
Author

lablnet commented Aug 24, 2020

Hi,

Could you please show me the full code?
assets:install is not called by benchmark kit.

would you like see code i am benchmarking?
i am benchmarking this https://github.com/Zestframework/Zest

@steevanb
Copy link
Member

Ok thanks, but could you give me code you are benchmarking?
This is the code of your framework, but maybe you made some modifications / installations before using the benchmark kit?

@lablnet
Copy link
Author

lablnet commented Aug 24, 2020

Ok thanks, but could you give me code you are benchmarking?
This is the code of your framework, but maybe you made some modifications / installations before using the benchmark kit?

this is same code i push yet
https://github.com/zestframework/Zest-Benchmark

@lablnet
Copy link
Author

lablnet commented Aug 24, 2020

i install kit as mentioned and i have to change url in wget because from the readme the url was not work

then i run command phpbenchkit it ask me directory name i put Zest which was inside /var/www/html/Zest/ and i run script from /html

then it show me to run phpbenchkit configure:all

when i run this it show me above mentioned error

Thanks

@steevanb
Copy link
Member

Thanks i will take a look as soon as possible.

@lablnet
Copy link
Author

lablnet commented Aug 27, 2020

Thanks i will take a look as soon as possible.

Any update, if possible?

@steevanb
Copy link
Member

I will have time for it during this week-end or next week, i will tell you here when i've fixed it.

@steevanb
Copy link
Member

steevanb commented Aug 31, 2020

I've found the problem: it's not the code, it's the documentation.

Commands has been renamed but i didn't change the documentation: configure:all has been renamed to configure:benchmark.

Problem is solved, you can call phpbenchkit --selfupdate to get the documentation fix and call phpbenchkit configure:benchmark.

@lablnet
Copy link
Author

lablnet commented Aug 31, 2020

I've found the problem: it's not the code, it's the documentation.

Commands has been renamed but i didn't change the documentation: configure:all has been renamed to configure:benchmark.

Problem is solved, you can call phpbenchkit --selfupdate to get the documentation fix and call phpbenchkit configure:benchmark.

Give me time to check pls 😊 I will be back with status yet it's late night here

Thanks for your time to look to issue

@lablnet
Copy link
Author

lablnet commented Sep 1, 2020

I've found the problem: it's not the code, it's the documentation.

Commands has been renamed but i didn't change the documentation: configure:all has been renamed to configure:benchmark.

Problem is solved, you can call phpbenchkit --selfupdate to get the documentation fix and call phpbenchkit configure:benchmark.

Nah Boss its not working
image

Even i try to run with sudo prefix as well.
I changed the permission of whole directory as well

image

Looking forward to hear from you thanks

@steevanb
Copy link
Member

steevanb commented Sep 1, 2020

It seems ok on my side:
Zest benchmark

@steevanb
Copy link
Member

steevanb commented Sep 1, 2020

Could you tell me your UID with echo $UID?
Do it on your host, not inside the Docker container.

@steevanb
Copy link
Member

steevanb commented Sep 1, 2020

I've added Zest Framework to benchmark kit.
You can call phpbenchkit --selfupdate, then answer framework to Composent type? question, and you will see Zest Framework in the list for next question.

@lablnet
Copy link
Author

lablnet commented Sep 2, 2020

Could you tell me your UID with echo $UID?
Do it on your host, not inside the Docker container.

image

@lablnet
Copy link
Author

lablnet commented Sep 2, 2020

I've added Zest Framework to benchmark kit.
You can call phpbenchkit --selfupdate, then answer framework to Composent type? question, and you will see Zest Framework in the list for next question.

Yes i see but when i follow steps it showing same result, even i run that command with sudo prefix

image

@peter279k
Copy link

The issue is about permission denied.

That is, the /var/www/benchmark owner is not same as your current user.

The /var/www/benchmark owner should be www-data user and it's not lablnet.

To resolve above issue, I think it can add sudo before the phpbenchkit configure:benchmark.

@lablnet
Copy link
Author

lablnet commented Sep 2, 2020

The issue is about permission denied.

That is, the /var/www/benchmark owner is not same as your current user.

The /var/www/benchmark owner should be www-data user and it's not lablnet.

To resolve above issue, I think it can add sudo before the phpbenchkit configure:benchmark.

I try with that too but still same issue

image

@peter279k
Copy link

The permission denied problem is inside Docker phpbenchmarks/benchmark-kit:4 container.

The phpbenchkit configure:benchmark command will create the directory and files on /var/www/benchmark/.phpbenchmarks folder.

圖片

And it seems that the phpbenchkit script will use the docker exec with phpbenchmarks user to create above directory.

It can look at this line to find out above command.

It will be permission denied because the /var/www/benchmark/ directory owner is the root, not phpbenchmarks.

To fix above issue temporarily, it should use docker exec container_id /bin/bash -c "chown -R phpbenchmarks:phpbenchmarks /var/www/benchmark/" before running phpbenchkit configure:benchmark command.

And it will be worked :).

圖片

@steevanb
Copy link
Member

steevanb commented Sep 2, 2020

Thanks @peter279k.

I thought you were on a subdirectory of /var/www, but peter is right if you are not (/var/www is the root of your installation, not /var/www/Zest_Framework for example).

You can change permissions of /var/www with it's command, or do it outside of the container.
But i think the best solution is to add a subdirectory into /var/www, and give permissions of your user only to this directory.

@lablnet
Copy link
Author

lablnet commented Sep 2, 2020

Its fixed thanks both @peter279k and @steevanb

But the document should be improved for new person in docker and Linux environment thanks.

@lablnet lablnet closed this as completed Sep 2, 2020
@peter279k
Copy link

Its fixed thanks both @peter279k and @steevanb

But the document should be improved for new person in docker and Linux environment thanks.

That's right. They should be improved :).

@steevanb
Copy link
Member

steevanb commented Sep 2, 2020

Yes, for now benchmark kit 4 is under developement. Documentation is not fully written ;)

peter279k added a commit to open-source-contributions/benchmark-kit that referenced this issue Sep 2, 2020
peter279k added a commit to open-source-contributions/benchmark-kit that referenced this issue Sep 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants