Your message dated Sat, 12 Sep 2015 21:19:44 +0000
with message-id <[email protected]>
and subject line Bug#785396: fixed in coquelicot 0.9.4-1
has caused the Debian Bug report #785396,
regarding Fix sass-cache location (breaks in Jessie)
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
785396: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=785396
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: coquelicot
Version: 0.9.3-1
Tags: patch
Control: block -1 by 782634

This patch follows from #782634, and adds configurable cache location (and sets
it to something sane for Debian, because otherwise the default sass-cache
location when running as a daemon is /.sass-cache, which breaks with
permissions errors. Although I marked the patch as "Forwarded: not-needed", you
may wish to add cache_path to upstream's default config too, with a local
setting like "./cache", in which case feel free to forward this to yourself :-D
and add that line.

As mentioned before, I am not so familiar with Ruby idioms, so although I also
took a stab at updating the various spec/etc files for the new config-var, I
strongly recommend reviewing those bits, as I probably got something wrong with
them.

-- 
Rowan Thorpe
PGP fingerprint:
 BB0A 0787 C0EE BDD8 7F97  3D30 49F2 13A5 265D CCBD
----
"There is a great difference between worry and concern. A worried person sees
a problem, and a concerned person solves a problem."
 - Harold Stephens
>From 8a93d4c2ff446a18532a45412a6392ec81403983 Mon Sep 17 00:00:00 2001
From: Rowan Thorpe <[email protected]>
Date: Fri, 15 May 2015 15:44:33 +0300
Subject: [PATCH] Add configurable cache location (needed in Jessie)

* This adds a configurable cache location, and sets a sane default for
  debian - which is in fact necessary for >= Jessie, as otherwise the default
  sass-cache location is /.sass-cache which causes permissions problems

* I also included a small sneaky improvement to the header of the previous
  debian-diff
---
 debian/coquelicot.postinst                         |   4 +
 .../patches/0011-Improve-running-as-non-root.patch |   4 +
 .../0012-Fix-sass-cache-location-on-jessie.patch   | 108 +++++++++++++++++++++
 debian/patches/series                              |   1 +
 debian/settings.yml                                |   4 +
 5 files changed, 121 insertions(+)
 create mode 100644 debian/patches/0012-Fix-sass-cache-location-on-jessie.patch

diff --git a/debian/coquelicot.postinst b/debian/coquelicot.postinst
index c2e4cd4..cea412a 100755
--- a/debian/coquelicot.postinst
+++ b/debian/coquelicot.postinst
@@ -17,6 +17,10 @@ case "$1" in
 		chown coquelicot:coquelicot /var/lib/coquelicot
 		chmod 750 /var/lib/coquelicot
 	fi
+	if ! dpkg-statoverride --list "/var/cache/coquelicot"; then
+		chown coquelicot:coquelicot /var/cache/coquelicot
+		chmod 750 /var/cache/coquelicot
+	fi
 	if ! dpkg-statoverride --list "/var/log/coquelicot"; then
 		chown root:coquelicot /var/log/coquelicot
 		chmod 770 /var/log/coquelicot
diff --git a/debian/patches/0011-Improve-running-as-non-root.patch b/debian/patches/0011-Improve-running-as-non-root.patch
index 076cf05..7d8f100 100644
--- a/debian/patches/0011-Improve-running-as-non-root.patch
+++ b/debian/patches/0011-Improve-running-as-non-root.patch
@@ -4,6 +4,10 @@ Forwarded: not-needed
 Last-Update: 2015-03-05
 ---
 This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+---
+ lib/coquelicot/app.rb |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
 --- a/lib/coquelicot/app.rb
 +++ b/lib/coquelicot/app.rb
 @@ -240,7 +240,7 @@
