🎉 Init
This commit is contained in:
commit
7346bb05e4
24
.gitignore
vendored
Normal file
24
.gitignore
vendored
Normal file
@ -0,0 +1,24 @@
|
||||
# Nuxt dev/build outputs
|
||||
.output
|
||||
.data
|
||||
.nuxt
|
||||
.nitro
|
||||
.cache
|
||||
dist
|
||||
|
||||
# Node dependencies
|
||||
node_modules
|
||||
|
||||
# Logs
|
||||
logs
|
||||
*.log
|
||||
|
||||
# Misc
|
||||
.DS_Store
|
||||
.fleet
|
||||
.idea
|
||||
|
||||
# Local env files
|
||||
.env
|
||||
.env.*
|
||||
!.env.example
|
||||
17
Dockerfile
Normal file
17
Dockerfile
Normal file
@ -0,0 +1,17 @@
|
||||
FROM node:22.9.0-alpine
|
||||
|
||||
WORKDIR /usr/app
|
||||
|
||||
COPY . .
|
||||
|
||||
ARG VERSION
|
||||
|
||||
RUN npm install
|
||||
|
||||
RUN npx nuxi cleanup
|
||||
|
||||
RUN npx nuxi build
|
||||
|
||||
EXPOSE 3000
|
||||
|
||||
CMD ["node", ".output/server/index.mjs"]
|
||||
38
Jenkinsfile
vendored
Normal file
38
Jenkinsfile
vendored
Normal file
@ -0,0 +1,38 @@
|
||||
pipeline {
|
||||
agent any
|
||||
|
||||
stages {
|
||||
stage('Set Image Name') {
|
||||
steps {
|
||||
script {
|
||||
env.IMAGE = "harbor.dinauer.dev/verifoo/frontend:${env.BUILD_NUMBER}";
|
||||
}
|
||||
}
|
||||
}
|
||||
stage('Build Image') {
|
||||
steps {
|
||||
script {
|
||||
sh "docker build --no-cache -t ${env.IMAGE} ."
|
||||
}
|
||||
}
|
||||
}
|
||||
stage('Push Image to Docker Hub') {
|
||||
steps {
|
||||
script {
|
||||
withCredentials([usernamePassword(credentialsId: 'harbor', usernameVariable: 'USERNAME', passwordVariable: 'PASSWORD')]) {
|
||||
sh 'echo ${PASSWORD} | docker login harbor.dinauer.dev -u ${USERNAME} --password-stdin'
|
||||
sh "docker push ${env.IMAGE}"
|
||||
sh "docker logout harbor.dinauer.dev"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
stage('Remove image from host') {
|
||||
steps {
|
||||
script {
|
||||
sh "docker image rm --force ${env.IMAGE}"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
75
README.md
Normal file
75
README.md
Normal file
@ -0,0 +1,75 @@
|
||||
# Nuxt Minimal Starter
|
||||
|
||||
Look at the [Nuxt documentation](https://nuxt.com/docs/getting-started/introduction) to learn more.
|
||||
|
||||
## Setup
|
||||
|
||||
Make sure to install dependencies:
|
||||
|
||||
```bash
|
||||
# npm
|
||||
npm install
|
||||
|
||||
# pnpm
|
||||
pnpm install
|
||||
|
||||
# yarn
|
||||
yarn install
|
||||
|
||||
# bun
|
||||
bun install
|
||||
```
|
||||
|
||||
## Development Server
|
||||
|
||||
Start the development server on `http://localhost:3000`:
|
||||
|
||||
```bash
|
||||
# npm
|
||||
npm run dev
|
||||
|
||||
# pnpm
|
||||
pnpm dev
|
||||
|
||||
# yarn
|
||||
yarn dev
|
||||
|
||||
# bun
|
||||
bun run dev
|
||||
```
|
||||
|
||||
## Production
|
||||
|
||||
Build the application for production:
|
||||
|
||||
```bash
|
||||
# npm
|
||||
npm run build
|
||||
|
||||
# pnpm
|
||||
pnpm build
|
||||
|
||||
# yarn
|
||||
yarn build
|
||||
|
||||
# bun
|
||||
bun run build
|
||||
```
|
||||
|
||||
Locally preview production build:
|
||||
|
||||
```bash
|
||||
# npm
|
||||
npm run preview
|
||||
|
||||
# pnpm
|
||||
pnpm preview
|
||||
|
||||
# yarn
|
||||
yarn preview
|
||||
|
||||
# bun
|
||||
bun run preview
|
||||
```
|
||||
|
||||
Check out the [deployment documentation](https://nuxt.com/docs/getting-started/deployment) for more information.
|
||||
19
app/api/Login.ts
Normal file
19
app/api/Login.ts
Normal file
@ -0,0 +1,19 @@
|
||||
import axios from "axios";
|
||||
|
||||
export class Login
|
||||
{
|
||||
email?: string;
|
||||
password?: string;
|
||||
|
||||
static login(login: Login, onSuccess: (token: string) => void, onError: () => void)
|
||||
{
|
||||
axios.post<string>(useRuntimeConfig().public.baseUrl + '/sessions/' + useRuntimeConfig().public.realmId, login, { maxRedirects: 1 })
|
||||
.then((response) => {
|
||||
console.log(response.headers['Location']);
|
||||
onSuccess(response.data);
|
||||
})
|
||||
.catch(() => {
|
||||
onError();
|
||||
});
|
||||
}
|
||||
}
|
||||
5
app/app.vue
Normal file
5
app/app.vue
Normal file
@ -0,0 +1,5 @@
|
||||
<template>
|
||||
<div id="app">
|
||||
<NuxtPage></NuxtPage>
|
||||
</div>
|
||||
</template>
|
||||
33
app/assets/style.css
Normal file
33
app/assets/style.css
Normal file
@ -0,0 +1,33 @@
|
||||
@import url('https://fonts.googleapis.com/css2?family=Google+Sans:ital,opsz,wght@0,17..18,400..700;1,17..18,400..700&display=swap');
|
||||
|
||||
* {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
font-family: "Google Sans", sans-serif;
|
||||
font-optical-sizing: auto;
|
||||
font-style: normal;
|
||||
font-variation-settings: "GRAD" 0;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
html, body, #__nuxt {
|
||||
height: 100vh;
|
||||
width: 100vw;
|
||||
}
|
||||
|
||||
#app {
|
||||
width: 100vw;
|
||||
min-height: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
input, textarea, select {
|
||||
width: 100%;
|
||||
height: 2.5rem;
|
||||
font-size: 0.9rem;
|
||||
padding: 0.25rem;
|
||||
outline: none;
|
||||
border: 1px solid #989898;
|
||||
}
|
||||
64
app/pages/realms/[realm]/auth.vue
Normal file
64
app/pages/realms/[realm]/auth.vue
Normal file
@ -0,0 +1,64 @@
|
||||
<template>
|
||||
<div class="login-container">
|
||||
<form class="login-form" method="POST" :action="useRuntimeConfig().public.baseUrl + '/realms/' + useRuntimeConfig().public.realmKey + '/protocol/openid-connect/auth?client_id=' + useRoute().query.client_id">
|
||||
<div style="display: flex; flex-direction: column; justify-content: center;">
|
||||
<h2 class="sso-heading">Sign in with Verifoo</h2>
|
||||
<p class="sso-subheading">MavenVault</p>
|
||||
</div>
|
||||
<div class="field">
|
||||
<p>E-Mail</p>
|
||||
<input name="email" type="text" value="andreas.j.dinauer@gmail.com">
|
||||
</div>
|
||||
<div class="field">
|
||||
<p>Password</p>
|
||||
<input name="password" type="password" value="pw">
|
||||
</div>
|
||||
<a href="">Forgot password?</a>
|
||||
<button class="button" type="submit">Login</button>
|
||||
</form>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.login-container {
|
||||
width: 620px;
|
||||
}
|
||||
.field {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr;
|
||||
gap: 0.5rem;
|
||||
}
|
||||
.login-form {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr;
|
||||
gap: 1.25rem;
|
||||
background-color: #f4f4f4;
|
||||
padding: 3rem;
|
||||
border: 1px solid #dfdfdf;
|
||||
}
|
||||
.sso-heading {
|
||||
text-align: center;
|
||||
display: inline-block;
|
||||
margin-bottom: 0.5rem;
|
||||
}
|
||||
.sso-subheading {
|
||||
text-align: center;
|
||||
display: inline-block;
|
||||
margin-bottom: 1.5rem;
|
||||
}
|
||||
.button {
|
||||
background-color: #232323;
|
||||
color: white;
|
||||
height: 2.5rem;
|
||||
outline: none;
|
||||
border: none;
|
||||
font-size: 1.125rem;
|
||||
margin-top: 1.5rem;
|
||||
}
|
||||
a {
|
||||
color: black;
|
||||
}
|
||||
</style>
|
||||
14
nuxt.config.ts
Normal file
14
nuxt.config.ts
Normal file
@ -0,0 +1,14 @@
|
||||
// https://nuxt.com/docs/api/configuration/nuxt-config
|
||||
export default defineNuxtConfig({
|
||||
compatibilityDate: '2025-07-15',
|
||||
devtools: { enabled: true },
|
||||
runtimeConfig: {
|
||||
public: {
|
||||
baseUrl: process.env.NUXT_PUBLIC_BASE_URL,
|
||||
realmKey: process.env.NUXT_PUBLIC_REALM_KEY
|
||||
}
|
||||
},
|
||||
css: [
|
||||
'@/assets/style.css'
|
||||
]
|
||||
})
|
||||
10114
package-lock.json
generated
Normal file
10114
package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load Diff
19
package.json
Normal file
19
package.json
Normal file
@ -0,0 +1,19 @@
|
||||
{
|
||||
"name": "iam-frontend",
|
||||
"type": "module",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"build": "nuxt build",
|
||||
"dev": "nuxt dev",
|
||||
"generate": "nuxt generate",
|
||||
"preview": "nuxt preview",
|
||||
"postinstall": "nuxt prepare"
|
||||
},
|
||||
"dependencies": {
|
||||
"@types/node": "^25.3.0",
|
||||
"axios": "^1.13.5",
|
||||
"nuxt": "^4.3.1",
|
||||
"vue": "^3.5.28",
|
||||
"vue-router": "^4.6.4"
|
||||
}
|
||||
}
|
||||
BIN
public/favicon.ico
Normal file
BIN
public/favicon.ico
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 4.2 KiB |
2
public/robots.txt
Normal file
2
public/robots.txt
Normal file
@ -0,0 +1,2 @@
|
||||
User-Agent: *
|
||||
Disallow:
|
||||
21
tsconfig.json
Normal file
21
tsconfig.json
Normal file
@ -0,0 +1,21 @@
|
||||
{
|
||||
// https://nuxt.com/docs/guide/concepts/typescript
|
||||
"files": [],
|
||||
"references": [
|
||||
{
|
||||
"path": "./.nuxt/tsconfig.app.json"
|
||||
},
|
||||
{
|
||||
"path": "./.nuxt/tsconfig.server.json"
|
||||
},
|
||||
{
|
||||
"path": "./.nuxt/tsconfig.shared.json"
|
||||
},
|
||||
{
|
||||
"path": "./.nuxt/tsconfig.node.json"
|
||||
}
|
||||
],
|
||||
"compilerOptions": {
|
||||
"types": ["node"]
|
||||
}
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user