05-28-2020 01:21 PM
Hi
I want to start developing custom modules in Alfresco. For this I have installed the following.
* Eclipse IDE for Java Developers version 2020-03 (4.15.0).
* Java (javac 14.0.1).
* Maven (Apache Maven 3.6.3.).
* JDK 14.0.1.
* Windows 10 64BIT
I followed these steps
https://docs.alfresco.com/sdk2.1/concepts/alfresco-sdk-installing-prerequisite-software.html
https://docs.alfresco.com/5.2/tasks/sdk-develop-eclipse.html
I want to do the following.
My question is. How do I start doing this from everything I have.
How do I access from the browser?
How can I start developing what I want?
Thank you
05-28-2020 01:44 PM
@viperboys which version of ACS you are using? 5.2.x or 6.x ?
For 6.x version see the steps here:
Planning to start with 6.x, see this post: https://hub.alfresco.com/t5/alfresco-content-services-forum/get-started-with-alfresco-6-and-alfresco...
Debug in eclipse: https://github.com/Alfresco/alfresco-sdk/blob/master/docs/advanced-topics/debugging/debug-eclipse.md
If using 5.2.x, see the instructions to get basic project:
Generate the new project by following these steps:
1- Open commond prompt and execute following maven command:
For windows cmd: mvn archetype:generate -Dfilter=org.alfresco: For windows powershell: mvn archetype:generate -Dfilter="org.alfresco:" For mac/linux terminals, either can be used.
2- You will be asked to choose the archetype. SELECT '2'
Choose archetype: 1: remote -> org.alfresco.maven.archetype:activiti-jar-archetype (DEPRECATED - UNSUPPORTED - EXPERIMENTAL) 2: remote -> org.alfresco.maven.archetype:alfresco-allinone-archetype (Sample multi-module project for All-in-One development on the Alfresco platform. Includes modules for Platform/Repository JAR and Share JAR) 3: remote -> org.alfresco.maven.archetype:alfresco-amp-archetype (Sample project with full support for lifecycle and rapid development of Repository AMPs (Alfresco Module Packages)) 4: remote -> org.alfresco.maven.archetype:alfresco-platform-jar-archetype (Sample project with full support for lifecycle and rapid development of Platform/Repository JARs and AMPs (Alfresco Module Packages)) 5: remote -> org.alfresco.maven.archetype:alfresco-share-jar-archetype (Share project with full support for lifecycle and rapid development of JARs and AMPs (Alfresco Module Packages)) 6: remote -> org.alfresco.maven.archetype:share-amp-archetype (Share project with full support for lifecycle and rapid development of AMPs (Alfresco Module Packages))
3- Select '11' for the SDK version as 3.1.0
Choose org.alfresco.maven.archetype:alfresco-allinone-archetype version: 1: 2.0.0-beta-1 2: 2.0.0-beta-2 3: 2.0.0-beta-3 4: 2.0.0-beta-4 5: 2.0.0 6: 2.1.0 7: 2.1.1 8: 2.2.0 9: 3.0.0 10: 3.0.1 11: 3.1.0 12: 4.0.0-beta-1 13: 4.0.0 14: 4.1.0 Choose a number: 14:11
4- Provide 'groupId'
Define value for property 'groupId':
e.g. com.demo.aio.sdk3
5- Provide the 'artifactId' (name of your project)
Define value for property 'artifactId':
e.g.: sdk3-aio-project
6- Provide package:
Define value for property 'package' com.demo.aio.sdk3: :
Keep as is. Press enter.
7- You will be asked to confirm the properties:
Confirm properties configuration: groupId: com.demo.aio.sdk3 artifactId: sdk3-aio-project version: 1.0-SNAPSHOT package: com.demo.aio.sdk3 Y: :
Press 'Y', if everything looks good. A sample project will be generated.
8- Import them in eclipse and get started.
Note: JDK 1.8 is recommended for SDK3.1.0
To debug in eclipse (SDK3.1.0): http://javaworld-abhinav.blogspot.com/2015/07/debugging-alfresco-and-share-in-eclipse.html
06-04-2020 06:06 AM
@carloshc95 looking at your error it seems you are using windows and i assume you have already installed Docker Desktop for windows (https://docs.docker.com/docker-for-windows/release-notes/)
Latest version can be downloaded from here just in case: https://download.docker.com/win/stable/Docker%20Desktop%20Installer.exe
Open poweshell and check following:
docker --version docker-compose -version
Both should return version successfuly, which idicates installation was proper.
Have you created user account on docker hub?
You must create a user account on docker hub and when you start Docker Desktop, you must login using the credentials you created. It will allow downloading alfresco/share and other images from docker hub (for community versions).
Go to: https://hub.docker.com/signup?next=%2F%3Foverlay%3Donboarding to create an account.
To login, use powersehll or docker desktop signin option after user account creation. Posweshell login command shown below.
PS: docker login Authenticating with existing credentials... Stored credentials invalid or expired Username (xyz@gmail.com): xyz Password: Login Succeeded
https://docs.docker.com/engine/reference/commandline/login/
Using docker desktop: https://www.docker.com/blog/using-docker-desktop-and-docker-hub-together-part-1/
Before starting with SDK4.x and docker based project, Installation of docker engine on your development environment and user account creation is pre-requisite.
Understand the concept:
https://docs.alfresco.com/6.2/concepts/deploy-concepts.html
Visit here for more details: https://docs.alfresco.com/6.2/concepts/deploy-prereqs.html
If problem stil persists, then create a separate thread with the logs and steps you have followed.
Note that, java11 is mandatory to run the sdk based projects. See details on deploy-prereqs shared above.
06-03-2020 11:22 AM
Its not as difficult as you are thinking. Follow the steps by step process as explained in the tutorials.
Have a look at the README file. Since your current project structure is as per SDK4.1.0, you need to make sure that you have docker installed on your environment.
06-04-2020 04:07 AM
Hello! I have created my outdoor project (SDK 4.x) following the indicated steps and when I run "run.bat build_start" from my cmd I get the following error.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "docker-compose", line 6, in <module>
File "compose\cli\main.py", line 72, in main
File "compose\cli\main.py", line 128, in perform_command
File "compose\cli\main.py", line 1077, in up
File "compose\cli\main.py", line 1073, in up
File "compose\project.py", line 548, in up
File "compose\service.py", line 351, in ensure_image_exists
File "compose\service.py", line 1106, in build
File "site-packages\docker\api\build.py", line 261, in build
File "site-packages\docker\api\build.py", line 308, in _set_auth_headers
File "site-packages\docker\auth.py", line 302, in get_all_credentials
File "site-packages\docker\credentials\store.py", line 71, in list
File "site-packages\docker\credentials\store.py", line 93, in _execute
docker.credentials.errors.StoreError: Credentials store docker-credential-desktop exited with "error listing credentials - err: exit status 1, out: `No se ha encontrado el elemento.`".
[9680] Failed to execute script docker-compose
Attaching to
Why does this error occur? How can I solve it?
And another question, What would be the url with which I can access the outdoor shared resource of this project?
Thank you very much in advance for your reply, as I can't find much information about alfresco 6.x and sdk 4.x
06-04-2020 04:24 AM
Hi @carloshc95,
What's your dev environment? It might be a permissions issue on your machine - see this thread - or other authentication issues if you're trying with Enterprise.
HTH,
06-04-2020 05:54 AM
Hi! @EddieMay,
Windows 10 and Eclipse (Eclipse IDE for Java and DSL Developers – 200- 03).
I have run with my admin account and it still produces the error.
Try testing if it is a permission problema on my machine. Thanks!
06-04-2020 06:06 AM
@carloshc95 looking at your error it seems you are using windows and i assume you have already installed Docker Desktop for windows (https://docs.docker.com/docker-for-windows/release-notes/)
Latest version can be downloaded from here just in case: https://download.docker.com/win/stable/Docker%20Desktop%20Installer.exe
Open poweshell and check following:
docker --version docker-compose -version
Both should return version successfuly, which idicates installation was proper.
Have you created user account on docker hub?
You must create a user account on docker hub and when you start Docker Desktop, you must login using the credentials you created. It will allow downloading alfresco/share and other images from docker hub (for community versions).
Go to: https://hub.docker.com/signup?next=%2F%3Foverlay%3Donboarding to create an account.
To login, use powersehll or docker desktop signin option after user account creation. Posweshell login command shown below.
PS: docker login Authenticating with existing credentials... Stored credentials invalid or expired Username (xyz@gmail.com): xyz Password: Login Succeeded
https://docs.docker.com/engine/reference/commandline/login/
Using docker desktop: https://www.docker.com/blog/using-docker-desktop-and-docker-hub-together-part-1/
Before starting with SDK4.x and docker based project, Installation of docker engine on your development environment and user account creation is pre-requisite.
Understand the concept:
https://docs.alfresco.com/6.2/concepts/deploy-concepts.html
Visit here for more details: https://docs.alfresco.com/6.2/concepts/deploy-prereqs.html
If problem stil persists, then create a separate thread with the logs and steps you have followed.
Note that, java11 is mandatory to run the sdk based projects. See details on deploy-prereqs shared above.
Explore our Alfresco products with the links below. Use labels to filter content by product module.