Skip to content

Instantly share code, notes, and snippets.

@4lberto
Created April 11, 2018 15:36
Show Gist options
  • Save 4lberto/246ab497bc7c3ae092eedfa86f08dba6 to your computer and use it in GitHub Desktop.
Save 4lberto/246ab497bc7c3ae092eedfa86f08dba6 to your computer and use it in GitHub Desktop.
Launch a container with Nexus 3 in Ubuntu. Uses a host directory to crate a volume to store data
#!/bin/bash
#Create a directory to store the data in
mkdir nexus-data
chown -R 200:200 nexus-data
#Launch docker with a volume
docker run -d -p 28081:28081 --name nexus -v $(pwd)nexus-data:/sonatype-work sonatype/nexus3
#show log
docker logs -f nexus3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment