Skip to content

Commit

Permalink
Changed copy command (#38)
Browse files Browse the repository at this point in the history
Co-authored-by: Martin-Belton-gov <martin.belton@digital.education.gov.uk>
  • Loading branch information
MartinBelton-gov and Martin-Belton-gov authored Feb 1, 2024
1 parent db9c22e commit 43be846
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 14 deletions.
9 changes: 2 additions & 7 deletions .github/workflows/dockerpublish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,17 +88,12 @@ jobs:
cd /home/runner/work/Grafana.Plugin.CostManagement/Grafana.Plugin.CostManagement/latest-cost-plugin
unzip -o dfe-azurecostbackend-datasource-${{ env.PLUGIN_VERSION }}.zip
unzip -o blackcowmoo-googleanalytics-datasource-0.2.3.zip
cp /home/runner/work/Grafana.Plugin.CostManagement/Grafana.Plugin.CostManagement/grafana-files/grafana.ini .
cd /home/runner/work/Grafana.Plugin.CostManagement/Grafana.Plugin.CostManagement/latest-cost-plugin/dfe-azurecostbackend-datasource
pwd
ls
cd /home/runner/work/Grafana.Plugin.CostManagement/Grafana.Plugin.CostManagement
- name: Copy grafana.ini to /etc/grafana
run: |
sudo cp /home/runner/work/Grafana.Plugin.CostManagement/Grafana.Plugin.CostManagement/grafana-files/grafana.ini /etc/grafana/
ls -l /etc/grafana/
cat /etc/grafana/grafana.ini
shell: bash
# Build and push Docker image with Buildx (don't push on PR)
# https://github.com/docker/build-push-action
Expand Down
8 changes: 1 addition & 7 deletions .github/workflows/publish-ghcr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ jobs:
ls
unzip -o dfe-azurecostbackend-datasource-${{ env.PLUGIN_VERSION }}.zip
unzip -o blackcowmoo-googleanalytics-datasource-0.2.3.zip
cp /home/runner/work/Grafana.Plugin.CostManagement/Grafana.Plugin.CostManagement/grafana-files/grafana.ini .
cd ..
# Login against a Docker registry except on PR
Expand All @@ -42,13 +43,6 @@ jobs:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Copy grafana.ini to /etc/grafana
run: |
sudo cp /home/runner/work/Grafana.Plugin.CostManagement/Grafana.Plugin.CostManagement/grafana-files/grafana.ini /etc/grafana/
ls -l /etc/grafana/
cat /etc/grafana/grafana.ini
shell: bash

- name: Build Docker Image
run: |
docker build . -t ghcr.io/dfe-digital/grafana-azurecostplugin-grafana:${{ env.PLUGIN_VERSION }}
Expand Down
2 changes: 2 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ FROM grafana/${grafana_image}:${grafana_version}
# Inject livereload script into grafana index.html
USER root

COPY latest-cost-plugin/grafana.ini /etc/grafana/grafana.ini

# Copy your plugin files into the Grafana plugins directory
COPY latest-cost-plugin/dfe-azurecostbackend-datasource /var/lib/grafana/plugins/dfe-azurecostbackend-datasource
COPY latest-cost-plugin/blackcowmoo-googleanalytics-datasource /var/lib/grafana/plugins/blackcowmoo-googleanalytics-datasource
Expand Down

0 comments on commit 43be846

Please sign in to comment.