How to deploy docker image of artifactory-oss on marathon without permissions issues

I am trying to deploy a docker container of artifactory-oss

This is the docker-compose.yml I used locally to test it:

  • Linking a SQL Server with a liferay instance running in a docker container
  • Update & Upgrade Docker distribution on Windows
  • How to run the latest docker container I created?
  • how to run two microservices on same network?
  • Vagrant unable to connect to docker through ssh
  • Docker Rails Server Refusing Connections
  • version: '2'
    services:
      artifactory:
        image: jfrog-docker-registry.bintray.io/jfrog/artifactory-oss:4.1.3
        ports:
          - "8081:8081"
        volumes:
          - "/var/opt/jfrog/artifactory"
    

    I have tried to deploy it on mesos with marathon.

    I have permissions issues:

    I0415 19:43:01.747540 15616 fetcher.cpp:424] Fetcher Info: {"cache_directory":"\/tmp\/mesos\/fetch\/slaves\/4e00de0a-3293-453f-83ab-9576653867d7-S0","items":[{"action":"BYPASS_CACHE","uri":{"cache":false,"executable":false,"extract":true,"value":"file:\/\/\/etc\/docker.tar.gz"}}],"sandbox_directory":"\/tmp\/mesos\/slaves\/4e00de0a-3293-453f-83ab-9576653867d7-S0\/frameworks\/21d4cb5a-ac85-4a3c-90fd-b8ab6d37ecc0-0000\/executors\/kopaxgroup_developers_artifactory.f7cf24d5-2213-11e7-a891-c60d6e82d111\/runs\/f412d99e-34f4-459f-8533-4e58c2e8dd59"}
    I0415 19:43:01.749455 15616 fetcher.cpp:379] Fetching URI 'file:///etc/docker.tar.gz'
    I0415 19:43:01.749469 15616 fetcher.cpp:250] Fetching directly into the sandbox directory
    I0415 19:43:01.749485 15616 fetcher.cpp:187] Fetching URI 'file:///etc/docker.tar.gz'
    I0415 19:43:01.749500 15616 fetcher.cpp:167] Copying resource with command:cp '/etc/docker.tar.gz' '/tmp/mesos/slaves/4e00de0a-3293-453f-83ab-9576653867d7-S0/frameworks/21d4cb5a-ac85-4a3c-90fd-b8ab6d37ecc0-0000/executors/kopaxgroup_developers_artifactory.f7cf24d5-2213-11e7-a891-c60d6e82d111/runs/f412d99e-34f4-459f-8533-4e58c2e8dd59/docker.tar.gz'
    I0415 19:43:01.752964 15616 fetcher.cpp:84] Extracting with command: tar -C '/tmp/mesos/slaves/4e00de0a-3293-453f-83ab-9576653867d7-S0/frameworks/21d4cb5a-ac85-4a3c-90fd-b8ab6d37ecc0-0000/executors/kopaxgroup_developers_artifactory.f7cf24d5-2213-11e7-a891-c60d6e82d111/runs/f412d99e-34f4-459f-8533-4e58c2e8dd59' -xf '/tmp/mesos/slaves/4e00de0a-3293-453f-83ab-9576653867d7-S0/frameworks/21d4cb5a-ac85-4a3c-90fd-b8ab6d37ecc0-0000/executors/kopaxgroup_developers_artifactory.f7cf24d5-2213-11e7-a891-c60d6e82d111/runs/f412d99e-34f4-459f-8533-4e58c2e8dd59/docker.tar.gz'
    I0415 19:43:01.758829 15616 fetcher.cpp:92] Extracted '/tmp/mesos/slaves/4e00de0a-3293-453f-83ab-9576653867d7-S0/frameworks/21d4cb5a-ac85-4a3c-90fd-b8ab6d37ecc0-0000/executors/kopaxgroup_developers_artifactory.f7cf24d5-2213-11e7-a891-c60d6e82d111/runs/f412d99e-34f4-459f-8533-4e58c2e8dd59/docker.tar.gz' into '/tmp/mesos/slaves/4e00de0a-3293-453f-83ab-9576653867d7-S0/frameworks/21d4cb5a-ac85-4a3c-90fd-b8ab6d37ecc0-0000/executors/kopaxgroup_developers_artifactory.f7cf24d5-2213-11e7-a891-c60d6e82d111/runs/f412d99e-34f4-459f-8533-4e58c2e8dd59'
    I0415 19:43:01.758857 15616 fetcher.cpp:456] Fetched 'file:///etc/docker.tar.gz' to '/tmp/mesos/slaves/4e00de0a-3293-453f-83ab-9576653867d7-S0/frameworks/21d4cb5a-ac85-4a3c-90fd-b8ab6d37ecc0-0000/executors/kopaxgroup_developers_artifactory.f7cf24d5-2213-11e7-a891-c60d6e82d111/runs/f412d99e-34f4-459f-8533-4e58c2e8dd59/docker.tar.gz'
    I0415 19:43:12.658823 15681 exec.cpp:143] Version: 0.28.1
    I0415 19:43:12.679823 15695 exec.cpp:217] Executor registered on slave 4e00de0a-3293-453f-83ab-9576653867d7-S0
    nginx: unrecognized service
    mkdir: cannot create directory `/var/opt/jfrog/artifactory/logs': Permission denied
    mkdir: cannot create directory `': No such file or directory
    mkdir: cannot create directory `/var/opt/jfrog/artifactory/temp': Permission denied
    mkdir: cannot create directory `/var/opt/jfrog/artifactory/work': Permission denied
    touch: cannot touch `/opt/jfrog/artifactory/tomcat/logs/catalina.out': No such file or directory
    /opt/jfrog/artifactory/tomcat/bin/catalina.sh: line 401: /opt/jfrog/artifactory/tomcat/logs/catalina.out: No such file or directory
    

    Apparently I am not alone https://serverfault.com/questions/838926/docker-cannot-create-directory-opt-jfrog-artifactory-logs-permission-denied

    The Dockerfile is not viewable anywhere, does anyknow know I can solve this ?

    Edit: I managed to work with this image. It’s a old version with the very old GUI. The question is still unanswered for v4

  • docker web server does not shut even after deletion
  • How to alter the mount point of PostgreSQL through Docker?
  • Mocking 3rd party API calls without changing code
  • How to set-up a docker registry acting as a Proxy?
  • Sharing exclusive files to docker instances from host
  • openshift v3 sed couldn't open temporary file
  • Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.