1

I'm testing Nexus 3 from Docker container and I'm using https://github.com/sonatype/docker-nexus/blob/94d654faa2166b60fe2a4ad9629ff418a305dcb9/oss/Dockerfile.

The issue is that when I upload artifact to the Nexus I cant find it in the file system in order to create backup. The folder /sonatype-work is empty. I've successfully use this approach for backup of Nexus 2.

Could you please advice me where Nexus 3 stores its artifacts.

030
  • 10,842
  • 12
  • 78
  • 123
user3283749
  • 21
  • 1
  • 5
  • The sonatype-work folder no longer seems to exist in Nexus 3. The best answer I could find is from the mailing list. https://groups.google.com/a/glists.sonatype.com/d/msg/nexus-users/zKfAG63KJZ0/WMQN7ovuAwAJ Guess I won't be upgrading any time soon. – Brian Blain Jul 13 '16 at 18:53
  • Does this answer your question? [Nexus 3 backup via command line?](https://stackoverflow.com/questions/49272210/nexus-3-backup-via-command-line) – 030 Mar 29 '20 at 03:02
  • Does this answer your question? [How to backup all Nexus 3 artifacts?](https://stackoverflow.com/questions/46467106/how-to-backup-all-nexus-3-artifacts) – 030 May 19 '21 at 12:24
  • It does exists and can be deducted from the behaviour of the Dockerfile. The new replacement for that location is: /opt/sonatype/sonatype-work – Alberto Soto Dec 13 '21 at 13:46

2 Answers2

0

Try the helicopterizer for Backup and Restore for Docker Container in the Cloud Providers.

https://github.com/frekele/helicopterizer

frekele
  • 644
  • 6
  • 13
0

If you followed the installation instructions, you should have a volume mount of nexus-data. You can find this by executing the following from the docker host (assuming the volume name is nexus-data):

# docker inspect nexus-data
[
    {
        "Driver": "local",
        "Labels": null,
        "Mountpoint": "/some/dir/nexus-data/_data",
        "Name": "nexus-data",
        "Options": {},
        "Scope": "local"
    }
]

This is the host dir that you will need to use for your backup script.

ntwrkguru
  • 1,644
  • 1
  • 11
  • 14