diff --git a/debian/patches/0012-Fix-sass-cache-location-on-jessie.patch b/debian/patches/0012-Fix-sass-cache-location-on-jessie.patch
new file mode 100644
index 0000000..d20b5f3
--- /dev/null
+++ b/debian/patches/0012-Fix-sass-cache-location-on-jessie.patch
@@ -0,0 +1,108 @@
+Description: Force sane sass-cache location (avoids permissions problems on Jessie)
+Author: Rowan Thorpe <[email protected]>
+Forwarded: not-needed
+Last-Update: 2015-05-15
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+---
+ HACKING                     |    4 +++-
+ conf/settings-default.yml   |    4 ++++
+ lib/coquelicot/app.rb       |    4 +++-
+ spec/coquelicot/app_spec.rb |    8 ++++++++
+ spec/spec_helper.rb         |    8 ++++++++
+ 5 files changed, 26 insertions(+), 2 deletions(-)
+
+--- a/HACKING
++++ b/HACKING
+@@ -131,7 +131,9 @@
+ Storage details
+ ---------------
+ 
+-Files are stored in the directory specified by the 'depot_path' setting.
++Files are stored in the directory specified by the 'depot_path' setting, and
++cache files are stored in the directory specified by the 'cache_path'
++setting.
+ One file in Coquelicot is actually stored in two files: one for metadata and
+ one for the file content.
+ 
+--- a/conf/settings-default.yml
++++ b/conf/settings-default.yml
+@@ -70,6 +70,10 @@
+ #
+ depot_path: "./files"
+ 
++# Cache directory in which Coquelicot will write throwaway files
++#
++cache_path: "./cache"
++
+ # Text to display on top of the upload form
+ #
+ #   This is indexed by locale code to support multiple languages.
+--- a/spec/coquelicot/app_spec.rb
++++ b/spec/coquelicot/app_spec.rb
+@@ -322,6 +322,7 @@
+         settings = Tempfile.new('coquelicot')
+         begin
+           settings.write(YAML.dump({ 'depot_path' => '/nonexistent' }))
++          settings.write(YAML.dump({ 'cache_path' => '/nonexistent2' }))
+           settings.close
+           @settings_path = settings.path
+           example.run
+@@ -336,6 +337,13 @@
+         end
+         expect(Coquelicot.settings.depot_path).to be == '/nonexistent'
+       end
++      it 'should use the cache path defined in the given settings' do
++        # We don't give a command, so exit is expected
++        stderr = capture(:stderr) do
++          expect { Coquelicot.run! ['-c', @settings_path] }.to raise_error(SystemExit)
++        end
++        expect(Coquelicot.settings.cache_path).to be == '/nonexistent2'
++      end
+     end
+     context 'when the given settings file does not exist' do
+       it 'should display an error' do
+--- a/spec/spec_helper.rb
++++ b/spec/spec_helper.rb
+@@ -55,6 +55,14 @@
+     ensure
+       FileUtils.remove_entry_secure path
+     end
++    path = Dir.mktmpdir('coquelicot')
++    begin
++      @cache_path = path
++      app.set :cache_path, path
++      example.run
++    ensure
++      FileUtils.remove_entry_secure path
++    end
+   end
+ end
+ 
+--- a/lib/coquelicot/app.rb
++++ b/lib/coquelicot/app.rb
+@@ -232,6 +232,7 @@
+                                              File.join(root, 'public') :
+                                              '/usr/share/coquelicot/public' }
+     set :depot_path, '/var/lib/coquelicot'
++    set :cache_path, '/var/cache/coquelicot'
+     set :max_file_size, 5 * 1024 * 1024 # 5 MiB
+     set :default_expire, 60
+     set :maximum_expire, 60 * 24 * 30 # 1 month
+@@ -255,6 +256,7 @@
+     use Coquelicot::Rack::Upload
+     # limit requests other than upload to an input body of 5 kiB max
+     use Rainbows::MaxBody, 5 * 1024
++    FileUtils.mkdir_p(File.join(settings.cache_path, 'sass-cache'))
+ 
+     not_found do
+       @uri = env['REQUEST_URI']
+@@ -280,7 +282,7 @@
+ 
+     get '/style.css' do
+       content_type 'text/css', :charset => 'utf-8'
+-      sass :style
++      sass :style, :cache_location => File.join(settings.cache_path, 'sass-cache')
+     end
+ 
+     get '/' do
diff --git a/debian/patches/series b/debian/patches/series
index f0b777a..a742015 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -5,3 +5,4 @@
 0006-Stop-using-non-free-background-image.patch
 0010-Fix-gem-dependency-issues.patch
 0011-Improve-running-as-non-root.patch
