Packaging .app with appropriate permissions

bbot
Contributor

I'm trying to deploy Cisco Spark but am running into permission errors. I've tried using Composer, and dragging and dropping the .app into Composer and packaging as a dmg.

If I set the permission to root/admin with 755, at every launch it tells me I don't have the appropriate permission to auto-update. If I change the owner to the logged in user, it'll be fine.

How can I deploy an app and set the owner always to the logged in user?

Download link
https://www.ciscospark.com/downloads.html

1 ACCEPTED SOLUTION

tfoggi
New Contributor II

I solved this by including a simple postinstall script in the deployment package to change ownership of the app file to the current user after it is copied to the Applications folder:

################################################
#!/bin/sh

# Set "CurrentUser" to current logged-in user
CurrentUser="$(stat -f %Su /dev/console)"

# Set ownership of Cisco Spark.app to current user
/usr/sbin/chown -R $CurrentUser /Applications/Cisco Spark.app

################################################

Then if you want to disable the EULA for users:

  1. Grab the ~/Library/Application Support/Cisco Spark/spark_shared_store.db
  2. Open with SQLLite editor such as DB Browser for SQLite
  3. "Clean" the db file by zeroing out the values for PreLoginID and InstallationID
  4. Enter a value of "Accepted" (no quotes) for the value of the EulaAccepted filter
  5. Create a separate .dmg package to deploy this to all users using FEU and FUT

View solution in original post

8 REPLIES 8

donmontalvo
Esteemed Contributor III

Might want to open an issue on their Github page.

--
https://donmontalvo.com

bbot
Contributor

Done! Thanks!

bbot
Contributor

According to Cisco -- not sure why he's talking about GPO's and msiexec when we were talking about Macs...

After reviewing the case, I understand that you want to do a mass deployment of the Cisco Spark application on the all MAC users. I am not sure if this is possible, I will check with the resources and provide an update. In the meantime, could you please tell why you want to do a mass deployment of Spark? The user can download the client or use Spark for web is they do not have admin rights.
There is no document for mass deployment of the Cisco spark app. However it's a cloud deployed app , the msi you pull down from ciscospark.com is more or a less an installer / shell and it can be installed using msiexec or via gpo/ sccm tools. The context of the app install is designed to be installed / ran by the user, so that admin rights aren't required for user to install the app even in lock down environment.

tfoggi
New Contributor II

I'm seeing this issue also, curious if there have been any further developments? Thinking about rigging our deployment to install as the user possibly, but curious if Cisco has a solution in the works. I'd rather they fix it on their end obviously.

ryan_ball
Valued Contributor

You might also try just dragging the .app into Packages.

Developer's site:
[http://s.sudre.free.fr/Software/Packages/about.html](link URL)

rtrouton's blog about it:
[https://derflounder.wordpress.com/2014/05/02/building-simple-packages-with-packages/](link URL)

infusionsoft
New Contributor

I am also having this issue. When it is deployed, there is a message saying "Cisco Spark is installed with incorrect permissions. Automatic application updates will fail..."

I have tried creating the package in Composer as a .dmg and .pkg with the same result. I created the package with Packages and deployed using JAMF and the result is the same.....anyone have some ideas?

Ken_Bailey
New Contributor III

Hi Just wanted to see if anybody has any luck with this. Currently having same issue and looking to do a mass rollout.

tfoggi
New Contributor II

I solved this by including a simple postinstall script in the deployment package to change ownership of the app file to the current user after it is copied to the Applications folder:

################################################
#!/bin/sh

# Set "CurrentUser" to current logged-in user
CurrentUser="$(stat -f %Su /dev/console)"

# Set ownership of Cisco Spark.app to current user
/usr/sbin/chown -R $CurrentUser /Applications/Cisco Spark.app

################################################

Then if you want to disable the EULA for users:

  1. Grab the ~/Library/Application Support/Cisco Spark/spark_shared_store.db
  2. Open with SQLLite editor such as DB Browser for SQLite
  3. "Clean" the db file by zeroing out the values for PreLoginID and InstallationID
  4. Enter a value of "Accepted" (no quotes) for the value of the EulaAccepted filter
  5. Create a separate .dmg package to deploy this to all users using FEU and FUT