Merge branch 'main' into add-authentik-sso
This commit is contained in:
commit
b111dd0af2
|
|
@ -3,6 +3,7 @@ pipeline {
|
|||
|
||||
environment {
|
||||
NODE_VERSION = '20.17.0'
|
||||
PR_NUMBER = "${env.CHANGE_ID}" // PR number comes from webhook payload
|
||||
}
|
||||
|
||||
stages {
|
||||
|
|
@ -32,6 +33,39 @@ pipeline {
|
|||
sh 'npm run build'
|
||||
}
|
||||
}
|
||||
|
||||
stage('Build and Push Docker Image') {
|
||||
when {
|
||||
expression { return env.CHANGE_ID != null } // Only run if it's a PR
|
||||
}
|
||||
steps {
|
||||
withCredentials([string(credentialsId: 'gh-pat', variable: 'GITHUB_PASS')]) {
|
||||
|
||||
// Docker login step
|
||||
sh '''
|
||||
echo "$GITHUB_PASS" | docker login ghcr.io -u "egelhaus" --password-stdin
|
||||
'''
|
||||
|
||||
// Set image tag dynamically based on the PR number
|
||||
sh '''
|
||||
IMAGE_TAG="ghcr.io/gitroomhq/postiz-app-pr:$PR_NUMBER"
|
||||
echo "IMAGE_TAG=$IMAGE_TAG" >> image.env
|
||||
'''
|
||||
|
||||
// Build Docker image
|
||||
sh '''
|
||||
source image.env
|
||||
docker build -f Dockerfile.dev -t $IMAGE_TAG .
|
||||
'''
|
||||
|
||||
// Push Docker image to GitHub Container Registry
|
||||
sh '''
|
||||
source image.env
|
||||
docker push $IMAGE_TAG
|
||||
'''
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
post {
|
||||
success {
|
||||
|
|
|
|||
|
|
@ -506,7 +506,7 @@ export const MainBillingComponent: FC<{
|
|||
<PurchaseCrypto />
|
||||
{!!subscription?.id && (
|
||||
<div className="flex justify-center mt-[20px] gap-[10px]">
|
||||
<Button onClick={updatePayment}>Update Payment Method</Button>
|
||||
<Button onClick={updatePayment}>Update Payment Method / Invoices History</Button>
|
||||
{isGeneral && !subscription?.cancelAt && (
|
||||
<Button
|
||||
className="bg-red-500"
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ import { useVariables } from '@gitroom/react/helpers/variable.context';
|
|||
|
||||
export const PublicComponent = () => {
|
||||
const user = useUser();
|
||||
const {frontEndUrl} = useVariables();
|
||||
const { backendUrl } = useVariables();
|
||||
const toaster = useToaster();
|
||||
const [reveal, setReveal] = useState(false);
|
||||
const [reveal2, setReveal2] = useState(false);
|
||||
|
|
@ -19,6 +19,11 @@ export const PublicComponent = () => {
|
|||
copy(user?.publicApi!);
|
||||
}, [user]);
|
||||
|
||||
const copyToClipboard2 = useCallback(() => {
|
||||
toaster.show('MCP copied to clipboard', 'success');
|
||||
copy(`${backendUrl}/mcp/` + user?.publicApi + '/sse');
|
||||
}, [user]);
|
||||
|
||||
if (!user || !user.publicApi) {
|
||||
return null;
|
||||
}
|
||||
|
|
@ -64,11 +69,15 @@ export const PublicComponent = () => {
|
|||
<div className="my-[16px] mt-[16px] bg-sixth border-fifth items-center border rounded-[4px] p-[24px] flex gap-[24px]">
|
||||
<div className="flex items-center">
|
||||
{reveal2 ? (
|
||||
`${frontEndUrl}/mcp/` + user.publicApi + '/sse'
|
||||
`${backendUrl}/mcp/` + user.publicApi + '/sse'
|
||||
) : (
|
||||
<>
|
||||
<div className="blur-sm">{(`${frontEndUrl}/mcp/` + user.publicApi + '/sse').slice(0, -5)}</div>
|
||||
<div>{(`${frontEndUrl}/mcp/` + user.publicApi + '/sse').slice(-5)}</div>
|
||||
<div className="blur-sm">
|
||||
{(`${backendUrl}/mcp/` + user.publicApi + '/sse').slice(0, -5)}
|
||||
</div>
|
||||
<div>
|
||||
{(`${backendUrl}/mcp/` + user.publicApi + '/sse').slice(-5)}
|
||||
</div>
|
||||
</>
|
||||
)}
|
||||
</div>
|
||||
|
|
@ -76,7 +85,7 @@ export const PublicComponent = () => {
|
|||
{!reveal2 ? (
|
||||
<Button onClick={() => setReveal2(true)}>Reveal</Button>
|
||||
) : (
|
||||
<Button onClick={copyToClipboard}>Copy Key</Button>
|
||||
<Button onClick={copyToClipboard2}>Copy Key</Button>
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -348,15 +348,7 @@ export class StripeService {
|
|||
async createBillingPortalLink(customer: string) {
|
||||
return stripe.billingPortal.sessions.create({
|
||||
customer,
|
||||
flow_data: {
|
||||
after_completion: {
|
||||
type: 'redirect',
|
||||
redirect: {
|
||||
return_url: process.env['FRONTEND_URL'] + '/billing',
|
||||
},
|
||||
},
|
||||
type: 'payment_method_update',
|
||||
},
|
||||
return_url: process.env['FRONTEND_URL'] + '/billing',
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
v1.38.1
|
||||
v1.39.1
|
||||
|
|
|
|||
Loading…
Reference in New Issue