Browse Source

Plan b, upload to aws in preparation.

master
Jonas Oberg 2 years ago
parent
commit
3f7bb3c7ba
3 changed files with 11 additions and 1 deletions
  1. 3
    1
      Dockerfile
  2. 1
    0
      playbook.yml
  3. 7
    0
      site/build/build.sh

+ 3
- 1
Dockerfile View File

@@ -4,7 +4,9 @@ ENV HUGO_VERSION 0.20.7
ENV HUGO_BINARY hugo_${HUGO_VERSION}_Linux-64bit.deb

RUN apt-get update && apt-get upgrade -y && \
apt-get install -y git curl unzip python3
apt-get install -y git curl unzip python3 python3-pip libyaml-dev

RUN pip3 install awscli

RUN curl -sS https://getcomposer.org/installer \
| php -- --install-dir=/usr/local/bin --filename=composer

+ 1
- 0
playbook.yml View File

@@ -19,4 +19,5 @@
LETSENCRYPT_EMAIL: jonas@fsfe.org
volumes:
- "/srv/forms/pmpc:/usr/share/blog/data/signatures:ro"
- "/srv/pmpc-cred:/srv/cred:ro"


+ 7
- 0
site/build/build.sh View File

@@ -18,4 +18,11 @@ if [ "$mode" == "server" ]; then
hugo server
else
hugo

#
# After building the website, we set the AWS credentials and uploda
# everything to our AWS s3 bucket.
#
. /srv/cred/aws.sh
/usr/local/bin/aws s3 cp /usr/share/blog/public/ s3://aws-website-pmpc-soegm/ --recursive
fi

Loading…
Cancel
Save