Conjur Quick Start: load sample policy step

I am doing the Conjur Quick Start and I am on the 2nd part “Define Policy”. I ran the command given in the instructions on my terminal:
docker-compose exec client conjur policy load root policy/BotApp.yml > my_app_data
but terminal did not return “Loaded policy ‘root’” and no API keys got saved in my_app_data. Did anyone else run into this issue as well?

Hey Natalia,

could you please share a screenshot and what is in my_app_data? Any error messages before this?


Hi John,

This is a screenshot of the contents of my_data_app.
There were no error messages before either and I was able to successfully login to conjur as admin.

do you have a screenshot of the terminal?

Hi. I am running into a similar issue at this same step… (im new to conjur) however i have tried to follow the tutorial to the exact letter several times starting a new server from scratch. Each time at this step i try my terminal does not return “loaded policy root” the file is created but i cant do any thing with the my_app_data as i get the following error: Permission denied @ rb_sysopen - policy/BotApp.yml. Any help would be appreciated.

@NataliaKhan, it looks like you’ve run this policy load previously. The API key is only returned when you first create the host, but that was overwritten since we’re using > to redirect the output instead of >>. You’ll want to run something like docker-compose exec client conjur host rotate_api_key -h BotApp >> botapp_key`. This should write a new api key for the BotApp host into that file.

@linzwelch, I believe you might be in the wrong directory and/or the BotApp.yml policy file is missing.

@linzwelch welcome to Conjur, sorry to hear about your issue. This tutorial won’t run well if you do it multiple times in the same place because it is an initial setup, as it sounds like you learned :slight_smile:

Part of this is same issue Natalia had, with the > all of the output from that command is being directed to the file, so you are not seeing the message the tutorial says, we will update to clarify after a review.

If you look in that file, it will show the number of times the policy was loaded, I assume you will see it was loaded multiple times and you missed the key that was returned the first time as the file was overwritten, you are not alone :slight_smile:

Can you try it again from a different sever / fresh start and also as Nate said make sure you are in the right directory.

Can you try this hosted tutorial with Ansible? I would love to get your feedback and to see if this format works any better for you or suggestions for improvements:

You can message me directly with feedback or if you have an issue with this tutorial or others post something in the forum under a new topic.

Thank you,
John

Thank you for this information. I am running the commands under the /home/user/conjur-quickstart/ directory. The the BotApp.yml file is under /home/user/conjur-quickstart/conf/policy/BotApp.yml . I do not have access to my lab at the moment to rebuild as its down for maintenance but will try a fresh machine once i am back in. Also i would be more than happy to check out the tutorial and give feedback. Thank you for the quick responses as i am very excited to get into the community and become experts like your selves.

1 Like

great, and please include a screenshot of the terminal if you run into issues still.

Thanks,
John

I passed this step two ways separately. Worked!
The first way, uninstall and reinstall all components. :slight_smile:
The second way, back to U1.S5 and create a new admin.

@John,

There is no output.
image|690x73

That was a good practice for me, thanks for your labors!

1 Like

@Siyar thank you for verifying, this is really helpful!