Uploading to dropbox

Hi,

Okay, I’m sure there is a better way of doing this, but it works for me.

You need to have jibri installed on a server, edit /etc/jitsi/jibri/config.json and change the finalising script location to /usr/bin, save and restart jibri with service jibri restart

You also need to make sure you set your AppKey in your /etc/jitsi/meet/meet.hostname-config.js file on your jitsi server. Restart the relevant server.

Clone the jitsi-upload-integrations and copy both the dropbox/dropbox_uploader.sh and the jitsi_uploader.sh to /usr/bin.

Now use su to become the jibri user and add your generated access token to the uploader:
su - jibri
dropbox_uploader.sh

Edit jitsi_uploader.sh and in the dropbox_upload function replace:

$UPLOAD_BIN -b upload "$1" "$2"

With:
f="$(basename – $2)"
$UPLOAD_BIN -b upload “$1” “/Recordings/$f”

It does upload the video with underscores instead of spaces, but it does upload the video rather than saying it has. If you comment out the rm and rmdir you can keep a copy of the video on the jibri server as well.

1 Like

hi, could you be more detailed? I followed you up to the appkey, even the first step I suppose is to change “finalize_recording_script_path”: “/path/to/finalize_recording.sh”, in
“finalize_recording_script_path”: “/usr/bin/finalize_recording.sh”, ok! but then it is not clear what to do, could you show me the steps? I don’t understand why there is no guide to implement dropbox correctly. I hope you can help me. thanks

Well, many questions for configuring a function to upload to Dropbox but almost are unuseful or too complicated to follow. WHY???
With me, it’s quite simple:

  • Login your Dropbox account > create new app > get keyapp and input something similar as OAUTH2 (Redirect URIs) : “https://meet.yourdomain.com/static/oauth.html
    That’s all on Dropbox

  • Now, everything is on your server side:
    $ vi /etc/jitsi/meet/meet.yourdomain.com-config.js
    fileRecordingsEnabled: true,
    dropbox: {
    appKey: ‘123456asdzxc’ // Specify your app key here.
    }
    # NOTE: dont miss this quote

    $ apt install jitsi-upload-integrations -y

    $ ls -l /usr/bin/jitsi_uploader.sh
    # this bash should be here :slight_smile:

    $ vi /etc/jitsi/jibri/config.json
    “finalize_recording_script_path”: “/usr/bin/jitsi_uploader.sh”

    $ reboot -h # i prefer this cmd
    DONE!!!

it doesn’t work, when I click login; does nothing…

it doesn’t work, when I click login; does nothing…

I’ve never seen “nothing”. Recheck carefully any popup or your logs which is located on /var/log/jitsi/jibri/log.0.txt

it should go to another window where do dropbox login; and this doesn’t happen when I click sign in …

Recheck steps as i posted.
You should ensure:

  • Enabled dropbox section in “/etc/jitsi/meet/meet.yourdomain.com-config.js”
  • And edit “finalize_recording_script_path”: “/usr/bin/jitsi_uploader.sh” in “/etc/jitsi/jibri/config.json”

If, even, I have made tests with the file dropbox_uploader.sh; executing command from this file in terminal; create directories and delete them, for example, and it communicates perfectly with the app created in dropbox. At the moment I have the problem in the UI, that when pressing the Sign In button does not go to the part where I login with Dropbox; the error in the browser inspector is as follows:

