Add jenkinsfile (#72)
* create Jenkinsfile * allow textlive image to be set with env vars * log error message in test * use sandboxed compiles variables * Add SANDBOXED_COMPILES_HOST_DIR var to test config * add SIBLING_CONTAINER_USER env var
This commit is contained in:
@@ -92,14 +92,14 @@ describe "Example Documents", ->
|
||||
|
||||
it "should generate the correct pdf", (done) ->
|
||||
Client.compileDirectory @project_id, fixturePath("examples"), example_dir, 4242, (error, res, body) =>
|
||||
if body?.compile?.status is "failure"
|
||||
if error || body?.compile?.status is "failure"
|
||||
console.log "DEBUG: error", error, "body", JSON.stringify(body)
|
||||
pdf = Client.getOutputFile body, "pdf"
|
||||
downloadAndComparePdf(@project_id, example_dir, pdf.url, done)
|
||||
|
||||
it "should generate the correct pdf on the second run as well", (done) ->
|
||||
Client.compileDirectory @project_id, fixturePath("examples"), example_dir, 4242, (error, res, body) =>
|
||||
if body?.compile?.status is "failure"
|
||||
if error || body?.compile?.status is "failure"
|
||||
console.log "DEBUG: error", error, "body", JSON.stringify(body)
|
||||
pdf = Client.getOutputFile body, "pdf"
|
||||
downloadAndComparePdf(@project_id, example_dir, pdf.url, done)
|
||||
|
||||
@@ -16,6 +16,7 @@ module.exports =
|
||||
clsiCacheDir: Path.resolve(__dirname + "/../../../cache")
|
||||
#synctexBaseDir: (project_id) -> Path.join(@compilesDir, project_id)
|
||||
synctexBaseDir: () -> "/compile"
|
||||
sandboxedCompilesHostDir: process.env['SANDBOXED_COMPILES_HOST_DIR']
|
||||
|
||||
clsi:
|
||||
#strace: true
|
||||
@@ -23,13 +24,13 @@ module.exports =
|
||||
commandRunner: "docker-runner-sharelatex"
|
||||
latexmkCommandPrefix: ["/usr/bin/time", "-v"] # on Linux
|
||||
docker:
|
||||
image: "texlive-full:2017.1-opt"
|
||||
image: process.env.TEXLIVE_IMAGE || "texlive-full:2017.1-opt"
|
||||
env:
|
||||
PATH: "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/texlive/2017/bin/x86_64-linux/"
|
||||
HOME: "/tmp"
|
||||
modem:
|
||||
socketPath: false
|
||||
user: "111"
|
||||
user: process.env.SIBLING_CONTAINER_USER ||"111"
|
||||
|
||||
internal:
|
||||
clsi:
|
||||
|
||||
Reference in New Issue
Block a user