Service/activities4: Difference between revisions

Srevin03 (talk | contribs)
add more documentation
Tag: visualeditor-switched
No edit summary
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
== Description ==
== Description ==
A redesigned Sugar Activity Library for Python3 Activities.
Sugar Activity Library for Python 3 Activities.


== Hostnames ==
== Hostnames ==
Line 27: Line 27:
   rsync dist/Pippy-17.xo user@sunjammer.sugarlabs.org:/srv/activities-v4/bundles/
   rsync dist/Pippy-17.xo user@sunjammer.sugarlabs.org:/srv/activities-v4/bundles/
    
    
   # optionally, generate the metadata and copy them to the same bundles directory
   # optionally, generate metadata and copy to the same directory


   # add a link to source code repository
   # add a link to source code repository
Line 33: Line 33:
    
    
   # get a list of authors of the activity
   # get a list of authors of the activity
   git -P --log --pretty=format:"%an" > org.laptop.Pippy.log
   git log -P --pretty=format:"%an" > org.laptop.Pippy.log


   # copy it to sunjammer's bundles/metadata directory
   # copy them to sunjammer's bundles/metadata directory
   rsync org.laptop.Pippy.* user@sunjammer.sugarlabs.org:/srv/activities-v4/bundles/metadata/
   rsync org.laptop.Pippy.* user@sunjammer.sugarlabs.org:/srv/activities-v4/bundles/metadata/
 
  # trigger a new build of aslo-v4
  rebuild-aslo


A cron job will automatically rebuild the aslo-v4 and deploy it. Verify that your changes are deployed within 12 hours.
 
'''TODO: ''', use a better tool to rebuild the source on detecting changes.
 
Deploy directory: {{ code | /srv/www-sugarlabs/v4-activities }}
Deploy directory: {{ code | /srv/www-sugarlabs/v4-activities }}
Source directory: {{ code | /srv/activities-v4/src }}
Source directory: {{ code | /srv/activities-v4/src }}
Line 52: Line 53:
   ~/bin/aslo-rebuild
   ~/bin/aslo-rebuild


This will pull {{ code | master }} from the [https://github.com/sugarlabs/aslo-v4 source repository], and the python library will be installed to {{ code | ~/.local/lib/python3.x/site-packages }}. Once this has been done, it will be accessible from any directory. {{ code | ~/bin/aslo-rebuild }} will rebuild v4.activities.sugarlabs.org, and deploy it to {{ code | /srv/www-sugarlabs/v4-activities }}.
This will pull {{ code | master }} from the [https://github.com/sugarlabs/aslo-v4 source repository], and the python library will be installed to {{ code | ~/.local/lib/python3.x/site-packages }}. Once this has been done, it will be accessible from any directory. {{ code | ~/bin/aslo-rebuild }} will rebuild v4.activities.sugarlabs.org, and deploy it to {{ code | /srv/www-sugarlabs/v4-activities }}. This is only recommended if the user is '''activities-v4'''. For all other cases, please use {{ code | rebuild-aslo -> /usr/local/bin/rebuild-aslo }} and {{ code | source-update-aslo -> /usr/local/bin/source-update-aslo }} for rebuilding and updating the source code.
 
ASLO-v4 also maintains host specific configuration in {{ code | /srv/activities-v4/etc }} which is maintained in a git repository. To make changes, add yourself to the {{ code | activities-v4 }} group and commit your changes.