Logger.js:154 2020-06-30T13:45:33.907Z [JitsiMeetJS.js] <Object.getGlobalOnErrorHandler>: UnhandledError: null Script: null Line: null Column: null StackTrace: Error: A client id is required. You can set the client id using .setClientId().
at t.value (Dropbox-sdk.min.js:1)
at ue (functions.web.js:46)
at actions.js:27
at index.js:11
at middleware.js:41
at middleware.js:29
at middleware.js:13
at middleware.js:30
at middleware.js:39
at middleware.js:22
at middleware.js:22
at middleware.js:67
at middleware.js:19
at middleware.js:20
at middleware.js:19
at middleware.js:23
at middleware.js:15
at middleware.js:23
at middleware.js:72
at middleware.js:110
at middleware.js:43
at middleware.js:30
at middleware.js:23
at middleware.js:25
at middleware.js:40
at subscriber.js:19
at middleware.web.js:20
at middleware.web.js:20
at middleware.web.js:34
at middleware.any.js:55
at middleware.js:44
at middleware.js:29
at middleware.js:16
at middleware.js:81
at middleware.web.js:22
at middleware.any.js:93
at middleware.js:77
at middleware.js:32
at middleware.js:33
at middleware.js:71
at middleware.js:103
at middleware.js:24
at middleware.js:131
at middleware.js:16
at middleware.js:61
at middleware.js:106
at middleware.js:21
at middleware.js:42
at middleware.js:44
at middleware.js:24
at index.js:3
at middleware.js:24
at middleware.js:61
at middleware.js:162
at middleware.js:42
at middleware.js:23
at middleware.js:106
at Object.dispatch (middleware.js:133)
at Oe._onSignIn (StartRecordingDialogContent.js:463)
at withAnalyticsEvents.js:77
at Object.f (react-dom.production.min.js:15)
at w (react-dom.production.min.js:15)
at react-dom.production.min.js:16
at E (react-dom.production.min.js:16)
at D (react-dom.production.min.js:17)
at A (react-dom.production.min.js:17)
at O (react-dom.production.min.js:17)
at Pn (react-dom.production.min.js:85)
at Rn (react-dom.production.min.js:87)
at t.unstable_runWithPriority (scheduler.production.min.js:20)
at ha (react-dom.production.min.js:113)
at zs (react-dom.production.min.js:207)
at Fn (react-dom.production.min.js:86)
s @ md5.js:1
getGlobalOnErrorHandler @ async.js:1
window.onunhandledrejection @ app.bundle.min.js?v=4127:1
Dropbox-sdk.min.js:1 Uncaught (in promise) Error: A client id is required. You can set the client id using .setClientId().
at t.value (Dropbox-sdk.min.js:1)
at ue (functions.web.js:46)
at actions.js:27
at index.js:11
at middleware.js:41
at middleware.js:29
at middleware.js:13
at middleware.js:30
at middleware.js:39
at middleware.js:22
at middleware.js:22
at middleware.js:67
at middleware.js:19
at middleware.js:20
at middleware.js:19
at middleware.js:23
at middleware.js:15
at middleware.js:23
at middleware.js:72
at middleware.js:110
at middleware.js:43
at middleware.js:30
at middleware.js:23
at middleware.js:25
at middleware.js:40
at subscriber.js:19
at middleware.web.js:20
at middleware.web.js:20
at middleware.web.js:34
at middleware.any.js:55
at middleware.js:44
at middleware.js:29
at middleware.js:16
at middleware.js:81
at middleware.web.js:22
at middleware.any.js:93
at middleware.js:77
at middleware.js:32
at middleware.js:33
at middleware.js:71
at middleware.js:103
at middleware.js:24
at middleware.js:131
at middleware.js:16
at middleware.js:61
at middleware.js:106
at middleware.js:21
at middleware.js:42
at middleware.js:44
at middleware.js:24
at index.js:3
at middleware.js:24
at middleware.js:61
at middleware.js:162
at middleware.js:42
at middleware.js:23
at middleware.js:106
at Object.dispatch (middleware.js:133)
at Oe._onSignIn (StartRecordingDialogContent.js:463)
at withAnalyticsEvents.js:77
at Object.f (react-dom.production.min.js:15)
at w (react-dom.production.min.js:15)
at react-dom.production.min.js:16
at E (react-dom.production.min.js:16)
at D (react-dom.production.min.js:17)
at A (react-dom.production.min.js:17)
at O (react-dom.production.min.js:17)
at Pn (react-dom.production.min.js:85)
at Rn (react-dom.production.min.js:87)
at t.unstable_runWithPriority (scheduler.production.min.js:20)
at ha (react-dom.production.min.js:113)
at zs (react-dom.production.min.js:207)
at Fn (react-dom.production.min.js:86)

Have you followed https://jitsi.github.io/handbook/docs/dev-guide/dev-guide-web-integrations#creating-the-dropbox-app-for-dropbox-recording-integration ?

Yes, and I have reviewed step by step again several times. The only doubt is that the instructions suggest putting in Redirect URIs; https://yourdeployment.com//static/oauth.html; two slaches after the domain, but the .js file suggests a single slash after the domain. I have tried it both ways. Now when I put this url in the browser; goes to a blank page, is this correct? I have tried placing: https://meet.jit.si/static/oauth.html in the browser and it does the same; I do not know if it is because it is correct or on this server they have the location of the static folder elsewhere.

Thanks again…

Yes, that page is blank when checked from the browser. It is a auth callback

Hello Damencho, yes, the file that is hosted on my server has exactly that code. Which may be the problem. Any suggestion?

It is great! Works fine, thanks!

Two things you should concern:

  • Was Dropbox app enable “additional users”?
  • A recording iwill be success only if your meeting run without password :slight_smile:
    (It is fixed with Prosody 0.11.5)