Commit 69ef8888 authored by Antoine Fontaine's avatar Antoine Fontaine 🎱
Browse files

Finally get CI right and revert max size

parent 45d2d59e
Pipeline #1896 passed with stages
in 44 minutes and 35 seconds
......@@ -10,11 +10,12 @@ run-build:
tags:
- debian
- generic
script:
before_script:
- echo 'Acquire::http { Proxy "http://rapperswil:3142"; };' > /etc/apt/apt.conf.d/02proxy
- apt-get update -qy
- apt-get install -y build-essential haskell-stack zlib1g-dev
- stack upgrade
script:
- stack build --copy-bins --pedantic --ghc-options -Wno-name-shadowing
- cp $(stack path --local-bin)/gnupaste ./gnupaste
- dpkg-buildpackage -us -uc
......@@ -54,4 +55,4 @@ run-deploy:
- chmod 644 ~/.ssh/known_hosts
script:
- 'echo "$CD_MINIDINSTALL_CONFIG" > ~/.dput.cf'
- 'dput -u gnugen build-artifacts/gnugen*.changes'
- 'dput -u gnugen build-artifacts/gnupaste*.changes'
......@@ -71,10 +71,10 @@ processUpload pool pasteDir instanceUrl reqAddr mXForward multipData =
Nothing -> throwError err400 { errBody = "You must include a file in the multipart/formdata you upload!" }
Just upload -> do
size <- liftIO $ getFileSize (fdPayload upload)
-- Ensure file isn't too big
when (size > 1*1024*1024) $
throwError err413 { errBody = "Request size exceeded 1MiB." }
--size <- liftIO $ getFileSize (fdPayload upload)
---- Ensure file isn't too big
--when (size > 1*1024*1024) $
-- throwError err413 { errBody = "Request size exceeded 1MiB." }
-- Get information to store.
now <- liftIO getCurrentTime
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment