Skip to main content
Solved

Packaging .app with appropriate permissions

  • July 21, 2017
  • 8 replies
  • 65 views

Forum|alt.badge.img+12

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

Best answer by tfoggi

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

8 replies

donmontalvo
Forum|alt.badge.img+36
  • Hall of Fame
  • July 21, 2017

Might want to open an issue on their Github page.


Forum|alt.badge.img+12
  • Author
  • Contributor
  • July 21, 2017

Done! Thanks!


Forum|alt.badge.img+12
  • Author
  • Contributor
  • July 24, 2017

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.


Forum|alt.badge.img+3
  • New Contributor
  • September 7, 2017

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.


Forum|alt.badge.img+19
  • Contributor
  • September 7, 2017

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)


Forum|alt.badge.img
  • New Contributor
  • September 29, 2017

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?


Forum|alt.badge.img+5
  • Contributor
  • November 3, 2017

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


Forum|alt.badge.img+3
  • New Contributor
  • Answer
  • November 27, 2017

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