+0012-Fix-sass-cache-location-on-jessie.patch
diff --git a/debian/settings.yml b/debian/settings.yml
index 0d2d3ba..0951409 100644
--- a/debian/settings.yml
+++ b/debian/settings.yml
@@ -70,6 +70,10 @@ random_pass_length: 16
 #
 depot_path: "/var/lib/coquelicot"
 
+# Cache directory in which Coquelicot will write throwaway files
+#
+cache_path: "/var/cache/coquelicot"
+
 # Text to display on top of the upload form
 #
 #   This is indexed by locale code to support multiple languages.
-- 
2.1.4


--- End Message ---
--- Begin Message ---
Source: coquelicot
Source-Version: 0.9.4-1

We believe that the bug you reported is fixed in the latest version of
coquelicot, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Jérémy Bobbio <[email protected]> (supplier of updated coquelicot package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Sat, 12 Sep 2015 22:07:26 +0200
Source: coquelicot
Binary: coquelicot
Architecture: source all
Version: 0.9.4-1
Distribution: unstable
Urgency: medium
Maintainer: Jérémy Bobbio <[email protected]>
Changed-By: Jérémy Bobbio <[email protected]>
Description:
 coquelicot - "one-click" file sharing web application with a focus on users' p
Closes: 722528 741421 773820 774859 774944 776312 778754 779828 782634 785396 
796416 796503
Changes:
 coquelicot (0.9.4-1) unstable; urgency=medium
 .
   [ Jérémy Bobbio ]
   * New upstream release:
     - Keep errors from the authentication methods in the logs. (Closes: 
#741421)
     - Ensure compatibility with RSpec 3. (Closes: #796416)
   * Update debian/README.source
   * Update git-buildpackage configuration.
   * Update Depends and Build-Depends to match new upstream requierements.
     ruby-hpricot is no longer required. (Closes: #796503)
   * Update debian/copyright.
   * Document and ship settings for the LDAP authentication method.
     Original patch by Rowan Thorpe. (Closes: #774944)
   * Merge new upstream settings to the Debian configuration. We now create
     /var/cache/coquelicot for cache files. Original patch by Rowan Thorpe.
     (Closes: #785396)
   * Refresh patches and drop obsolete ones.
   * Update static gemspec.
   * Don't use bundler at all to run the test suite.
   * Add a patch to support the version of tilt currently in Debian.
   * Run integration tests when building the package.
   * Add a patch from upstream to fix a missing requires in integration tests.
   * Rewrite initscript using init-d-script(5). Thanks Rowan Thorpe for the
     suggestion. (Closes: #778754)
   * Stop running coquelicot as root. Big up to Rowan Thorpe for noticing the
     problem and offering an initial patch. (Closes: #779828, #782634)
   * Use debian/changelog date as gem build time. (Closes: #776312)
   * Add autopkgtests: on top of using gem2deb-test-runner to run unit tests and
     integration tests on the installed package, we also do black box testing
     for basic upload/download and garbage collection.
   * Add a patch from upstream to be compatible with jQuery 1.9+.
   * Switch to debhelper compat level 9.
   * Mention in debian/README.Debian that sub-directories are supported.
     (Closes: #722528)
 .
   [ Rowan Thorpe ]
   * Verify upstream OpenPGP signature.
   * Document that quilt patches must be applied when creating static gemspec.
   * Add ignores and clean rules for package rebuilding. (Closes: #774859)
   * Fix URL of the Git repository. (Closes: #773820)
   * Bump Standards-Version and use canonical URLs in Vcs-*.
Checksums-Sha1:
 da0fc385a26bc1500957e5d8d4e732e0c2c1b41b 2299 coquelicot_0.9.4-1.dsc
 0fd7feb0e556b2d588f66acf9013c3411412b5d5 187287 coquelicot_0.9.4.orig.tar.gz
 8eefaaf2e35a7102085c9a32086e5469d1fbc445 38873 coquelicot_0.9.4-1.debian.tar.gz
 fe6c80bad43f45d8220b17216bb624134c8b386f 290802 coquelicot_0.9.4-1_all.deb
Checksums-Sha256:
 2ed3a9dded53ee00bbcb4e5b499b6fa8ed735e8f886e8726e78ef79122016dfe 2299 
coquelicot_0.9.4-1.dsc
 91b69bdaec8f835859f2ab73b5c28e3092f250a18a158da8ea2fb5db6b694f5c 187287 
coquelicot_0.9.4.orig.tar.gz
 19bd9cfcfc9ddf7b8edce673c186cf7a0e0205daada38580f34342aecbf54474 38873 
coquelicot_0.9.4-1.debian.tar.gz
 16f0e59727bae4073097dadeccef5b30e6b8c930dbbe828bd84680beb669f714 290802 
coquelicot_0.9.4-1_all.deb
Files:
 2dca539742b1f29ebb87b60b4ea0c240 2299 web optional coquelicot_0.9.4-1.dsc
 9599e4e1d552fdd3a7ec551faed7e47d 187287 web optional 
coquelicot_0.9.4.orig.tar.gz
 1df8b7ee3bbb90ebb51ae10dbc689928 38873 web optional 
coquelicot_0.9.4-1.debian.tar.gz
 916c1af5e1be72888114c7ccdc5399dd 290802 web optional coquelicot_0.9.4-1_all.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iQIcBAEBCAAGBQJV9Il+AAoJEEAsIlA9Nuk227IP/jz756Zpw2gGPp9/dp0al/El
j6HPkxiCoQBOEDs9vM9Q/VMf8vobg+tgY0Rts0/63rwmwbEGWMc7Nk/p7npSiPdH
Jz+JGfdmzd+HIs/kQcdJNEsxlGwIylbeOqF6fzo3P2qyFV+auJLDKrLR/EU4V6XG
sNytMNWKxRaXOQu4wFLHsZB7FL1TqAPQlqk4/IMBzmkR8o4acKHg04PyV3zT2Ypa
eYLkJ3PmMymQz6UwdJhTxKBXizeQEbDz716mderdAsxyp3ukEm5RS75H0+5Mgdlu
UQf1HW7LdVVIXdZNQ6kz49+XqSRZkeWm7Nj3gKIFHefYz0enxqZdix7PBh9vIity
ckbHac6CEMQ00chpg790uIaxzZmpAymxvilGBrffGk6h9OXLG/tFZ9mqHjcpbepD
FeSXNBRzDk6ljPdKs9/TCl7K8v7yNnQkYuHTKRawZ3eeupl9P0iIazj7og7TdRDI
HDoVJwJvrY1j/sOQ7EzGWo0DHnzbbfg5sc4YIJWi95ZmKz5Y1YNvjOiGS8BUaBiU
G8iq9zhymPg9mNXFhoo1M8BGx/APVJgeiOADIuHQsYIp6M5pnkNB0UUNxYsXXtUU
oAxD5ymSc8xelGj/a3M0hl3qSLxnGd/ioStlTGebZuWm26dzZYfqBHCNKvewMRWX
EaPwnqvhQLbIHuRqyioB
=4Nu0
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to