mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-12 23:35:50 +00:00
diable authentication
This commit is contained in:
parent
990aabfd0c
commit
a3e8ca49e5
@ -5,15 +5,5 @@
|
||||
<script>
|
||||
export default {
|
||||
name: 'App',
|
||||
methods: {
|
||||
async readToken() {
|
||||
if (window.localStorage && window.localStorage.getItem('vuex')) {
|
||||
this.$store.commit('token', JSON.parse(window.localStorage.vuex).token)
|
||||
}
|
||||
},
|
||||
},
|
||||
created() {
|
||||
this.readToken()
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
@ -21,7 +21,7 @@ import { BootstrapVue } from 'bootstrap-vue'
|
||||
const httpLink = new HttpLink({ uri: CONFIG.GRAPHQL_URI })
|
||||
|
||||
const authLink = new ApolloLink((operation, forward) => {
|
||||
const token = '' // store.state.token
|
||||
const token = store.state.token
|
||||
operation.setContext({
|
||||
headers: {
|
||||
Authorization: token && token.length > 0 ? `Bearer ${token}` : '',
|
||||
|
||||
@ -3,9 +3,11 @@ import NotFound from '@/components/NotFoundPage.vue'
|
||||
const routes = [
|
||||
{
|
||||
path: '/',
|
||||
/*
|
||||
meta: {
|
||||
requiresAuth: true,
|
||||
},
|
||||
*/
|
||||
},
|
||||
{ path: '*', component: NotFound },
|
||||
]
|
||||
|
||||
@ -12,7 +12,7 @@ export const mutations = {
|
||||
const store = new Vuex.Store({
|
||||
mutations,
|
||||
state: {
|
||||
token: null,
|
||||
token: 'some-token',
|
||||
},
|
||||
})
|
||||
|
||||
|
||||
@ -8,8 +8,6 @@ services:
|
||||
image: gradido/frontend:development
|
||||
build:
|
||||
target: development
|
||||
networks:
|
||||
- external-net
|
||||
environment:
|
||||
- NODE_ENV="development"
|
||||
# - DEBUG=true
|
||||
@ -27,8 +25,6 @@ services:
|
||||
image: gradido/admin:development
|
||||
build:
|
||||
target: development
|
||||
networks:
|
||||
- external-net
|
||||
environment:
|
||||
- NODE_ENV="development"
|
||||
# - DEBUG=true
|
||||
|
||||
@ -15,6 +15,7 @@ services:
|
||||
context: ./frontend
|
||||
target: production
|
||||
networks:
|
||||
- external-net
|
||||
- internal-net
|
||||
ports:
|
||||
- 3000:3000
|
||||
@ -39,6 +40,7 @@ services:
|
||||
context: ./admin
|
||||
target: production
|
||||
networks:
|
||||
- external-net
|
||||
- internal-net
|
||||
ports:
|
||||
- 8080:8080
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user