Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

theme casper is a dangling symlink #230

Open
chendelin1982 opened this issue Sep 4, 2020 · 9 comments
Open

theme casper is a dangling symlink #230

chendelin1982 opened this issue Sep 4, 2020 · 9 comments

Comments

@chendelin1982
Copy link

chendelin1982 commented Sep 4, 2020

Hi,
When I have mount /var/lib/ghost/content, I found that themes/casper is a dangling symlink
the symlink is: /var/lib/ghost/current/content/themes/casper
but the actual directory is: /var/lib/ghost/content/themes/casper

@kopax
Copy link

kopax commented Oct 27, 2020

To me, it's confirmed as I have the same issue with the latest ghost:3.6.0.

image

To reproduce, just start with a docker-compose with a guest OS mounted volume, check the directory /content/themes, you'll see the wrong symlink.

@tianon
Copy link
Member

tianon commented Dec 15, 2020

I can't reproduce: 😕

$ docker pull ghost
Using default tag: latest
latest: Pulling from library/ghost
Digest: sha256:e44738f6b05a06494724d59e88ecb53fcde62bfcb5a1a1f49fc155ac25928241
Status: Image is up to date for ghost:latest
docker.io/library/ghost:latest

$ docker volume create ghost-content
ghost-content

$ docker run -it --rm --name test -v ghost-content:/var/lib/ghost/content ghost
...
[2020-12-15 00:58:25] INFO Relation: User to Role
[2020-12-15 00:58:27] INFO Ghost is running in production...
[2020-12-15 00:58:27] INFO Your site is now available on http://localhost:2368/
[2020-12-15 00:58:27] INFO Ctrl+C to shut down
[2020-12-15 00:58:27] INFO Ghost boot 4.238s

$ # in another terminal
$ docker exec test ls -l content/themes/casper/
total 288
-rw-r--r-- 1 node node   1065 Oct 26  1985 LICENSE
-rw-r--r-- 1 node node   2895 Oct 26  1985 README.md
drwxr-xr-x 5 node node   4096 Dec 12 18:14 assets
-rw-r--r-- 1 node node   2480 Oct 26  1985 author.hbs
-rw-r--r-- 1 node node   5934 Oct 26  1985 default.hbs
-rw-r--r-- 1 node node    968 Oct 26  1985 error-404.hbs
-rw-r--r-- 1 node node   2597 Oct 26  1985 error.hbs
-rw-r--r-- 1 node node   5244 Oct 26  1985 gulpfile.js
-rw-r--r-- 1 node node   3079 Oct 26  1985 index.hbs
-rw-r--r-- 1 node node   2495 Oct 26  1985 package.json
-rw-r--r-- 1 node node   2161 Oct 26  1985 page.hbs
drwxr-xr-x 3 node node   4096 Dec 12 18:14 partials
-rw-r--r-- 1 node node   8394 Oct 26  1985 post.hbs
-rw-r--r-- 1 node node   1117 Oct 26  1985 tag.hbs
-rw-r--r-- 1 node node 220823 Oct 26  1985 yarn.lock

@pascalandy
Copy link
Contributor

all good on my side as well v3.40.1

@ecalcutin
Copy link

Same here. Cant edit theme :(
My docker compose file:

version: "3.8"

services:
  ghost:
    image: ghost:4-alpine
    restart: always
    ports:
      - 8080:2368
    volumes:
      - ./ghostdata:/var/lib/ghost/content
    environment:
      url: http://localhost:8080
      NODE_ENV: development

image

@ideacco
Copy link

ideacco commented Mar 3, 2022

I encountered the same problem, but later I found that the default theme cannot be modified, you can go to the official website to download the default theme, then upload it to ghost through the management page, and activate the theme. At this time, you can see the Docker mapping theme file.

@m3nu
Copy link

m3nu commented Mar 18, 2022

Seeing this as well. Happens after container restarts.

@hawkkiller
Copy link

image

@derek-adair
Copy link

derek-adair commented Jun 28, 2023

This issue can probably be closed as it's mainly just a miscommunication between the maintainers and those having this issue and I believed it to be the root of the problem the user is facing here.


the symlink is not dangling... inside the container.. I think this is where the confusion is coming from -- users are not going to be editing the theme within the docker container -- we expect it to be accessible from host machines. Furthermore, there is no clear way to edit themes and preview them live (as far as i can tell). That discussion is also taking place in the other issue.

@derek-adair
Copy link

derek-adair commented Jun 28, 2023

I can't reproduce: confused
$ docker exec test ls -l content/themes/casper/

You are running the ls command in the container and not on the host machine. ls -l content/themes/casper/ will yield a broken symlink.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants