Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
ilawbijom
@ilawbijom
@lnielsen ok thanks.
ilawbijom
@ilawbijom
Hello, does anyone know this error: elasticsearch.exceptions.NotFoundError: NotFoundError(404, 'index_not_found_exception', 'no such index')
Dubois Laurent
@itld_solutions_twitter
@ilawbijom Hi, Have you run scripts/setup ? In the setup script, there is a command to init the elasticsearch index.
ilawbijom
@ilawbijom
@itld_solutions_twitter hi, i know when i run this script the failer is gone but i will lose my data also with it. i dont want to lose my data eveytime i stop the webserver.
Zacharias Zacharodimos
@zzacharo
@ilawbijom if you open the setup you could see the commands that are being executed. For your problem you need just to run the command for creating the indexes...
invenio index init --force
by losing your data do you mean the database data?
ilawbijom
@ilawbijom
@zzacharo hello. thanks. yes i los the database data.
Zacharias Zacharodimos
@zzacharo
So if you run just the above command it will create the recreate the indexes only
ilawbijom
@ilawbijom
@zzacharo this command you mentioned works good, but one i think database tables are not regonized anymore, i get an error of internal. i want to have my database data after i stop the containers and when i run again the containers i should be able to see my database data and tables.
ilawbijom
@ilawbijom
@zzacharo . OK found the solution. i was using docker-compose down command which will stop and delete the containers. i prefer to use docker container stop <docker ids>
Zacharias Zacharodimos
@zzacharo
@ilawbijom so everything is fine now?
mb-wali
@mb-wali
@zzacharo yes dear. its fine now.
mb-wali
@mb-wali
hello guys. running this command docker-compose -f docker-compose.full.yml up to start all the services in Invenio gives an error of:ERROR: Service 'worker' failed to build: .. any ideas??
mb-wali
@mb-wali
The issue is in the Dockerfile this line of code: FROM my-site-base:${DEPENDENCIES_VERSION} is giving the error of access denied or the repository doesnt exist....... any ideas??
Olivier DOSSMANN
@blankoworld
@mb-wali probably you need to build the image before.
The ./docker/build-images.sh do the trick! ;)
mb-wali
@mb-wali
@blankoworld thank you so much... you are life saver. :)
Olivier DOSSMANN
@blankoworld
I'm just a simple human ;)
Mayazure
@Mayazure
Hi everyone, I defined a record type which has some metadata including a 'title' field. When configure the REST api, is it possible that when list all records, only the title field is listed and returned to client, while when read a specific record, all the metadata are returned to client? Thank you very much!
Zacharias Zacharodimos
@zzacharo
Hey @Mayazure you can control what is returned to your response via the serializers. You can define your marshmallow schema and enlist all the fields you want to return back to the user. You can check our latest invenio training for some more information here https://github.com/inveniosoftware/training/tree/master/07-data-models-new-field#step-7-manipulate-response-using-serializers
Mayazure
@Mayazure
@zzacharo Thanks for your response. Actually, I realized that what I need to do is to modify the search_serializer and make it different from record_serializer. After doing so, I solved the problem.
Zacharias Zacharodimos
@zzacharo
yes search_serializer is always used to manipulate search response and record_serializer when you try to access an individual record
jjcrawley
@jjcrawley
doing a little research on and not having much luck finding whether ldap can be used for user authentication in the documentation. can someone help point me to documentation? thanks!
fenekku
@fenekku
@jjcrawley We have open-sourced a library to use LDAP some time ago: https://github.com/galterlibrary/invenio-ldapclient . Feel free to contribute to it.
jjcrawley
@jjcrawley
thanks!
mb-wali
@mb-wali
Hello guys, i am trying to override the header.html of Invenio i found this documentation: https://invenio-theme.readthedocs.io/en/latest/usage.html , i am able to override the logo with this block {% block brand %} ... {% endblock brand %} but not sure how to do for search bar and navbar_header and ideas??
Zacharias Zacharodimos
@zzacharo
mb-wali
@mb-wali
@zzacharo thanks, but i want to change for example navbar_header, navbar_nav and navbar_right.
Zacharias Zacharodimos
@zzacharo
you can still extend your template from the default one and override only the blocks you need
mb-wali
@mb-wali
@zzacharo thanks mate, one more thing how can i add external javascript files to a templte?
just another template that you can override :)
In that file you can find also examples in general about template overriding
mb-wali
@mb-wali
if i have a javascript file i want to include to my template how would i do that?
Nicola
@ntarocco
@mb-wali I would recommend you to have a loot to the Invenio training repository: https://github.com/inveniosoftware/training
there are some examples and detailed instructions to achieve what you need!
Nicola
@ntarocco
for JS, you have a couple of choices
  1. add your new js file to an existing bundle, similar to here. In this case, when building the assets it will be automatically included inside that js bundle and injected in your template
  2. create a new bundle: declare the bundle as in the example above, register it in the entrypoints with a name e.g. mybundle_js, as for example here, use your new bundle in a template as here with the name my_bundle_js.
mb-wali
@mb-wali
@ntarocco thanks mate, but i have tried and i get this error in the production: any idea?? Refused to apply inline style because it violates the following Content Security Policy directive: "default-src 'self'". Either the 'unsafe-inline' keyword, a hash ('sha256-7IQC4fgmFN4sN11DMR+v/SXZnKcigtkmQfJTszsGwzc='), or a nonce ('nonce-...') is required to enable inline execution. Note also that 'style-src' was not explicitly set, so 'default-src' is used as a fallback.
Nicola
@ntarocco
@mb-wali in Invenio, by default, we are strict with the CSP directives. To be able to tune them, see here: https://github.com/inveniosoftware/invenio-app/blob/master/invenio_app/config.py#L115
we should for sure improve the documentation around CSP
in the meantime you can have a look to Talisman, the library we use for security
and tune the configuration in teh config.py
mb-wali
@mb-wali
@ntarocco thanks. :)
ugswork
@ugswork

@ugswork The issue with these webassets and these binaries, is that they have to be installed globally in your system

@slint In Github i see that invenio-communitiesv1.0.0a21 is available. Would like to know if this version has been updated to use Webpack? And also I am trying to find how to add a record to a community's inclusion request to be accepted (and added) to the community, by curate. Thank you.

ugswork
@ugswork
@slint I saw the inclusion request created in Deposit. SInce I am not using deposit, did not find it earlier.
prog20901
@prog20901
i want to develop an app using https://github.com/inveniosoftware/react-searchkit and please let me know if someone is available to discuss
please kindly ping me with private message to discuss if interested
Nicola
@ntarocco
@prog20901 I will write you privately