Sign inSign up

getting/hugo

By getting

•Updated over 6 years ago

🐳 Truly minimal Docker images for Hugo.

Image
0

1.3K

getting/hugo repository overview

⁠Hugo Docker Image

Build Status Docker Cloud Build Status MicroBadger Size Docker Pulls MIT

🐳 Truly minimal Docker images for Hugo.

⁠Docker Pull Command

docker pull getting/hugo:${tag}

⁠Building The Image Yourself

docker build --rm -t getting/hugo:latest .

注:中国大陆网络需修改Dockerfile,删除# ENV GOPROXY=https://goproxy.io 行首 #

⁠Using image

Create a new site:

docker run --rm -v $(pwd):/page getting/hugo new site ${site_name}

Build static pages:

docker run --rm -v $(pwd):/page getting/hugo

Start the Hugo server:

docker run --rm -it -p 1313:1313 -v $(pwd):/page getting/hugo server -D --bind=0.0.0.0

Command line help:

docker run --rm getting/hugo help

⁠Using on TravisCI

Example in .travis.yml:

language: minimal

branches:
  only:
    - master

sudo: required

services:
  - docker

install:
  - docker pull getting/hugo

script:
  - docker run --rm -v $(pwd):/page getting/hugo -e blog.sooo.site

deploy:
  provider: pages
  skip_cleanup: true
  github_token: $GITHUB_TOKEN
  keep_history: true
  local_dir: public
  on:
    branch: master

Tag summary

Content type

Image

Digest

Size

13 MB

Last updated

over 6 years ago

docker pull getting/hugo