Last active
October 4, 2017 11:31
-
-
Save KristerV/c01b7947641a47e0256ab938e7fdbc4d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wget http://out.redwall.ee/rangeforce/kliendile/rangeforce-1.0.zip | |
unzip rangeforce-1.0.zip -d rfweb | |
rm rangeforce-1.0.zip | |
cd rfweb/dist/ | |
# Create Dockerfile | |
cat > ./Dockerfile <<EOL | |
FROM php | |
COPY . /var/www/myapp | |
CMD ["php", "-S", "0.0.0.0:80", "-t", "/var/www/myapp"] | |
EOL | |
# Build and run container | |
docker build -t rangeforce_web . | |
docker run -d -p 80:80 --name rangeforce_web_container rangeforce_web | |
# STOP COPY HERE if all you want to do is start the server | |
# Remove container | |
docker container kill /rangeforce_web_container | |
docker container rm /rangeforce_web_container | |
# Use bash inside the container | |
docker exec -ti rangeforce_web_container /bin/bash |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment