Publish Ethereal Nexus Docker image #20
Workflow file for this run
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
name: Publish Ethereal Nexus Docker image | |
on: | |
release: | |
types: [published] | |
paths: | |
- ethereal-nexus-dashboard | |
jobs: | |
push_to_registry: | |
environment: playground | |
name: Push Docker image to Docker Hub | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out the repo | |
uses: actions/checkout@v3 | |
- name: Log in to Docker Hub | |
uses: docker/login-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- name: Extract metadata (tags, labels) for Docker | |
id: meta | |
uses: docker/metadata-action@9ec57ed1fcdbf14dcef7dfbe97b2010124a938b7 | |
with: | |
images: docker19diconium/remote-components | |
- name: 'Create env file' | |
run: | | |
echo "${{ secrets.MONGODB_URI }}" >> ./ethereal-nexus-dashboard/.env | |
echo "${{ secrets.AZURE_BLOB_STORAGE_ACCOUNT }}" >> ./ethereal-nexus-dashboard/.env | |
echo "${{ secrets.AZURE_BLOB_STORAGE_SECRET }}" >> ./ethereal-nexus-dashboard/.env | |
echo "${{ secrets.PGHOST }}" >> ./ethereal-nexus-dashboard/.env | |
echo "${{ secrets.PGUSER }}" >> ./ethereal-nexus-dashboard/.env | |
echo "${{ secrets.PGPORT }}" >> ./ethereal-nexus-dashboard/.env | |
echo "${{ secrets.PGPASSWORD }}" >> ./ethereal-nexus-dashboard/.env | |
echo "PGSSL=true" >> ./ethereal-nexus-dashboard/.env | |
echo "${{ secrets.NEXT_AUTH_SECRET }}" >> ./ethereal-nexus-dashboard/.env | |
- name: debug env file | |
run: | | |
ls -la . | |
ls -la ./ethereal-nexus-dashboard/ | |
cat ./ethereal-nexus-dashboard/.env | |
- name: Build and push Docker image | |
uses: docker/build-push-action@v2 | |
with: | |
context: ./ethereal-nexus-dashboard/ | |
file: ./ethereal-nexus-dashboard/Dockerfile | |
push: true | |
tags: ${{ steps.meta.outputs.tags }} | |
labels: ${{ steps.meta.outputs.labels }} |