Hi
I am new to DHIS2 and I want to set up development environment to develop the custom application for DHIS2. Please guide on this issue.
Thank You!
Hi
I am new to DHIS2 and I want to set up development environment to develop the custom application for DHIS2. Please guide on this issue.
Thank You!
Hi Sami,
Great question!
We’ve got this outlined for you at the Developer Portal! From there you can follow the flow where you want to go. Web app / Android App.
There’s also instructions how to run a backend yourself!
Hope this helps! Let me know if you have any other questions
should I follow this link and configure it using docker?
Yes it’s beneficial of running your own server locally using Docker for development purposes!
Hi
I installed docker and after that I run the command “yarn global add @dhis2/cli” . it was successfully executed but when I run “d2 cluster --help” it say ‘d2’ is not recognized as an internal or external command,
Hi,
This seems to indicate it didn’t install correctly somehow. If you run yarn global list
does it display?
Hi,
I install it using npm and now it is working fine.
Thank you!
Hi,
Now I am running
‘‘d2 cluster up 2.39.1.1 --db-version 2.39 --seed’’ command and I am getting this error
@sami12111 we do not support PowerShell or the native Windows terminal for d2 cluster
. You will need to run the d2 cluster
under Windows Subsystem for Linux
Yes I install it on docker and I am running it under Window Subsystem for Linux.
By the way the issue is resolved using --update flag.
Thank You
But now stuck with another issue.
I created a simple app using
Creating a DHIS2 Web app | DHIS2 Developer Portal documentation.
But I am unable to upload it to app hub. Please guide me on this issue.
Screenshot of error is attached below.
Thank You!
Hi @sami12111 . If it’s still not working for you to upload the app, you might want to open the network tab and look for the POST to api/apps. There is probably some additional detail in the response there.
Hi @sami12111 ,
It looks like you’re now getting a different error (500) whereas you were previously getting a 409 error. You might now want to check that your localhost is running properly.
If the server is running properly, and you can reproduce the 409 error again, I’d recommend looking in the network tab rather than the console.
For example, in the example below, I can see that my app is missing a required file (and therefore will not upload):
Yes the manifest file issue is resolved, now facing that error (500) as you can see the screenshot.
In the network tab I am getting the same error
Thanks @sami12111. I’m using a Mac (OS Monterey). I don’t have experience with setup on Windows, but that looks like it could be an issue with your server not having permission to write to that directory (DHIS2/files/apps), so the app cannot be saved.
Hi @sami12111: I’m not familiar with Windows, but this article might be of use: How to change folder permissions on Windows - V2 Cloud
Let us know how it goes, and if that doesn’t help, maybe someone with more set up experience in Windows can weigh in with some advice