Skip to content
Snippets Groups Projects
Commit 01d2b161 authored by Remi  PLANEL's avatar Remi PLANEL
Browse files

add to nuxt config and set at build time short sha

parent a29fff3b
No related branches found
No related tags found
No related merge requests found
Pipeline #127568 waiting for manual action with stages
in 1 minute and 53 seconds
...@@ -423,6 +423,7 @@ sync-zotero: ...@@ -423,6 +423,7 @@ sync-zotero:
--build-arg "BASE_URL=$BASE_URL" --build-arg "BASE_URL=$BASE_URL"
--build-arg "MEILI_HOST=${MEILI_HOST}" --build-arg "MEILI_HOST=${MEILI_HOST}"
--build-arg "MEILI_API_KEY=$MEILI_API_KEY" --build-arg "MEILI_API_KEY=$MEILI_API_KEY"
--build-arg "SHORT_SHA=${$CI_COMMIT_SHORT_SHA}"
-f $DOCKERFILE $CONTEXT -f $DOCKERFILE $CONTEXT
- docker push "$CI_REGISTRY_IMAGE/$IMAGE_NAME:$CI_COMMIT_SHORT_SHA" - docker push "$CI_REGISTRY_IMAGE/$IMAGE_NAME:$CI_COMMIT_SHORT_SHA"
......
<script setup lang="ts"> <script setup lang="ts">
const runtimeConfig = useRuntimeConfig(); const runtimeConfig = useRuntimeConfig();
</script> </script>
<template> <template>
<v-footer app text-center d-flex flex-column> <v-footer app text-center d-flex flex-column>
test
<div class="px-4 text-center w-100"> <div class="px-4 text-center w-100">
<span> {{ runtimeConfig.public.shortSha }} <span> {{ runtimeConfig.public.shortSha }}
</span> </span>
......
...@@ -12,6 +12,7 @@ services: ...@@ -12,6 +12,7 @@ services:
container_name: nuxt container_name: nuxt
environment: environment:
HOST: 0.0.0.0 HOST: 0.0.0.0
NUXT_PUBLIC_SHORT_SHA: "short-sha"
volumes: volumes:
- .:/usr/src/app - .:/usr/src/app
- defense-finder-wiki-node-modules:/usr/src/app/node_modules - defense-finder-wiki-node-modules:/usr/src/app/node_modules
......
...@@ -77,6 +77,7 @@ export default defineNuxtConfig({ ...@@ -77,6 +77,7 @@ export default defineNuxtConfig({
runtimeConfig: { runtimeConfig: {
public: { public: {
shortSha: 'xxxxx',
defenseFinderWebservice: '/', defenseFinderWebservice: '/',
hostUrl: "http://localhost:8082", hostUrl: "http://localhost:8082",
meilisearchClient: { meilisearchClient: {
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment