Error when cloning ERPNext GIT

Then the ERPNext app is already installed, at least partially. I’m finding instructions to repair.

@Clive_Conlon This may work, run this then try to install again:

bench --site [sitename] uninstall-app erpnext

Does that mean that the shell automatically installs ERPNext? I have not created a site yet though, ERPNext is in the *\frappe-bench folder… so if I use that command I do not have a site name.

Not sure. Hopefully someone more knowledgeable than me can help. I’m pretty sure just deleting that folder isn’t the right course of action though. Maybe move the folder out of frappe-bench and try again and see what happens though.

I will re-image quickly and see what happens, if it does the same I will just rename the erpnext folder, will update on what happens with it, thanks for trying to assist though.

You should try the command that @cpurbaugh suggested. To find out your site name, you can go to frappe-bench/sites and see what folders are there. There should be “assets” and any sites. It might typically be site1, but it is erpnext.vm on the virtual machine.

Alternatively, I think that bench --site all uninstall-app erpnext or bench uninstall-app erpnext will work, but not 100% sure.

@Clive_Conlon The production setup comes with erpnext, so the app is already there. Which script did you use to install?

You might also have a folder called site1.local in your sites folder.

You were missing an l:

bench --site all uninstall-app erpnext

bench uninstall-app erpnext

1 Like

I used https://raw.githubusercontent.com/frappe/bench/master/install_scripts/setup_frappe.sh
I also see that it has site1.local, do I have to delete that and create a new site from there?
after I created my site do I then install ERPNext to that site as well? or will it automatically install when creating the site?

Yea, so that script installs a site by default, and erpnext along with that. You already have a working site. You don’t need to download erpnext or create a new site. I’ll add this to the readme of the bench repo so it’s clear, sorry about that :sweat_smile:

No problem, thanx for the help, will the site be publicly available as well? When I try to access it publicly it still gives me the nginx default page, so do I edit the index page to reroute somewhere else or delete the nginx index page?

Have you setup production? (run the script with --setup-production), if so, yes. It should be accessible via your IP. If you plan to access it via a domain you’ll have to create a new site with the domain you plan to use (and install erpnext on it using bench --site [site-name] install-app erpnext), and run the below commands. If it’s not working via IP, run the below commands.

bench config dns_multitenant on
bench setup nginx
bench restart
sudo service nginx restart

At the moment I only have it as a lab running on a VPS so no domain assigned, but it has a public IP so i will access it like that for now and when we go live I will do it on a subdomain erpnext.mydomain.co.za or something of the sort, will those steps work for that as well?>

Yes, they will. Just make sure you create a site with that name. You don’t need to run the first command twice though.

Alright I think the ERPNext installed OK now in my new site, I just made it the IP address for now, but it still shows the Nginx welcome page, do I have to edit the conf file to redirect to the index page of ERPNext? and if so, what is the location?

You should just run these commands

Ok great thank you, I did run them, but I forgot that it was before I created the new site…
It is running but the login screen does not seem to display properly and I am trying to login using administrator and the password I set up when creating the site, but it is not allowing me through…

sorry for all the questions, I am starting to feel very dumb :sweat_smile:

I think your old site, site1.local is still there. Which is why you can’t access with your password as it seems to be using that old site. You can use bench drop-site site1.local to remove that site, then you can run bench use [site-name] to make your new site the default. The problem with this is that later if you add another site it will cause issues. But if you’re accessing via IP you’ll need to set your new site as the default site.

Once you’re all set with a domain, then remove a file called “currentsite.txt” in the sites folder, and that will remove the default site.

Regarding your site looking like that
Run

bench --site [site-name] build
bench --site [site-name] clear-cache

then clear-cache for your browser whilst refreshing, you should be able to see everything properly.

The site definitely points to my site, site1.local does not exist anymore, but still does not want to grant me access and the site still looks the same :cry:
Would you mind if I can PM you with the VNC link and you can have a look at it for me and see what I did wrong?

so this is what I did and now the site looks right and the login works:

chmod o+x /home/frappe chmod o+r /home/frappe

thanks to @Tanuj on this thread Installation fails due to mysql pass - #19 by Tanuj

so relieved :sweat_smile: thanx for your help @vjFaLk :grin:

2 Likes

@Clive_Conlon Glad to know it’s working properly, I wonder how the permissions for the frappe home folder went awry…