2020-04-09 22:06:58 +01:00
|
|
|
name: Deploy
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
|
2020-09-12 11:29:43 +01:00
|
|
|
env:
|
|
|
|
FLICKR_API_KEY: ${{ secrets.FLICKR_API_KEY }}
|
|
|
|
FLICKR_USER_ID: ${{ secrets.FLICKR_USER_ID }}
|
|
|
|
|
2020-04-09 22:06:58 +01:00
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
|
|
|
|
- uses: actions/checkout@v1
|
2020-04-09 22:27:13 +01:00
|
|
|
with:
|
|
|
|
submodules: true
|
2020-04-09 22:06:58 +01:00
|
|
|
|
2020-09-12 11:29:43 +01:00
|
|
|
- name: Dump environment
|
|
|
|
run: env >> .env
|
|
|
|
|
2020-04-09 22:06:58 +01:00
|
|
|
- name: Build production container
|
2020-09-12 11:29:43 +01:00
|
|
|
run: docker build --tag docker.pkg.github.com/${GITHUB_REPOSITORY,,}/theorangeone.net:latest --env-file .env .
|
2020-04-09 22:06:58 +01:00
|
|
|
|
|
|
|
- name: Log into GitHub Docker Registry
|
|
|
|
run: echo ${{ secrets.GITHUB_TOKEN }} | docker login docker.pkg.github.com -u ${GITHUB_REPOSITORY%/*} --password-stdin
|
|
|
|
|
|
|
|
- name: Push the Docker container
|
2020-04-09 22:32:59 +01:00
|
|
|
run: docker push docker.pkg.github.com/${GITHUB_REPOSITORY,,}/theorangeone.net:latest
|